**Ibn al-Haytham**is sometimes called al-Basri, meaning from the city of Basra in Iraq, and sometimes called al-Misri, meaning that he came from Egypt. He is often known as

**Alhazen**which is the Latinised version of his first name "al-Hasan".

In particular this name occurs in the naming of the problem for which he is best remembered, namely Alhazen's problem:

We shall discuss this problem, and ibn al-Haytham's other work, after giving some biographical details. In contrast to our lack of knowledge of the lives of many of the Arabic mathematicians, we have quite a number of details of ibn al-Haytham's life. However, although these details are in broad agreement with each other, they do contradict each other in several ways. We must therefore try to determine which are more likely to be accurate. It is worth commenting that an autobiography written by ibn al-Haytham in 1027 survives, but it says nothing of the events his life and concentrates on his intellectual development.Given a light source and a spherical mirror, find the point on the mirror were the light will be reflected to the eye of an observer.

Since the main events that we know of in ibn al-Haytham's life involve his time in Egypt, we should set the scene regarding that country. The Fatimid political and religious dynasty took its name from Fatimah, the daughter of the Prophet Muhammad. The Fatimids headed a religious movement dedicated to taking over the whole of the political and religious world of Islam. As a consequence they refused to recognise the 'Abbasid caliphs. The Fatimid caliphs ruled North Africa and Sicily during the first half of the 10^{th} century, but after a number of unsuccessful attempts to defeat Egypt, they began a major advance into that country in 969 conquering the Nile Valley. They founded the city of Cairo as the capital of their new empire. These events were happening while ibn al-Haytham was a young boy growing up in Basra.

We know little of ibn al-Haytham's years in Basra. In his autobiography he explains how, as a youth, he thought about the conflicting religious views of the various religious movements and came to the conclusion that none of them represented the truth. It appears that he did not devote himself to the study of mathematics and other academic topics at a young age but trained for what might be best described as a civil service job. He was appointed as a minister for Basra and the surrounding region. However, ibn al-Haytham became increasingly unhappy with his deep studies of religion and made a decision to devote himself entirely to a study of science which he found most clearly described in the writings of Aristotle. Having made this decision, ibn al-Haytham kept to it for the rest of his life devoting all his energies to mathematics, physics, and other sciences.

Ibn al-Haytham went to Egypt some considerable time after he made the decision to give up his job as a minister and to devote himself to science, for he had made his reputation as a famous scientist while still in Basra. We do know that al-Hakim was Caliph when ibn al-Haytham reached Egypt. Al-Hakim was the second of the Fatimid caliphs to begin his reign in Egypt; al-Aziz was the first of the Fatimid caliphs to do so. Al-Aziz became Caliph in 975 on the death of his father al-Mu'izz. He was very involved in military and political ventures in northern Syria trying to expand the Fatimid empire. For most of his 20 year reign he worked towards this aim. Al-Aziz died in 996 while organising an army to march against the Byzantines and al-Hakim, who was eleven years old at the time, became Caliph.

Al-Hakim, despite being a cruel leader who murdered his enemies, was a patron of the sciences employing top quality scientists such as the astronomer ibn Yunus. His support for science may have been partly because of his interest in astrology. Al-Hakim was highly eccentric, for example he ordered the sacking of the city of al-Fustat, he ordered the killing of all dogs since their barking annoyed him, and he banned certain vegetables and shellfish. However al-Hakim kept astronomical instruments in his house overlooking Cairo and built up a library which was only second in importance to that of the House of Wisdom over 150 years earlier.

Our knowledge of ibn al-Haytham's interaction with al-Hakim comes from a number of sources, the most important of which is the writings of al-Qifti. We are told that al-Hakim learnt of a proposal by ibn al-Haytham to regulate the flow of water down the Nile. He requested that ibn al-Haytham come to Egypt to carry out his proposal and al-Hakim appointed him to head an engineering team which would undertake the task. However, as the team travelled further and further up the Nile, ibn al-Haytham realised that his idea to regulate the flow of water with large constructions would not work.

