Algorithms..

The Mind of Programming and the Basis of Its Development

There is a close relationship between programming and algorithms, the latter is written in a specific programming language to perform a specific purpose or solve a specific problem, and any programming language in the world is based on specific algorithm steps.

Eng. Mohammed Alhassan

   No one who works in the field of programming or owns the basic concepts of it can bypass algorithms, or ignore their essential role, nor can he develop in his career unless he masters how to use them, and understand their nature, especially since they are essential in programming science and benefit from its languages circulating in the world, and a major contributor to the tremendous development that we are currently witnessing in the field of programming applications in various fields.

   وهذا المفهوم – الذي ربما يبدو غامضا لفئة من الجمهور- لا يعد إحدى لغات البرمجة، بل يمكن شرحه بأنه يمثل طرائق التحليل والتفكير التي يمكن اتباعها حتى يتمكن أي مبرمج من كتابة ما يعرف (بالكود) في علم البرمجة. كما تعرف الخوارزميات – التي تنسب إلى العالم محمد بن موسى الخوارزمي – بأنها سلسلة من الخطوات الرياضية والمنطقية التي تستخدم لحل مشكلة معينة، أو أنها مجموعة من الخطوات المحددة ذات الترتيب المعين التي يسير المبرمج وفقها لحل مشكلة برمجية. ووفقا لذلك، فإنه إذا كان وضع الخوارزمية يحتاج إلى مزيج من المنهجية والعلم والإبداع، فإن تنفيذها لا يترك مجالا للتأويل والحدس.

   There is a close relationship between programming and algorithms, the latter is written in a specific programming language to perform a specific purpose or reach a solution to a specific problem, and any programming language in the world is based on specific algorithmic steps, and therefore either side (programming and algorithms) is only done by the other, and each is complementary to the role of the other.

In simple terms, if the programmer wants to solve a problem and wants to express it in a programming language, he will first resort to algorithms, that is, logically think about the steps and stages of the solution, and put them in mind. Then comes the role of programming, which is to express these steps and stages through the language chosen by the programmer, and in clear words that he understands or can express through recognized forms. This means that algorithms can be used for all problems that need logical thinking about how to solve them, especially complex processes that need to be simplified and shortened in time to address.

History of the Term

   There must be a historical look that shows us the sequence of use of the term algorithms, and whether those who used it meant to be attributed to the algorithmic scientist, or was it carved from two words used in one of the world's languages.

According to historical references, the term was used in the early twentieth century in mathematics and computerization, but its roots in history go much deeper. Old English dictionaries make it clear that the term refers to the decimal or Arabic counting system that Europeans called Algoritmi de Numero. It was widely believed that it came from the combination of the words Algiros (painful) and Arithmos (number). But the American computing scientist Donald Connuth was one of the first to mention that the term was attributed to al-Khwarizmi.

Some researchers believe that man since ancient times developed algorithms to draw geometric shapes and calculate their areas and volumes, and all the methods that humans learned to multiply and divide numbers are algorithms. Perhaps the oldest algorithm in history is Euclid's algorithm on calculating the greatest common divisor of two integers developed in the third century BC. Another famous algorithm is the one developed by the ancient Egyptians to draw a right-angled triangle, which Pythagoras turned into a famous theory.

ويعود الاهتمام المعاصر بمصطلح Algorithm إلى الفترة 1960 – 1980 عندما كان المهتمون بعلم الحاسوب والبَرمَجة يحاولون منح هذا الحقل العلمي الجديد صفة أكاديمية مستقلة عن التخصصات المشابهة. وبرز دور كونوث في إسهامين مهمين: الأول ما ذكره في مقدمة موسوعته (فن البرمجة الحاسوبية) أن كلمة “فن” التي جاءت في العنوان مقتبسة من التسمية العربية، للإشارة إلى أعلى مستويات الأداء العلمي أو المهني، كما ذكر أن مصطلح الخوارزميات منسوب إلى الخوارزمي. والإسهام الثاني لكونوث كان من خلال بحث نشره في مجلة رابطة الآلات الحاسوبية ACM، بمناسبة مرور 20 عاما على تأسيسها بعنوان “Ancient Babylonian Algorithms”  أظهر فيه عراقة مفهوم المصطلح، وأن الحضارات البشرية مارست حل المشكلات التي واجهتها بوضع حلول وصفية لكيفية حلها.

   وعن استخدام مصطلح الخوارزميات في اللغة العربية يقول الباحث العراقي في علوم الحاسوب الدكتور عبد الإله الديوجي ” إنه في عام 1972 اطلعت للمرة الأولى على الجزء الأول من كتاب كونوث، ولَفَتَني ما كَتبه عن أصل المصطلح  Algorithm، وقرأت كذلك ورقته البحثية عن الرياضيات البابلية التي حازت اهتمامي بشكل كبير، ما دعاني في عام 1974 إلى كتابة بحث مختصر في مجلة الجامعة التي تصدر عن جامعة الموصل بعنوان “الخوارزميات في التاريخ” فكانت، حسبما أعتقد، المرة الأولى التي استُخدم فيها “تعريب” المصطلح منسوبا بشكل أشير فيه إلى اسم الخوارزمي باللغة العربية. إذ لم أرَ قبل ذلك التاريخ مَن كَتَبَ باللغة العربية واستخدَم المصطلح بالشكل المنسوب للخوارزمي”.

Use Algorithms

  The term algorithm originally denoted three structures: sequence, selection, and repetition. In the sequence, the algorithm represents several sequential instructions, perhaps simple or of two types, the first of which is the choice: where there are problems that cannot be solved with a simple sequence of instructions, but you may need to test some conditions and then wait for the result of the test, if the result is correct, a path containing sequential instructions can be traced, and if they are wrong, another different path of instructions can be traced. The other type is repetition, which is used when solving some problems with which we need to repeat the same sequence of steps several times.

    There are very fast algorithms used in the case of simple inputs, but if these inputs are too many, they fail and take a long time, and then we resort in this case to other algorithms that suit these inputs, and this means that the appropriate algorithm must be used for the appropriate situation in order for the programmer to reach a quick and simple solution to the problem he is addressing.

Algorithms have a number of characteristics, the most important of which is that they are applied to changeable data, give a specific result, have an finite number of instructions, consist of a set of precise rules that everyone understands, and that they are accurate and specific so that each instruction is described unambiguously. The scope of identification of the input data, if any, must be defined, and the algorithm must be effective so that anyone can perform all operations in a finished time using manual capabilities.

Cadre

Algorithm

Abdullah ibn Muhammad ibn Musa al-Khwarizmi (781 – 847 AD), originally from Khwarazm in present-day Uzbekistan. He lived in Baghdad during the reign of the Abbasid caliph al-Ma'mun and was the supervisor of the al-Ma'mun library. He has published a number of books, including: The First and Second Marriage Books, The Book of Marble, The Book of the Astrolabe Work, The Book of Algebra and the Interview. The latter book is his best-known book, and it is one of the reference books in the field of mathematics in general, and in algebra in particular. He has outstanding achievements in mathematics, geography and astronomy.

Exit mobile version