As noted above, it was the rulers of the individual Islamic states in al-Andalus who decided whether to support mathematics and other sciences. So why would a ruler support a mathematician? Generally, it was because he felt that the mathematician could contribute to the wealth and, perhaps, the prestige of the kingdom. And a mathematician definitely needed support. Certainly, he could have a non-mathematical position that earned him a living, but it was better for scientific work if he were given the funds so he could spend sufficient time on mathematics. There were no institutional structures in Islamic Spain, or indeed in the Islamic world in general, that would allow a mathematician to flourish. There were no universities and the madrasas, in general, provided instruction in the religious sciences, but not the secular ones.

So, we are left with looking at the relationship between a ruler and a mathematician. We will consider four examples. The first is Abū ‘Abdullah Muḥammad ibn ‘Abdūn (923-976), a mathematician who was born and taught mathematics in Cordova, the capital of the Umayyad caliphate. He became a physician through his studies in the East and then returned to Cordova as the physician of the caliph, al-Ḥakam II. His only known mathematical work is *On measurement*, of which only one copy survives. Many of the methods in this treatise can be found in texts written in ancient Babylon. In fact, ibn ‘Abdūn’s treatise marks the extension of a pre-algebraic tradition of measuring surfaces from the eastern Islamic lands to al-Andalus and, then, to the Maghreb. This treatise is basically a practical manual, and not a theoretical one. It is, therefore, not surprising that the author of such a treatise would be supported. This was mathematics that could be used.

At the beginning of the manuscript of this treatise ibn ‘Abdūn is referred to as *muhandis* and *faraḍī*. The first denotes someone involved with measuring (theoretical or practical, e.g. surveying), and the second denotes a specialist in the arithmetical procedures necessary to calculate the legal heirs’ shares of an inheritance according to Islamic law. The treatise consists of a collection of problems in which the author presented algorithms for finding areas or lengths. He began with rectangles, squares, triangles, and parallelograms, then moved to circles, where he used the standard approximation of 22/7 for \(\pi\) in his calculations. But he also showed knowledge of the old methods of solving what we would call quadratic equations when he asked the reader to find certain lengths given information about areas or diagonals.

In these problems, he did not use the al-Khwārizmīan terminology of “thing” for the unknown and *māl* (treasure) for square. He simply converted all his measurements to numbers and gave an algorithm for finding the answers. The algorithms are like those from ancient Mesopotamia and are ultimately based on manipulation of geometric figures. But ibn ‘Abdūn left out any justification at all, as in the following examples:

If you are told, “We add the sides and the area and it is one hundred forty, what are the sides?” The calculation is that you add up the number of the sides, which is four, and take its half, two. Multiply it by itself, it is four. Add it to one hundred forty, which is one hundred forty-four. Then take the root of that, twelve, and take away from it half of the four and the remainder is equal to each of its sides.

If you are told that the diagonal is ten and one side exceeds the other by two, what are its two sides? The way to calculate this is that you multiply the diameter by itself, which is one hundred, and you multiply the two by itself, which is four, and you subtract it from one hundred. The remainder after that is ninety-six. You take half of that, which is forty-eight, which is the area. Now it is as if you are told, “A rectangle, whose length exceeds its width by two, and its area is forty-eight. What is each of the sides?” So, you work as we described to you [earlier], and you will hit the mark, Allah willing. [Katz *et al*, 2016, 452]

A century after ibn ‘Abdūn, we find another mathematician involved in a very practical subject, spherical trigonometry, the key to the understanding of astronomy. This was ibn Mu‘ādh al-Jayyānī, whose work, the *Book of Unknowns of Arcs of the Sphere*, written probably in the middle of the eleventh century, is the earliest extant work on pure trigonometry that was not written as an introduction to a work on astronomy. The last part of ibn Mu‘ādh’s name suggests that he was from Jaén in Andalusia. He is known to have been a *qādī* (religious judge) and in fact came from a family whose members included several such learned officials. Thus, given that he was active after the end of the Umayyad caliphate, he was probably supported by the ruler of one of the small Islamic kingdoms in the south of Spain. What we do not know is how ibn Mu‘ādh learned his trigonometry. His work is similar to material that had been widely discussed in eastern Islam, but nothing of his book points to any particular known eastern source.

