Little known book, Kitab al-Asrar, by the Andalusian engineer Ibn Khalaf al-Muradi. In this treatise, Al-Muradi describes how to construct a wide variety of ingenious mechanical devices. Using written instructions and diagrams, al-Muradi’s work describes 31 models, consisting of 15 clocks, 5 large mechanical toys (automata), 4 war machines, 2 machines for raising water from wells and one portable universal sundial. In this paper attention is focused on three clocks: Solar rays’ clock, Double barrel 24-hour clock and the Gazelles clepsydra. 3D animations are constructed to reveal details of the workings of the mechanisms.
After the incorporation of the heritage of science and technology inherited from ancient cultures, the scientific tradition of the Islamic world developed a genuine and original knowledge in the field of science and technology. Unfortunately, only a meagre mention is made in school curricula and popular history of science book of a great many contributions, discoveries and inventions from Muslim civilisation. The figure below shows diagrammatically a rudimentary timeline of the various civilisations who contributed over the centuries after ancient Mesopotamia, Egypt and earlier civilisations. The grey colours are what is taught by our educational establishments, showing a gap of more than a thousand years used to be referred to as the Dark Ages (or more recently, the medieval ages). As one can see, the gap in the grey misses the Indian, Persian, Chinese and in a big way, Muslim civilisation, shown in yellow. It is surprising to notice that Al-Andalus (Spain and Portugal when were Muslim) are not included, albeit are European. If one includes the scientific advances from Al-Andalus, Europe would not have the so-called Dark Ages. Such a major anomaly must be corrected for a stable future socio-political environment in Europe and America.
In early Muslim civilisation, people, in general, were driven by a new spirit, fuelled by a faith constituted in the Qur’an and the sayings and tradition of Prophet Muhammad. Central to the requirements of the faith is to undertake deeds that serve the community and care for the environment, and thus pleasing God (Allah in Arabic). Seeking knowledge and investigating the physical world was not only for the purpose of recognising the wonders of creation, but also to serve society by delivering cures, inventing medicines, erecting hospitals and learning institutions, inventing instruments and engineering systems, providing water to both humans and animals, taking care of resources bestowed by Allah, including trees, water and land, improving agricultural methods, and seeking solutions to socio-economic problems.
A typical example of the kind of reasoning that was engendered by this spirit is the short introduction written by the Taqi al-Din (Ottoman-Syrian scientist/engineer/astronomer) who built gravity and spring-driven clocks in Istanbul. In his treatise Al Kawakib Al Duriyyah fi Wad il Binkamat al Dawriyyah (‘The Brightest Stars for the Construction of the Mechanical Clocks’) written in Nablus in 1559, he said:
“My Lord, You are the one who has created motion and stillness. You have revealed scopes of knowledge out of the world hidden beyond the horizon. You have placed in the motion of wheels and balls minuscule truths and minute signs. You have enabled blessed minds to receive Your unceasing grace and enjoy what Your light reveals. My Lord, I pray You to shower Your peace and blessings on the one who has proclaimed Your attributes and declared Your revealed book, Muhammad, Your chosen servant and messenger. My Lord, grant Your blessings also to his household and his companions, who have diligently transmitted his message. My Lord, grant us what we hope for and make our final days full of good useful deeds. You are the One who is able to accomplish whatever You will, and who is certain to answer sincere prayers”.
We see a similar narrative in the title of Al-Jazari’s, Al Jami’ Bainal Al I’lm wal A’mal al Nafi’ fi Sina’at al Hiyal. In this tile, Al-Jazari refers to the link between science (I’lm) and useful deeds (A’mal al Nafi’) in the mechanical arts.
Such a spirit was widely spread across the Muslim world. That is, perhaps, why we see that many of the scientific and engineering developments were directed more towards social and public benefit.
Timekeeping and the instruments for measuring time accurately by different means were prominent societal features. Clocks witnessed a great development in variety, forms, mechanisms, and operations. The models used included candle clocks, geared mechanisms, the invention of flow regulators and the improvement of water clock technology in some of Banū Mūsā’s automatic and timing devices. Some of those clocks were described in precious manuscripts such as those of Damascus. Information also survived about the clocks of Iraq, those of Al-Mustanṣiriya clock in Baghdad and the clocks of Northern Euphrates (Miyāfariqīn and Nāṣiriyah). In Muslim Spain, a tradition of technology of clocks emerged with Abbas ibn Firnas, Al-Muradi and Al-Zarqali.
The phenomenon of the public display of beautiful and technologically sophisticated clocks was not confined to the Muslim East. Water clocks were also a common feature of urban life in the Maghrib, the Muslim West, which consists of Al-Andalus and the modern-day states of Morocco, Algeria, Tunisia, Libya and Mauritania. Like their counterparts in Syria and Iraq, the clocks of the Maghrib were almost always found in and around mosques and madrasas in the great cities of learning and culture, such as Fez, Marrakesh, Al-Qairawan and Tlemcen.
In this paper, we focus on the clocks of Al-Muradi, a little known Andalusian mathematician/astronomer/engineer, who perhaps deserves equal recognition to that given to Al-Jazari.
Ibn Khalaf al-Muradi, author of Kitab al-Asrar fi Nataij al-Afkar (‘The Book of Secrets about the Results of Ideas’) possibly thrived in the 11th century. According to Donald Hill, Al- Muradi invented the first geared clock, which was a water clock that utilised a complex gear train mechanism that included both segmental and epicyclic gearing, capable of transmitting high torque.
Al-Muradi’s clocks were also the first to also employ mercury in their hydraulic linkages, which solved the problem of water behaving differently according to room temperature.
Unfortunately, we know little about his life, not even his date of birth or death. Julio Samsó wrote an excellent critical review of Al-Muradi’s treatise and its translation in which he suggests his full name might have been Ahmad (or Muhammad) ibn Khalaf al-Muradi, possibly dwelled in Toledo at the time of Yahya Al-Mamun (of Banu Dh-Nun, a Berber dynasty who ruled Toledo during the eleventh century), who sponsored numerous technological marvels. Al-Muradi should not be confused with the Astronomer Ali ibn Khalaf al-Saydalani, who was an Andalusian mathematician and astronomer who belonged to the scientific circle of Saʿid al- Andalusi and who was a contemporary of the famous astronomer instrument maker Al-Zarqali  (Abu Ishaq Ibrahim al-Zarqali who was born in Toledo possibly in 1029 and died in Cordoba possibly in 1100).
Al-Muradi’s kitab al-Asrar is a treatise on how to construct a wide variety of ingenious mechanical devices. Using written instructions and diagrams, al-Muradi’s work describes 31 models, consisting of 15 clocks, 5 large mechanical toys (automata), 4 war machines, 2 machines for raising water from wells and one portable universal sundial. The manuscript is preserved in the Biblioteca Medicea Laurenziana in Florence. This is the only known extant copy of the text, although it is unlikely that it is the original manuscript authored by Al-Muradi himself, as the date of completion indicated on the manuscript is 21st Sha’ban 664 H (1266 CE). The Florence manuscript was made in the court of Alfonso X in Toledo and it is thought to be an exact copy of the original. Alfonso X (r.1252-1282) is known in Spanish as ‘Alfonso el Sabio’ (Alfonso the Wise), because of the translation initiative that he set up in Toledo. He gathered a group of Jewish and Christian translators/authors who compiled an important collection of scientific texts, to translate the great works of the Arabic intellectual tradition into Castilian (the then regional language of central Hispania).
The use of mercury by al-Muradi points to his being an Andalusi scholar, because the cinnabar mines of Almadén (south of Madrid) produced mercury since Roman times. Mercury is also used in an Alfonsine clock. This leads us to an important topic for research: the Book of Secrets was copied in Toledo during Alfonso X’s reign and the manuscript contains a note in Arabic, but in Hebrew script, by Ishaq b. Sid, one of the two main scientific collaborators of the king (the other one is Yehudah ben Mosheh). Ishaq says he has reconstructed al-Muradi’s machines and he seems to be the author of the Alfonsine clocks. What is the relation between al-Muradi’s and Alfonso’s clocks is a question needs answering by researchers.
In 2008, the Book of Secrets was published in facsimile, translated into English/ Italian/ French/Arabic and in an electronic edition with all machines interpreted in 3D, by the Italian Leonardo3 Study Centre for the Qatar Museums Authority.
The history of the manuscript’s journey from Toledo to Italy has yet to be written. The note must be taken of the work at the Bibliotheca Laurenziana in Florence, which was made out of the original at Toledo. It so happens that this is precisely the route followed by a certain Brunetto Latini, a Florentine envoy, who also resided at Alfonso’s court at the time, and who was very much interested in the scholarly activities there, and who returned to his Florentine origins subsequently. Oddly enough, soon after his return, there was a flurry of technological breakthroughs in northern Italy. This is very certainly the route. It is possible, though less likely, that two brothers, Giovanni Battista and Gerolamo Vecchietti, brought it to Rome in the late 16th century. Upon instruction by Pope Gregory XIII and Cardinal Fernando de’Medici, these brothers gathered non-Latin manuscripts and brought them back to Rome in order that they might be translated into Latin and published in the new Medicea Oriental Printing House. The brothers visited Syria, Persia, Egypt, the Maghrib, Spain and India on their mission of gathering knowledge of non-Latin civilisations.
The 15 water clocks described by Al-Muradi are similar to those described by Ridwan al-Sa’ati and Al-Jazari in that they function through a floating orbit that descends slowly inside a water tank and operates, through its movement, all the gears. The hours are signalled by small ball bearings, by the movement of automata, or by the illumination of lanterns. Similar water clocks can be found in Al-Jazari’s treatise, which antedates Al-Muradi’s manuscript by nearly 60 years. Al-Jazari not only describes similar machines but mechanisms very similar to those in Al-Muradi’s treatise. These include the expulsion of ball bearings and their transfer via tubes, as well as statues, snakes and the way in which they are loaded and expelled, which is exactly the same as those found in Al-Jazari’s work. A feature that distinguishes Al-Muradi’s machines quite sharply from those described by Al-Jazari is their sheer scale. In contrast to Al-Jazari, who emphasises delicate mechanisms and controls, Al-Muradi’s clocks and other machines are large and powerful. There are no conical valves, delay systems, feedback controls, or the use of small variations in atmospheric pressure – all features regarded as typical of Arabic clock technology. In Al-Muradi’s work, ruggedness replaces delicacy. For example, his approach to intermittent operation is to use ropes instead of strings, large wheels up to 3 spans in diameter, and spanning wheels weighing up to 1.5 ratls (approx. 3kg).
Three of the more sophisticated clocks that Al-Muradi presented in his ‘Book of Secrets’, ‘The clock with twenty-four doors and twelve mirrors’ and the ‘Clepsydra of the Gazelles’ are described below:
Al-Muradi refers to this clock as “the seventh figure”; a clock using solar light (see the relevant two pages of the manuscript shown in Figure 1). This clock was reconstructed using engineering graphics software as shown in Figure 2 and then rendered with colours, see figure 3. It uses a float in a long cylindrical tank of water with an orifice at the bottom (outflow clepsydra). As the water is discharged to the lower reservoir, the surface level is lowered. A float is placed on top of the surface, which is connected to a rope that goes around a pulley and then wraps around a circular disc mounted on a horizontal shaft, see Figure 4. The disc has a small circular hole that acts as an aperture for light to pass through. Behind this circular disc is another circular disc fixed to the body of the clock. Mounted on the rim is a series of 12 mirrors placed at 15 Degrees angular intervals, see Figure 5. Each mirror is inserted into a recess on the rim and positioned so that it directs sunlight onto a distant wall. As the sun moves over the sky from sunrise to sunset the mirrors project the light spot onto the wall. The light spots on the wall are marked in an arc with numbers from 1 to 12, see Figure 6. The rotating circular disc blocks the sunlight from the mirror only allowing the rays that pass through the hole aperture. When the hole reaches a mirror location it allows the sunlight to touch the mirror and reflects it onto the location on the wall indicating the hour of the day.
On the face of this clock, there are 24 doors, arranged in two rows of 12. Beneath these two rows of doors are 12 round windows arranged evenly in the shape of an arch. Beneath either end of this arch is the bust of a lion’s head, each with a vase directly below it, see Figure 7.
Behind the face of the clock is the body of the clock, enclosed in a wooden chamber, see Figures 8 and 9. It contains two tanks of water (A), each located on either end of the chamber. Each tank contains afloat (B) connected to a rope that is wrapped around a pulley in the centre of the chamber. The circumference of the wheel of the pulley is equal to the maximum distance that the float moves in its straight descent to the bottom of the water tank. This wheel is fixed, by means of an axle, to the centre of a larger wheel (D), which is divided into twelve parts, equivalent to the number of (temporal) hours of the day or the night. Either side of this large wheel is a round vessel (E) containing ball bearings. The rotation of the large wheel allows these ball bearings to be released at the moment of the elapsing of an hour and fall into a tube that carries them through the body of the clock to the open mouth of each lion head, from where they drop down into the brass vases. The ball bearing striking the bottom of the vase creates a chiming sound to indicate the elapsing of one complete hour. Simultaneously, one of the twenty-four doors opens, corresponding to the hour that has just elapsed. There is also a shift lever/lever/lever arm/crank arm (G) that is fixed to the centre of the large wheel, which carries a mirror that appears in the apertures of the twelve round windows to indicate silently the elapsing of one hour during the night.
A complete view of the clock from the rear is given in Figure 10. It shows the way in which the ropes are connected to all the weights and doors. It also shows the position of the water tanks and the storage vessels for the ball bearings in relation to the other parts of the clock.
Here is an explanation of how the door mechanism works (see Figure 11): When the time comes for the appropriate door to open, the rope (A) is pulled downward. Thus, the pulley (B) turns around its axle, pulling the two ropes (C). This in turn pulls the door open. When the time comes for the door to be closed, the rope ceases to be pulled down through path (A). Thus, the pulley (B) turns in the opposite direction due to the downwards force of the weight (D) connected to the rope that is wrapped around the pulley (E). This movement pulls the two ropes connected to the pulleys (F), which closes the door.
The Clepsydra of the Gazelles
In the ‘Book of Secrets’, Al-Muradi describes another captivating clock, which has come to be known as the Clepsydra of the Gazelles because of the numerous gazelle automata that it contains. In the early 1990s, Eduard Farré Olivé made a number of reconstructions, which worked successfully, of the clepsydra and published his analysis of it in 1998 in the journal Arte y Hora. He based his reconstructions on the explanations given in 1982 by Juan Vernet and Rafael Casals of the University of Barcelona deciphered the manuscript that contained instructions on how to construct this clepsydra and published their findings, His reconstructions, see Figure 12, and explanations of how the device worked have gained wide acceptance. The following section is based primarily on that 1998 article.
The Clepsydra of the Gazelles has 10 moving automata: two girls, four gazelles, a slave, and three snakes. When the clock is at rest, the position of the girls is inside a pavilion behind sliding doors. In front, there is an octagonal courtyard with a well in the centre, around which are standing four gazelles. In front of each gazelle is a watering hole and there are three more watering holes between the pavilion doors and the well.
Like most water clocks of the time, the Clepsydra of the Gazelles is built such that the automata move and act out a scene at the elapsing of each hour of the day or night. The movement of the automata at the end of an hour is as follows: the pavilion doors open and the girls move out into the courtyard whilst the four gazelles dip their heads into the watering holes to drink. After a short pause, a slave figure emerges up from the well and simultaneously three snakes pops-out of the three holes between the pavilion and the well, directly in the path of the girls. The snakes’ appearance then triggers new movements, mimicking the real-life surprise that would come about as a result of seeing three snakes suddenly appearing on the scene: the gazelles raise their necks as if on alert, the girls ‘flee’ back into the pavilion and close the door behind them and the slave moves back down into the well as if hiding. A few moments later, the snakes return back down their holes to their starting position under the courtyard floor.
The Clepsydra of the Gazelles had a cyclical mechanism that ensured – barring any unforeseen interruption – its movement was continuous throughout the day with no need for any external intervention. Only at the end of the day, when all the water had exited out of the system through a drainage valve in the bottom of the clock, did a person have to physically renew the water and put everything back in its place in preparation for the next cycle of operation.
The internal mechanism of the clocks operates as follows (see Figure 13): Over the course of an hour, although there is no movement of automata, the insides of the clock are working continuously. There is a ceaseless and precise outflow of water from a central water-tank that successively fills a series of chambers. As with all water clocks, it is the accurate calibration of this incoming water flow that is the time-keeping mechanism of the clock. The first chambers to fill are the gazelles drinking holes, followed by the well, then the central chamber with a concentric siphon. The water flow is calibrated so that the siphon fills up in just under an hour.
The emptying of the water from these chambers generates the movement of the automata, which is the second phase of operation over the course of an hour. This happens in the following order: when the siphon is full it empties its contents in the highest tank of the scales that are located in the body of the clock. These scales have a tube of mercury that forms the arm of the scales. When the weight of the water in the tank becomes greater than the weight of the mercury the scales suddenly move, triggering several mechanisms. These, in turn, close a valve that re-routes the water towards the second tank on the scales, opens the doors to the pavilion, move forward the carriage that carries the two girl figurines, and releases the gazelles’ necks so that their head tip forward and down into the drinking position. The tipping forward of the head of one of the gazelles activates a switch mechanism hidden in the watering hole, which empties the water out of the gazelles’ tanks into a water tank on a scale that causes the slave figurine to begin to move upwards. When the water tank is full, the slave appears out of the well, simultaneously opening his own drainage valve. The water then flows out of the slave figurine’s tank and moves to another water tank on another pair of scales that causes the snakes to move.
All of the water tanks empty gradually through a hole in their base, and the scales and the rest of the moving parts return to their original positions. The rate at which the water drains out of the hole determines the length of time it takes for the scales and other moving parts to return to their original positions. The scales that move the girls and those that move the slave have large holes, which mean that they return quickly to their starting position. The snakes, on the other hand, move slowly due to their small drainage holes.
An important condition for the smooth operation of this machine was the use of filtered water so that mineral residue or dirt from the water would not be left on its mechanisms. It had to be cleaned regularly and oiled lightly in order to ensure smooth running and to make sure that its conical valves (under the girls, the gazelle’s mouth, and the slave) closed completely with a watertight fit. It was very common to find in treatises on water clock manufacture sections that dealt at great length with methods to purify water for use in a water clock.
By the use of engineering graphics software, the details of the clocks were drawn so as to allow workshop technicians to manufacture all the parts. For the purpose of ease of visualisation of how the parts work together, 3D animations were produced and as shown in the following videos.
This work wouldn’t have been realised had it not been for the assistance of many colleagues. Of particular, I like to express gratitude to Prof. Julio Samsó for correcting the confusion found in the literature about Ibn Khalaf Al-Muradi, as being different from Ibn Khalaf al-Saydalani, both of whom were Andalusian and thrived in Toledo. Thanks are due to Abdulkader Jahjah who prepared the engineering drawings and the 3D animations.
 D. R. Hill: A History of Engineering in Classical and Medieval Times, (Abingdon (UK) 1996), p.203
 Julio Samsó’s review of the Italian edition and translation (into English) in Suhayl 9 (2009-10), pp 234-238.
See also Julio Samsó, Andalusian Astronomy in the Eleventh Century, Inference-Review, Vol. 5, No. 3 / September 2020. https://inference-review.com/article/andalusian-astronomy-in-the-eleventh-century.
 Calvo, Emilia (22 September 2017). “Some Features of the Old Castilian Alfonsine Translation of ʿAlī Ibn Khalaf’s Treatise on the Lámina Universal”. Medieval Encounters. 23 (1–5): 106–123. doi:10.1163/15700674-12342244.
 C. Dawson: Medieval Essays, (London, 1953), pp.129
Hill D.R, Arabic Water Clocks, p. 37. The portable universal sundial may have been an addition to the original source. See Julio Samsó’s review of the Italian edition and translation (into English) in Suhayl 9 (2009-10), pp 234-238.
 Introduction to the English version of ‘The Book of Secrets in the Results of Ideas’, edited by Leonardo3 Research Centre for the Qatar Museums Authority, p.11
 There appear to have been no Muslims in the group; the only known name belonging to this category was a fellow called “Bernardo el Arábigo” who was clearly a Muslim who had converted to Christianity.
 The Book of Secrets of al-Muradi , facsimile, translated in English/Italian/French/Arabic and in an electronic edition with all machines interpreted in 3D, by the Italian Leonardo3 Study Centre for the Qatar Museums Authority. 2008.
 D.R. Hill: Islamic; op cit, p. 142.
 F. Reichmann: The Sources of Western Literacy; Greenwood Press; London; 1980; p. 203.
 ‘The Book of Secrets’, p.11
 Hill D.R., Arabic Water Clocks, p.39
 ‘The Book of Secrets’, p.23
 Hill D.R., Arabic Water Clocks, p.39
 Eduard Farre Olive: ‘La Clepsidra de las Gacelas del Manuscrito de Relojes de al-Muradi’, Arte y Hora, no. 128H11, March-April 1998, pp.10-18