Brahmagupta ( – ) was an Indian mathematician and astronomer who is credited as the first person to understand and formalize the concept of the number zero for nothing in mathematics. He is the author of two early works on mathematics and astronomy: the Brāhmasphuṭasiddhānta (BSS, "correctly established doctrine of Brahma", dated 628), a theoretical treatise, and the Khandakhadyaka ("edible bite", dated 665), a more practical text. He is also credited with the first clear description of the quadratic formula (the solution of the quadratic equation)Bradley, Michael. The Birth of Mathematics: Ancient Times to 1300, p. 86 (Infobase Publishing 2006) in his main work, the Brāhma-sphuṭa-siddhānta.Mackenzie, Dana. The Universe in Zero Words: The Story of Mathematics as Told through Equations, p. 61 (Princeton University Press, 2012).

Life and career Brahmagupta, according to his own statement, was born in 598 CE. Born in Bhillamāla in Gurjaradesa (modern Bhinmal in Rajasthan, India) during the reign of the Chavda dynasty ruler Vyagrahamukha. He was the son of Jishnugupta and was a Hindu by religion, in particular, a Shaivite.: "Brahmagupta, one of the most celebrated mathematicians of the East, indeed of the world, was born in the year 598 CE, in the town of Bhillamala during the reign of King Vyaghramukh of the Chapa Dynasty." He lived and worked there for a good part of his life. Prithudaka Svamin, a later commentator, called him Bhillamalacharya, the teacher from Bhillamala.

Bhillamala was the capital of the Gurjaradesa, the second-largest kingdom of Western India, comprising southern Rajasthan and northern Gujarat in modern-day India. It was also a centre of learning for mathematics and astronomy. He became an astronomer of the Brahmapaksha school, one of the four major schools of Indian astronomy during this period. He studied the five traditional Siddhantas on Indian astronomy as well as the work of other astronomers including Aryabhata I, Latadeva, Pradyumna, Varahamihira, Simha, Srisena, Vijayanandin and Vishnuchandra.

In the year 628, at the age of 30, he composed the Brāhmasphuṭasiddhānta ("improved treatise of Brahma") which is believed to be a revised version of the received Siddhanta of the Brahmapaksha school of astronomy. Scholars state that he incorporated a great deal of originality into his revision, adding a considerable amount of new material. The book consists of 24 chapters with 1008 verses in the ārya metre. A good deal of it is astronomy, but it also contains key chapters on mathematics, including algebra, geometry, trigonometry and algorithmics, which are believed to contain new insights due to Brahmagupta himself.

Later, Brahmagupta moved to Ujjaini, Avanti, a major centre for astronomy in central India. At the age of 67, he composed his next well-known work Khanda-khādyaka, a practical manual of Indian astronomy in the karana category meant to be used by students.

Brahmagupta died in 668 CE, and he is presumed to have died in Ujjain.

Works Brahmagupta composed the following treatises:

Brāhmasphuṭasiddhānta, composed in 628 CE. Khaṇḍakhādyaka, composed in 665 CE. Grahaṇārkajñāna, (ascribed in one manuscript)

Reception Brahmagupta's mathematical advances were carried on further by Bhāskara II, a lineal descendant in Ujjain, who described Brahmagupta as the ganaka-chakra-chudamani (the gem of the circle of mathematicians). Prithudaka Svamin wrote commentaries on both of his works, rendering difficult verses into simpler language and adding illustrations. Lalla and Bhattotpala in the 8th and 9th centuries wrote commentaries on the Khanda-khadyaka. Further commentaries continued to be written into the 12th century.

A few decades after the death of Brahmagupta, Sindh came under the Arab Caliphate in 712 CE. Expeditions were sent into Gurjaradesa ("Al-Baylaman in Jurz", as per Arab historians). The kingdom of Bhillamala seems to have been annihilated but Ujjain repulsed the attacks. The court of Caliph Al-Mansur (754–775) received an embassy from Sindh, including an astrologer called Kanaka, who brought (possibly memorised) astronomical texts, including those of Brahmagupta. Brahmagupta's texts were translated into Arabic by Muḥammad ibn Ibrāhīm al-Fazārī, an astronomer in Al-Mansur's court, under the names Sindhind and Arakhand. An immediate outcome was the spread of the decimal number system used in the texts. The mathematician Al-Khwarizmi (800–850 CE) wrote a text called al-Jam wal-tafriq bi hisal-al-Hind (Addition and Subtraction in Indian Arithmetic), which was translated into Latin in the 13th century as Algorithmi de numero indorum. Through these texts, the decimal number system and Brahmagupta's algorithms for arithmetic have spread throughout the world. Al-Khwarizmi also wrote his own version of Sindhind, drawing on Al-Fazari's version and incorporating Ptolemaic elements. Indian astronomic material circulated widely for centuries, even making its way into medieval Latin texts.

The historian of science George Sarton called Brahmagupta "one of the greatest scientists of his race and the greatest of his time."

Mathematics Algebra Brahmagupta gave the solution of the general linear equation in chapter eighteen of Brahmasphuṭasiddhānta,

The difference between rupas, when inverted and divided by the difference of the [coefficients] of the [unknowns], is the unknown in the equation. The rupas are [subtracted on the side] below that from which the square and the unknown are to be subtracted.

which is a solution for the equation where rupas refers to the constants and . The solution given is equivalent to .

He further gave two equivalent solutions to the general quadratic equation

18.44. Diminish by the middle [number] the square-root of the rupas multiplied by four times the square and increased by the square of the middle [number]; divide the remainder by twice the square. [The result is] the middle [number]. 18.45. Whatever is the square-root of the rupas multiplied by the square [and] increased by the square of half the unknown, diminished that by half the unknown [and] divide [the remainder] by its square. [The result is] the unknown.

which are, respectively, solutions for the equation equivalent to,

and

He went on to solve systems of simultaneous indeterminate equations stating that the desired variable must first be isolated, and then the equation must be divided by the desired variable's coefficient. In particular, he recommended using "the pulverizer" to solve equations with multiple unknowns.

18.51. Subtract the colors different from the first color. [The remainder] divided by the first [color's coefficient] is the measure of the first. [Terms] two by two [are] considered [when reduced to] similar divisors, [and so on] repeatedly. If there are many [colors], the pulverizer [is to be used].

Like the algebra of Diophantus, the algebra of Brahmagupta was syncopated. Addition was indicated by placing the numbers side by side, subtraction by placing a dot over the subtrahend, and division by placing the divisor below the dividend, similar to our notation but without the bar. Multiplication, evolution, and unknown quantities were represented by abbreviations of appropriate terms. "he was the first one to give a general solution of the linear Diophantine equation ax + by = c, where a, b, and c are integers. [...] It is greatly to the credit of Brahmagupta that he gave all integral solutions of the linear Diophantine equation, whereas Diophantus himself had been satisfied to give one particular solution of an indeterminate equation. Inasmuch as Brahmagupta used some of the same examples as Diophantus, we see again the likelihood of Greek influence in India – or the possibility that they both made use of a common source, possibly from Babylonia. It is interesting to note also that the algebra of Brahmagupta, like that of Diophantus, was syncopated. Addition was indicated by juxtaposition, subtraction by placing a dot over the subtrahend, and division by placing the divisor below the dividend, as in our fractional notation but without the bar. The operations of multiplication and evolution (the taking of roots), as well as unknown quantities, were represented by abbreviations of appropriate words." The extent of Greek influence on this syncopation, if any, is not known and it is possible that both Greek and Indian syncopation may be derived from a common Babylonian source.

Arithmetic The four fundamental operations (addition, subtraction, multiplication, and division) were known to many cultures before Brahmagupta. This current system is based on the Hindu–Arabic numeral system and first appeared in the Brāhmasphuṭasiddhānta. Brahmagupta describes multiplication in the following way:

The multiplicand is repeated like a string for cattle, as often as there are integrant portions in the multiplier and is repeatedly multiplied by them and the products are added together. It is multiplication. Or the multiplicand is repeated as many times as there are component parts in the multiplier.

Indian arithmetic was known in medieval Europe as modus Indorum meaning "method of the Indians". In the Brāhmasphuṭasiddhānta, four methods for multiplication were described, including gomūtrikā, which is said to be close to the present-day methods. In the beginning of chapter twelve of his Brāhmasphuṭasiddhānta, entitled "Calculation", he also details operations on fractions. The reader is expected to know the basic arithmetic operations as far as taking the square root, although he explains how to find the cube and cube-root of an integer and later gives rules facilitating the computation of squares and square roots. He then gives rules for dealing with five types of combinations of fractions: ; ; ; ; and . The reader is apparently expected to be familiar with basic arithmetic operations as far as the square-root; Brahmagupta merely notes some points about applying them to fractions. The procedures for finding the cube and cube-root of an integer, however, are described (compared the latter to Aryabhata's very similar formulation). They are followed by rules for five types of combinations: [...]

Squares and cubes Brahmagupta then goes on to give the sum of the squares and cubes of the first integers. 12.20. The sum of the squares is that [sum] multiplied by twice the [number of] step[s] increased by one [and] divided by three. The sum of the cubes is the square of that [sum] Piles of these with identical balls [can also be computed]. Here Brahmagupta found the result in terms of the sum of the first integers, rather than in terms of as is the modern practice. Here the sums of the squares and cubes of the first n integers are defined in terms of the sum of the n integers itself;

He gives the sum of the squares of the first natural numbers as and the sum of the cubes of the first n natural numbers as .

Zero Brahmagupta's Brahmasphuṭasiddhānta is the first book that provides rules for arithmetic manipulations that apply to zero and to negative numbers. The Brāhmasphuṭasiddhānta is the earliest known text to treat zero as a number in its own right, rather than as simply a placeholder digit in representing another number as was done by the Babylonians or as a symbol for lack of quantity as was done by Ptolemy and the Romans. In chapter eighteen of his Brāhmasphuṭasiddhānta, Brahmagupta describes operations on negative numbers. He first describes addition and subtraction, 18.30. [The sum] of two positives is positives, of two negatives negative; of a positive and a negative [the sum] is their difference; if they are equal it is zero. The sum of a negative and zero is negative, [that] of a positive and zero positives, [and that] of two zeros zero. [...]