Ibn al-Haytham returned with his engineering team and reported to al-Hakim that they could not achieve their aim. Al-Hakim, disappointed with ibn al-Haytham's scientific abilities, appointed him to an administrative post. At first ibn al-Haytham accepted this but soon realised that al-Hakim was a dangerous man whom he could not trust. It appears that ibn al-Haytham pretended to be mad and as a result was confined to his house until after al-Hakim's death in 1021. During this time he undertook scientific work and after al-Hakim's death he was able to show that he had only pretended to be mad. According to al-Qifti, ibn al-Haytham lived for the rest of his life near the Azhar Mosque in Cairo writing mathematics texts, teaching and making money by copying texts. Since the Fatimids founded the University of Al-Azhar based on this mosque in 970, ibn al-Haytham must have been associated with this centre of learning.

A different report says that after failing in his mission to regulate the Nile, ibn al-Haytham fled from Egypt to Syria where he spent the rest of his life. This however seems unlikely for other reports certainly make it certain that ibn al-Haytham was in Egypt in 1038. One further complication is the title of a work ibn al-Haytham wrote in 1027 which is entitled *Ibn al-Haytham's answer to a geometrical question addressed to him in Baghdad*. Several different explanations are possible, the simplest of which being that he visited Baghdad for a short time before returning to Egypt. He may also have spent some time in Syria which would partly explain the other version of the story. Yet another version has ibn al-Haytham pretending to be mad while still in Basra.

Ibn al-Haytham's writings are too extensive for us to be able to cover even a reasonable amount. He seems to have written around 92 works of which, remarkably, over 55 have survived. The main topics on which he wrote were optics, including a theory of light and a theory of vision, astronomy, and mathematics, including geometry and number theory. We will give at least an indication of his contributions to these areas.

A seven volume work on optics, *Kitab al-Manazir*, is considered by many to be ibn al-Haytham's most important contribution. It was translated into Latin as *Opticae thesaurus Alhazeni* in 1270. The previous major work on optics had been Ptolemy's *Almagest* and although ibn al-Haytham's work did not have an influence to equal that of Ptolemy's, nevertheless it must be regarded as the next major contribution to the field. The work begins with an introduction in which ibn al-Haytham says that he will begin "the inquiry into the principles and premises". His methods will involve "criticising premises and exercising caution in drawing conclusions" while he aimed "to employ justice, not follow prejudice, and to take care in all that we judge and criticise that we seek the truth and not be swayed by opinions".

Also in Book I, ibn al-Haytham makes it clear that his investigation of light will be based on experimental evidence rather than on abstract theory. He notes that light is the same irrespective of the source and gives the examples of sunlight, light from a fire, or light reflected from a mirror which are all of the same nature. He gives the first correct explanation of vision, showing that light is reflected from an object into the eye. Most of the rest of Book I is devoted to the structure of the eye but here his explanations are necessarily in error since he does not have the concept of a lens which is necessary to understand the way the eye functions. His studies of optics did led him, however, to propose the use of a camera obscura, and he was the first person to mention it.

Book II of the *Optics* discusses visual perception while Book III examines conditions necessary for good vision and how errors in vision are caused. From a mathematical point of view Book IV is one of the most important since it discusses the theory of reflection. Ibn al-Haytham gave [1]:-

Alhazen's problem, quoted near the beginning of this article, appears in Book V. Although we have quoted the problem for spherical mirrors, ibn al-Haytham also considered cylindrical and conical mirrors. The paper [36] gives a detailed description of six geometrical lemmas used by ibn al-Haytham in solving this problem. Huygens reformulated the problem as:-... experimental proof of the specular reflection of accidental as well as essential light, a complete formulation of the laws of reflection, and a description of the construction and use of a copper instrument for measuring reflections from plane, spherical, cylindrical, and conical mirrors, whether convex or concave.

Huygens found a good solution which Vincenzo Riccati and then Saladini simplified and improved.To find the point of reflection on the surface of a spherical mirror, convex or concave, given the two points related to one another as eye and visible object.

Book VI of the *Optics* examines errors in vision due to reflection while the final book, Book VII, examines refraction [1]:-