Despite this work being a purely mathematical one, ibn Mu‘ādh obviously intended it to help in the study of astronomy. But it was not an elementary work. As he wrote in the preface,

In this book, we want to find the magnitudes of arcs falling on the surface of the sphere and the angles of great arcs occurring on it as exactly as possible, in order to derive from it the greatest benefit towards understanding the science of celestial motions and towards the calculation of the phenomena in the cosmos resulting from the varying positions of celestial bodies. … So, we present something whose value and usefulness in regard to understanding this [subject] are great. As for premises that were derived by scholars who preceded us, we give just the statements, without proof, so that we may arrive at acknowledgement of their proof. … We have written our book for those who are already advanced in geometry, rather than for beginners. [Katz *et al*, 2016, 503]

There are many possible starting points for the basic results of spherical trigonometry. Ibn Mu‘ādh chose as his starting point the transversal theorem, a theorem well-known from Greek times, although written then in terms of chords rather than Sines (where we use “Sine” to denote the medieval sine, the length of a line segment in a circle of a given radius). This theorem shows the relationship among certain ratios of Sines of arc segments in a figure consisting of four intersecting great circle arcs. Given this result and various similar ones, ibn Mu’adh then set out his goal for the book:

We say that there are two kinds of things found in a triangle, sides and angles. There are three sides and three angles, but there is no way to know the triangle completely, i.e. [all] its sides and its angles, by knowing only two of the six. Rather, from knowing only two things, be they two sides or two angles or one side and one angle, it [the triangle] is unspecified. For it is possible that there are a number of triangles, each of which has those [same] two known things, and so one must know three things connected with it [the triangle] to obtain knowledge of the rest. Thus, it is impossible to attain all of it knowing less than three members: three sides, three angles, two sides and an angle or two angles and a side. [Katz *et al*, 2016, 504]

In other words, ibn Mu’adh’s goal was to solve spherical triangles, given the knowledge of three of the six “things”. On the way to doing this, he proved various important results. For instance, he showed that if the ratio of the Sines of two arcs is known as well as their difference (or their sum), then the arcs are determined. He also demonstrated the spherical law of Sines, “a theorem of great usefulness and abundant benefit in general.”

In any triangle whose sides are arcs of great circles, the ratio of the Sine of each of its sides to the Sine of the opposite angle is a single ratio [Katz *et al*, 2016, 512].

After a long discussion of the properties of right spherical triangles, including results involving Cosines as well as Sines, Ibn Mu‘ādh systematically showed how to solve triangles, when any set of three “things” is known, often by dropping perpendiculars and then using the properties of right triangles. Probably the most difficult of the solutions to accomplish is when all three angles are known, obviously a result that has no parallel in plane trigonometry. (See [Katz *et al*, 2016, 518-520] for the details.)

The two works mentioned above were reasonably practical. After all, measurement was necessary in all sorts of contexts, and spherical astronomy was important for astronomy, which was in turn necessary for calculating the direction and times of prayer. In fact, in a short work ibn Mu‘ādh described how to find the *qibla*, the direction of prayer. On the other hand, he also wrote a very theoretical treatise on ratios, a work explaining in detail Euclid’s definition of ratio in Book V of the *Elements*. (See [Katz *et al*, 2016, 468-478, 530-533] for these two works.) Other mathematicians too worked on quite theoretical material.

For example, consider ibn al-Samḥ (984-1035), who lived in Cordova toward the end of the Umayyad caliphate, when that government was in turmoil. He was a student of the famous astronomer, Maslama al-Majrītī (950-1007), and wrote on astronomy, astrology and mathematics. Evidently, however, he earned his living as a practicing physician. Here, we look at his geometrical text, *The Plane Sections of a Cylinder and the Determination of their Areas*, which today only survives in a Hebrew translation by Qalonymos ben Qalonymos of Provence.

