{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

# 00-intro - Algorithms Lecture 0 Introduction[F10 We should...

This preview shows pages 1–2. Sign up to view the full content.

Algorithms Lecture 0: Introduction [ F10 ] We should explain, before proceeding, that it is not our object to consider this program with reference to the actual arrangement of the data on the Variables of the engine, but simply as an abstract question of the nature and number of the operations required to be perfomed during its complete solution. — Ada Augusta Byron King, Countess of Lovelace, translator’s notes for Luigi F. Menabrea, “Sketch of the Analytical Engine invented by Charles Babbage, Esq.” (1843) You are right to demand that an artist engage his work consciously, but you confuse two different things: solving the problem and correctly posing the question. — Anton Chekhov, in a letter to A. S. Suvorin (October 27, 1888) The more we reduce ourselves to machines in the lower things, the more force we shall set free to use in the higher. — Anna C. Brackett, The Technique of Rest (1892) The moment a man begins to talk about technique that’s proof that he is fresh out of ideas. — Raymond Chandler 0 Introduction 0.1 What is an algorithm? An algorithm is an explicit, precise, unambiguous, mechanically-executable sequence of elementary instructions. For example, here is an algorithm for singing that annoying song ‘99 Bottles of Beer on the Wall’, for arbitrary values of 99: B OTTLES O F B EER ( n ) : For i n down to 1 Sing “ i bottles of beer on the wall, i bottles of beer, Sing “ Take one down, pass it around, i - 1 bottles of beer on the wall. Sing “ No bottles of beer on the wall, no bottles of beer, Sing “ Go to the store, buy some more, n bottles of beer on the wall. The word ‘algorithm’ does not derive, as algorithmophobic classicists might guess, from the Greek root algos ( λγος ), meaning ‘pain’. Rather, it is a corruption of the name of the 9th century Persian mathematician Ab ¯ u ’Abd All ¯ ah Mu h . ammad ibn M ¯ us ¯ a al-Khw ¯ arizm ¯ ı. 1 Al-Khw ¯ arizm ¯ ı is perhaps best known as the writer of the treatise Al-Kit ¯ ab al-mukhta s . ar f ¯ ıh ¯ ıs ¯ ab al-˘gabr wa’l-muq ¯ abala 2 , from which the modern word algebra derives. In another treatise, al-Khw ¯ arizm ¯ ı popularized the modern decimal system for writing and manipulating numbers—in particular, the use of a small circle or s . ifr to represent a missing quantity—which had originated in India several centuries earlier. This system later became known in Europe as algorism . Thanks to the efforts of the medieval Italian mathematician Leonardo of Pisa, better known as Fibonacci, algorism began to replace the abacus as the preferred system of commercial calculation 3 in Europe in the late 12th century, although cyphers became truly ubiquitous in Western Europe only after the French revolution 600 years later. The more modern word algorithm is a false 1 ‘Mohammad, father of Adbdulla, son of Moses, the Kw ¯ arizmian’. Kw ¯ arizm is an ancient city, now called Khiva, in the Khorezm Province of Uzbekistan.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern