The wafq: magic squares in the medieval Islamic world
A history of the wafq, the Arabic numerical square: from the Brethren of Purity to al-Būnī, the word buduḥ and the passage of magic squares into Europe.
In the medieval Islamic world numerical squares had a precise name: wafq, a term that evokes the idea of agreement and harmony. Mathematicians, philosophers and authors of treatises on the occult properties of letters studied them for centuries. It was in this milieu that the tradition of magic squares developed systematically, before passing into Europe through Spain and the Latin translations of the central Middle Ages.
Mathematics and cosmic harmony
Among the earliest Arabic sources presenting squares of different orders are the Epistles of the Brethren of Purity, a philosophical encyclopaedia composed in Basra, probably in the tenth century, by a group of authors who remained anonymous. Neo-Pythagorean in outlook, they saw numbers as the key to the order of the universe and treated the squares as images of cosmic harmony. Their interest was both mathematical and symbolic, in an approach that did not separate the two fields.
In the following centuries Arabic- and Persian-speaking mathematicians worked out general methods for constructing squares of even and odd order, bordered squares that remain magic even when the outer frame is removed, and other complex variants. These studies, long ignored by histories of mathematics written in Europe, show remarkable arithmetical skill that went far beyond talismanic use and that historians of science have only recently given its due.
Letters, numbers and protection
Alongside mathematics there developed the “science of letters”, which assigned a numerical value to each letter of the Arabic alphabet. The name most associated with this tradition is al-Būnī, who died in Cairo in 1225 and to whom the Shams al-maʿārif, the “Sun of Knowledge”, is attributed. The text circulating today under this title, however, contains many later additions, and scholars carefully distinguish his authentic works from those handed down under his name.
The square of order three enjoyed a special fortune. Its corners hold the numbers two, four, six and eight, which in Arabic letters spell the word buduḥ. This word, considered to have a power of its own, was engraved on rings, bowls and textiles, and in popular tradition it was associated above all with the protection of women in childbirth. Many texts link it to the name of the theologian al-Ghazālī, but the attribution is traditional and undocumented.
From the Islamic world to Europe
Knowledge of the squares reached the Latin West together with Arabic astrology and astral magic. Treatises translated into Latin in the late Middle Ages associated the squares with the seven planets, and from this tradition derive the tables Agrippa published in the sixteenth century. Latin manuscripts often show different arrangements of the numbers, a sign of complex transmission through successive copies and reworkings.
In the Islamic world the tradition continued without interruption into the modern era. Numerical squares appear on metal bowls known as “magic-medicinal bowls”, on rolled paper amulets and on ceremonial garments such as the Ottoman talismanic shirts. Many of these objects are now held in museums in Istanbul, Cairo and Europe, and they document a practice that was widespread across all levels of society.
To study the wafq is to recognise how much European culture owes to the Islamic world in this field too. Before becoming planetary tables in Agrippa's books, magic squares were objects of refined calculation and symbols of harmony. Their history runs through Basra, Cairo, Toledo and Cologne, and shows how ideas travelled across the Mediterranean together with manuscripts and their readers.