Ibn al-Samḥ’s treatise is in two parts. In the first part, he introduced a figure constructed by what he called a “triangle of movement” and then considered an oblique section of a right circular cylinder, which he knew was an ellipse. He constructed the “triangle of movement” by fixing one side of a triangle and moving the intersection of the other two sides continuously in such a way that the sum of their lengths is constant, although the lengths of each will vary as their intersection moves.

**Figure 3.** The "triangle of movement" of ibn al-Samḥ of Cordova

From a modern point of view, this is one of the construction methods for an ellipse, but ibn al-Samḥ needed to show that this figure and the section of the cylinder share the same properties and therefore are the same figures. In the second part, Ibn al-Samḥ determined the area of the ellipse by relating its area to that of its inscribed and circumscribed circles. To do this, however, he found various ratios among the ellipse, its inscribed and circumscribed circles, and the major and minor axis. For example, he proved that the ratio of the inscribed circle to the ellipse is the same as the ratio of the minor to the major axis. Also, the ratio of the inscribed circle to the ellipse is the same as the ratio of the ellipse to the circumscribed circle.

Finally, the proposition giving the area of an ellipse is phrased in a way that echoes Proposition 1 of Archimedes’ *Measurement of the Circle*, each expressing the area of a curved figure (an ellipse in the one case, a circle in the other) in terms of a certain right triangle. Further, he actually calculated the area:

Every ellipse is equal to the right triangle of which one of the sides containing the right angle is equal to the circumference of the inscribed circle and of which the second side is equal to half of the greatest diameter. It results from what we have established that if we take five sevenths and one half of one seventh of the smallest diameter, and multiply this by the greatest diameter, we obtain the area of the ellipse. [Katz *et al*, 2016, 467]

Another important mathematician from Spain at this time was Al-Mu’taman Ibn Hūd (d. 1085). Until recently his works were thought to have been lost, but in the late 1980s Professors Ahmed Djebbar and Jan Hogendijk discovered manuscripts of his extensive survey of the mathematics of his time, his *Kitāb al-Istikmāl* (*Book of Perfection*). Ibn Hūd had planned for the book to have two “genera” but he had only finished the first when he became King of Saragossa, one of the small Islamic kingdoms on the peninsula, in 1081 and evidently had no time to write the second before he died four years later. Ibn Hūd had an elaborate division of his “genera” into species, subspecies, and sections. The work, definitely not intended for beginners, sheds unexpected light on the mathematics of Ibn Hūd’s time and is a fascinating blend of mathematics from Greek and Arabic sources, as well as what appear to be some original contributions of ibn Hūd himself. Obviously, given his position as a member of the dynasty that ruled Saragossa from 1038 to 1110, he was free to study whatever mathematics he wished. He clearly had the means to immerse himself in translated Greek mathematics and then to work on problems coming from these Greek sources. Consider these samples from the *Book of Perfection*:

[Heron’s Theorem:] [For] each triangle the ratio of the surface that is made of half the sum of its sides by the excess of that half over one of the sides to the surface of the triangle is as the ratio of the surface of the triangle to the surface that is made from the excess of half the sum of the sides over one of the two remaining sides by [the excess over] the other [Katz *et al*, 2016, 479].

Ibn Hūd’s proof was different from the one given by Heron. It made central use of the incircle of the triangle, the triangle whose center is the intersection of the angle bisectors of the triangle and which is tangent to all three sides.

Ibn Hūd also stated and proved a theorem thought to have been first stated by the Italian geometer Giovanni Ceva in 1678.

[Ceva’s Theorem:] In every triangle in which from each of its angles a line issues to intersect the opposite side, such that the three lines meet inside the triangle at one point, the ratio of one of the parts of a side of the triangle to the other [part], doubled with the ratio of the part [of the side] adjacent to the second term [of the first ratio] to the other part of that side is as the ratio of the two parts of the remaining side of the triangle, if [this last] ratio is inverted, and conversely [Katz *et al*, 2016, 483].