Ibn al-Haytham's study of refraction led him to propose that the atmosphere had a finite depth of about 15 km. He explained twilight by refraction of sunlight once the Sun was less than 19° below the horizon.Ibn al-Haytham does not give the impression that he was seeking a law which he failed to discover; but his "explanation" of refraction certainly forms part of the history of the formulation of the refraction law. The explanation is based on the idea that light is a movement which admits a variable speed(being less in denser bodies)...

Abu al-Qasim ibn Madan was an astronomer who proposed questions to ibn al-Haytham, raising doubts about some of Ptolemy's explanations of physical phenomena. Ibn al-Haytham wrote a treatise *Solution of doubts* in which he gives his answers to these questions. They are discussed in [43] where the questions are given in the following form:-

There are strange contrasts in ibn al-Haytham's work relating to Ptolemy. InWhat should we think of Ptolemy's account in "Almagest"I.3concerning the visible enlargement of celestial magnitudes(the stars and their mutual distances)on the horizon? Is the explanation apparently implied by this account correct, and if so, under what physical conditions? How should we understand the analogy Ptolemy draws in the same place between this celestial phenomenon and the apparent magnification of objects seen in water? ...

*Al-Shukuk ala Batlamyus*(Doubts concerning Ptolemy), ibn al-Haytham is critical of Ptolemy's ideas yet in a popular work the

*Configuration*, intended for the layman, ibn al-Haytham completely accepts Ptolemy's views without question. This is a very different approach to that taken in his

*Optics*as the quotations given above from the introduction indicate.

One of the mathematical problems which ibn al-Haytham attacked was the problem of squaring the circle. He wrote a work on the area of lunes, crescents formed from two intersecting circles, (see for example [10]) and then wrote the first of two treatises on squaring the circle using lunes (see [14]). However he seems to have realised that he could not solve the problem, for his promised second treatise on the topic never appeared. Whether ibn al-Haytham suspected that the problem was insoluble or whether he only realised that he could not solve it, in an interesting question which will never be answered.

In number theory al-Haytham solved problems involving congruences using what is now called Wilson's theorem:

Inif p is prime then1+(p -1)! is divisible by p .

*Opuscula*ibn al-Haytham considers the solution of a system of congruences. In his own words (using the translation in [7]):-

Ibn al-Haytham gives two methods of solution:-To find a number such that if we divide by two, one remains; if we divide by three, one remains; if we divide by four, one remains; if we divide by five, one remains; if we divide by six, one remains; if we divide by seven, there is no remainder.

Here ibn al-Haytham gives a general method of solution which, in the special case, gives the solution (7 - 1)! + 1. Using Wilson's theorem, this is divisible by 7 and it clearly leaves a remainder of 1 when divided by 2, 3, 4, 5, and 6. Ibn al-Haytham's second method gives all the solutions to systems of congruences of the type stated (which of course is a special case of the Chinese Remainder Theorem).The problem is indeterminate, that is it admits of many solutions. There are two methods to find them. One of them is the canonical method: we multiply the numbers mentioned that divide the number sought by each other; we add one to the product; this is the number sought.

Another contribution by ibn al-Haytham to number theory was his work on perfect numbers. Euclid, in the *Elements*, had proved:

The converse of this result, namely that every even perfect number is of the form 2If, for some k >1,21^{k}-is prime then21(2^{k-}1)^{k}-is a perfect number.

^{k-1}(2

^{k}- 1) where 2

^{k}- 1 is prime, was proved by Euler. Rashed ([7], [8] or [27]) claims that ibn al-Haytham was the first to state this converse (although the statement does not appear explicitly in ibn al-Haytham's work). Rashed examines ibn al-Haytham's attempt to prove it in

*Analysis and synthesis*which, as Rashed points out, is not entirely successful [7]:-

Ibn al-Haytham's main purpose inBut this partial failure should not eclipse the essential: a deliberate attempt to characterise the set of perfect numbers.

*Analysis and synthesis*is to study the methods mathematicians use to solve problems. The ancient Greeks used analysis to solve geometric problems but ibn al-Haytham sees it as a more general mathematical method which can be applied to other problems such as those in algebra. In this work ibn al-Haytham realises that analysis was not an algorithm which could automatically be applied using given rules but he realises that the method requires intuition. See [18] and [26] for more details.

**Article by:** *J J O'Connor* and *E F Robertson*