Probably the greatest accomplishment of ibn Hūd was his study of a famous problem in geometrical optics generally referred to as “Alhazen’s Problem”, which concerns reflection in mirrors whose surfaces are curved. (Alhazen is the Latin version of the name of ibn al-Haytham (965-1039), who discussed this problem is his famous work on optics.) Suppose one is given a spherical or conical mirror, concave or convex, and an object (thought of as being a point) visible in the mirror to an observer (represented by another point). The question is: At what point on the mirror will the observer see the object? As part of his solution to this problem, ibn al-Haytham gave six difficult geometrical lemmas, which were adapted by ibn Hūd in his *Istikmāl*. In some cases ibn Hūd followed ibn al-Haytham’s ideas, but in a number of cases he introduced new techniques, which simplified and shortened ibn al-Haytham’s proofs.

It is clear that the men we have discussed were quite able mathematicians. How did a mathematician operate in Muslim Spain? In general, as we suggested earlier, a mathematician needed another career to provide support, such as medicine or as a religious functionary, or else he needed to be supported by – or in the case of ibn Hūd, actually was – the ruler of the state in which he lived. There was no structure in this society that could support a steady flow of intellectual development, such as a university. If one wanted to study a particular field, one had to find an expert with whom to study. Since Spain at this time was far from the center of the Islamic domains, someone who wanted to study some advanced mathematical topic had to go to the east – to Egypt or Persia or Baghdad. But there certainly were people able to produce interesting mathematics in Muslim Spain. As we have seen in our examples, they restricted themselves to certain topics, in particular, geometry and trigonometry. Obviously, both of these were based on Euclid’s *Elements*, which had been translated many times into Arabic, beginning in the ninth century, while the latter topic was necessary for astronomy. But Muslim mathematicians had also read Archimedes, Apollonius, and Ptolemy, among other Greek authors. They certainly absorbed the Greek notion of mathematical proof, and we see this demonstrated in treatises written in Spain. Sā‘id names many other mathematicians active in al-Andalus up to the mid-eleventh century besides the ones mentioned above, but in virtually all cases, their fields of mathematical interest were geometry and trigonometry.

Although Muslim authors in the East were developing algebra during the period of Islamic rule in Spain, there is little evidence that any algebraic work more advanced than that of al-Khwārizmī was studied in Spain. In fact, the algebra that did appear in Spain is more closely related to the older geometric strain of the subject than to the more modern use of unknowns. Furthermore, even though Averroes (1126-1198) translated and commented extensively on the work of Aristotle, and his translations were quite influential later in Catholic Europe, Muslim mathematicians did not attempt to develop any of the mathematics implied by some of Aristotle’s physical ideas.

There is little evidence that there were any religious restrictions to the practice of mathematics in Spain. So, the reasons why one topic or another was studied or not were practical, such as the availability of teachers, or, more simply, had to do with the inclinations of a particular mathematician.

To complete the story, note that after the Battle of Navas de Tolosa, in 1212, in which Catholic armies defeated the Almohads, the Muslims rapidly lost control of most of Spain. In fact, Cadiz and Cordoba were conquered by the Catholics in 1236 and Seville in 1248. Muslim Spain was then reduced just to Granada, a province in which little mathematics was done in the next two hundred years. That is not to say that Muslims in the West stopped doing mathematics. There was certainly significant mathematics done in the twelfth and thirteenth centuries in North Africa, an area culturally similar to al-Andalus. This work included important contributions to combinatorics in the work of ibn Mun’im (d. 1228) and ibn al-Bannā’ (1256-1321), and the introduction of new algorithms for calculating with the Hindu-Arabic numerals by Abū Bakr Muḥammad al Hassār (12th century), some of whose ideas were taken over by Leonardo of Pisa in his *Liber abbaci*. (See the article "Moses ibn Tibbon's Hebrew Translation of al-Hassar's Kitab al Bayan" in *Convergence*.) But the discussion of these works would take us outside of the boundaries of Europe.