Rules written as short poems so they could be learned by heart, from Pingala to Bhaskara.
Sutra (prose rule)Piṅgala's shortcut for powers of two
द्विरर्धे । रूपे शून्यम् । द्विः शून्ये । तावदर्धे तद्गुणितम् ॥
dvir ardhe | rūpe śūnyam | dviḥ śūnye | tāvad ardhe tadguṇitam ||
Say it: DVIR AR-dhay ROO-pay SHOON-yam DVIH SHOON-yay TAA-vad AR-dhay tad-GU-ni-tam
Meaning. (If the number can be halved, halve it and write) two. (If not,) take away one and write a zero. (Then, working back from the end, starting from one:) at a zero, double; at a halving mark, multiply the amount by itself.
The math. To count all the long and short beat patterns in a 6-syllable line, Piṅgala halves and subtracts down to nothing, then doubles and squares back up: 1, 2, 4, 8, 64, so there are 64 patterns. 2^n by repeated halving and squaring (the "square and multiply" method); e.g. 2^6 = 64
Word by word, source and notes
- dviḥ
- two (write the mark "2")
- ardhe
- when (the number) is halved
- rūpe
- when one is taken away
- śūnyam
- an empty mark, a zero
- dviḥ
- twice, double
- śūnye
- at the empty mark
- tāvat
- that much
- ardhe
- at the halving mark
- tadguṇitam
- multiplied by itself
Source. Piṅgala, Chandaḥśāstra (Chandaḥsūtra) 8.28 to 8.31 in the numbering used by A. Kulkarni. Commonly dated to the last centuries BCE, uncertain. Explained by the commentator Halāyudha (Mṛtasañjīvanī, usually dated to the 10th century CE).
Good to know. These are terse prosody rules for counting Sanskrit meters, and they only make sense with a commentary. Sūtra numbering and readings vary between editions. Whether śūnya here is already the numeral zero or just a written marker is debated. Popular claims that Piṅgala "invented binary numbers" overstate it: his listing of long and short syllable patterns is analogous to binary counting. The number triangle (meru-prastāra, now called Pascal's triangle) is described in Halāyudha's later commentary, not in these sūtras.
Checked against:
- A. Kulkarni, Recursion and Combinatorial Mathematics in Chandaśāstra (arXiv math/0703658)
- INDOLOGY list, July 2022: Sunya (Piṅgala 8.28 to 8.31 as transcribed by A. Kulkarni)
Verse (śloka) · āryāEach place is ten times the last
एकं च दश च शतं च सहस्रं त्वयुतनियुते तथा प्रयुतम् ।
कोट्यर्बुदं च वृन्दं स्थानात्स्थानं दशगुणं स्यात् ॥
ekaṃ ca daśa ca śataṃ ca sahasraṃ tv ayutaniyute tathā prayutam |
koṭyarbudaṃ ca vṛndaṃ sthānāt sthānaṃ daśaguṇaṃ syāt ||
Say it: AY-kam cha DA-sha cha SHA-tam cha sa-HA-sram tva-yu-ta-NI-yu-tay TA-thaa PRA-yu-tam | ko-TYAR-bu-dam cha VRIN-dam STHAA-naat STHAA-nam da-SHA-gu-nam SYAAT
Meaning. One, ten, a hundred, a thousand, ten thousand, a hundred thousand, a million, ten million, a hundred million and a billion: from place to place, each is ten times (the previous).
The math. Āryabhaṭa names the places in a number, ones, tens, hundreds and so on, and says each place is worth ten times the one to its right, which is exactly how we write numbers today. Decimal place value: each place is worth 10 times the place before (1 to 10^9)
Word by word, source and notes
- ekaṃ
- one
- daśa
- ten
- śataṃ
- a hundred
- sahasraṃ
- a thousand
- ayutaniyute
- ten thousand and a hundred thousand
- tathā
- likewise
- prayutam
- a million
- koṭyarbudaṃ
- ten million and a hundred million
- vṛndaṃ
- a billion (10^9)
- sthānāt sthānaṃ
- from place to place
- daśaguṇaṃ
- ten times
- syāt
- is
Source. Āryabhaṭa, Āryabhaṭīya, Gaṇitapāda 2; composed 499 CE (Kusumapura).
Good to know. The GRETIL e-text (from Shukla's edition, entered without sandhi) omits "ca" after ekaṃ and "tu" before ayuta; the fuller reading here is the one usually printed and is needed for the āryā meter. The verse names the places; it does not itself describe the written zero.
Checked against:
- GRETIL: Āryabhaṭīya (K. S. Shukla ed., INSA 1976)
- Some Sanskrit Verses in Ancient Math (BPRIM, 2026)
Verse (śloka) · āryāĀryabhaṭa's value of π
चतुरधिकं शतमष्टगुणं द्वाषष्टिस्तथा सहस्राणाम् ।
अयुतद्वयविष्कम्भस्यासन्नो वृत्तपरिणाहः ॥
caturadhikaṃ śatam aṣṭaguṇaṃ dvāṣaṣṭis tathā sahasrāṇām |
ayutadvayaviṣkambhasyāsanno vṛttapariṇāhaḥ ||
Say it: cha-tu-RA-dhi-kam SHA-tam ash-TA-gu-nam dvaa-SHASH-tis TA-thaa sa-ha-SRAA-naam | a-yu-ta-dva-ya-vish-kam-bhas-yaa-SAN-no vrit-ta-pa-ri-NAA-hah
Meaning. One hundred plus four, multiplied by eight, and sixty-two thousand added: this is the approximate circumference of a circle whose diameter is twenty thousand.
The math. (100 + 4) × 8 + 62,000 = 62,832, and a circle 20,000 units across goes about 62,832 units around, so π is about 3.1416. π ≈ 62832 / 20000 = 3.1416
Word by word, source and notes
- caturadhikaṃ
- increased by four
- śatam
- a hundred
- aṣṭaguṇaṃ
- multiplied by eight
- dvāṣaṣṭiḥ
- sixty-two
- tathā
- and also
- sahasrāṇām
- thousands
- ayutadvaya
- two ayutas, 20,000
- viṣkambhasya
- of a diameter
- āsannaḥ
- approximate, near
- vṛttapariṇāhaḥ
- circumference of the circle
Source. Āryabhaṭa, Āryabhaṭīya, Gaṇitapāda 10; 499 CE. Quoted in the Kriyākramakarī on Līlāvatī 199.
Good to know. The word āsanna ("near") shows Āryabhaṭa knew this was an approximation. Some modern writers suggest it hints that π is irrational; that is a modern interpretation, not something the text proves. The Kriyākramakarī commentary explains āsanna in a similar way.
Checked against:
- GRETIL: Āryabhaṭīya (K. S. Shukla ed., INSA 1976)
- Wikipedia: Aryabhata (Gaṇitapāda 10 text and translation)
- Līlāvatī with Kriyākramakarī, ed. K. V. Sarma, VVRI 1975 (archive.org scan)
Verse (śloka) · āryāAdding with fortunes, debts and zero
धनयोर्धनमृणमृणयोर्धनर्णयोरन्तरं समैक्यं खम् ।
ऋणमैक्यं च धनमृणधनशून्ययोः शून्ययोः शून्यम् ॥
dhanayor dhanam ṛṇam ṛṇayor dhanarṇayor antaraṃ samaikyaṃ kham |
ṛṇam aikyaṃ ca dhanam ṛṇadhanaśūnyayoḥ śūnyayoḥ śūnyam ||
Say it: DHA-na-yor DHA-nam RI-nam RI-na-yor dha-NAR-na-yor AN-ta-ram sa-MAI-kyam KHAM | RI-nam AI-kyam cha DHA-nam ri-na-dha-na-SHOON-ya-yoh SHOON-ya-yoh SHOON-yam
Meaning. (The sum) of two positives is positive, of two negatives is negative; of a positive and a negative it is their difference, and if they are equal, zero. The sum of a negative and zero is negative, of a positive and zero positive, and of two zeros zero.
The math. Think of money: two gifts make a bigger gift, two debts make a bigger debt, a gift and a debt cancel down to the difference, and adding nothing changes nothing. Rules for adding positive and negative numbers and zero: (+)+(+)=+, (-)+(-)=-, a+(-a)=0, a+0=a, 0+0=0
Word by word, source and notes
- dhanayoḥ
- of two fortunes (positives)
- dhanam
- a fortune
- ṛṇam
- a debt (negative)
- ṛṇayoḥ
- of two debts
- dhanarṇayoḥ
- of a fortune and a debt
- antaraṃ
- the difference
- samaikyaṃ
- the sum of equal (fortune and debt)
- kham
- zero (literally: empty space)
- ṛṇam aikyaṃ ca dhanam
- the sum is a debt, and a fortune (respectively)
- ṛṇadhanaśūnyayoḥ
- of a debt and zero, of a fortune and zero
- śūnyayoḥ
- of two zeros
- śūnyam
- zero
Source. Brahmagupta, Brāhmasphuṭasiddhānta 18.30 (chapter on algebra, kuṭṭaka); 628 CE.
Good to know. One of the earliest known statements treating zero as a number with its own arithmetic rules. Brahmagupta's words for positive and negative are dhana (wealth) and ṛṇa (debt). In 18.34 to 18.35 he also says zero divided by zero is zero, which modern mathematics does not accept. Text checked in the Dvivedin (GRETIL) and R. S. Sharma editions.
Checked against:
- GRETIL: Brāhmasphuṭasiddhānta (S. Dvivedin ed., 1902)
- Brāhmasphuṭasiddhānta, ed. R. S. Sharma, 1966, vol. 4 (archive.org scan)
- Wikipedia: Brāhmasphuṭasiddhānta (rules for zero and negatives)
Verse (śloka) · āryāA debt times a debt is a fortune
ऋणमृणधनयोर्घातो धनमृणयोर्धनवधो धनं भवति ।
शून्यर्णयोः खधनयोः खशून्ययोर्वा वधः शून्यम् ॥
ṛṇam ṛṇadhanayor ghāto dhanam ṛṇayor dhanavadho dhanaṃ bhavati |
śūnyarṇayoḥ khadhanayoḥ khaśūnyayor vā vadhaḥ śūnyam ||
Say it: RI-nam ri-na-DHA-na-yor GHAA-to DHA-nam RI-na-yor dha-NA-va-dho DHA-nam BHA-va-ti | shoon-YAR-na-yoh kha-DHA-na-yoh kha-SHOON-ya-yor VAA VA-dhah SHOON-yam
Meaning. The product of a negative and a positive is negative; of two negatives, positive; the product of positives is positive. The product of zero and a negative, of zero and a positive, or of two zeros, is zero.
The math. Multiplying a positive by a negative gives a negative, two negatives make a positive, and anything times zero is zero, written down about 1,400 years ago. (-)×(+) = -, (-)×(-) = +, (+)×(+) = +, a×0 = 0
Word by word, source and notes
- ṛṇam
- a debt (negative)
- ṛṇadhanayoḥ
- of a debt and a fortune
- ghātaḥ
- the product
- dhanam
- a fortune (positive)
- ṛṇayoḥ
- of two debts
- dhanavadhaḥ
- the product of fortunes
- bhavati
- is
- śūnyarṇayoḥ
- of zero and a debt
- khadhanayoḥ
- of zero and a fortune
- khaśūnyayoḥ
- of zero and zero
- vā
- or
- vadhaḥ
- the product
- śūnyam
- zero
Source. Brahmagupta, Brāhmasphuṭasiddhānta 18.33; 628 CE.
Good to know. Stated as rules without proof. Text checked in the Dvivedin (GRETIL) and R. S. Sharma editions, which agree.
Checked against:
- GRETIL: Brāhmasphuṭasiddhānta (S. Dvivedin ed., 1902)
- Brāhmasphuṭasiddhānta, ed. R. S. Sharma, 1966, vol. 4 (archive.org scan)
- Wikipedia: Brāhmasphuṭasiddhānta (rules for zero and negatives)
Verse (śloka) · āryāNumbers written as words: Śaka 427
सप्ताश्विवेदसंख्यं शककालमपास्य चैत्रशुक्लादौ ।
saptāśvivedasaṃkhyaṃ śakakālam apāsya caitraśuklādau |
Say it: sap-taash-vi-vay-da-SAM-khyam sha-ka-KAA-lam a-PAAS-ya chai-tra-shuk-LAA-dau
Meaning. Subtract (from the given year) the Śaka year numbered seven, twins (Aśvins), Vedas, that is 427, at the beginning of the bright fortnight of Caitra.
The math. Instead of digits, the poet used words: "seven", "the twins" (2) and "the Vedas" (4); reading them right to left gives 427, a year that is 505 CE. Bhūta-saṃkhyā (object-number words) read right to left: 7, 2, 4 → 427
Word by word, source and notes
- sapta
- seven: 7
- aśvi
- the Aśvin twins: 2
- veda
- the Vedas: 4
- saṃkhyaṃ
- numbering
- śakakālam
- the Śaka era (years)
- apāsya
- having subtracted
- caitraśuklādau
- at the beginning of the bright half of the month Caitra
Source. Varāhamihira, Pañcasiddhāntikā 1.8, first half (Romaka method); epoch Śaka 427 = 505 CE; work of the 6th century CE.
Good to know. Only the first half of the verse is given. The second half names the weekday of the epoch, and the editions disagree on that word (Fleet and Neugebauer and Pingree favour Tuesday; other manuscripts read Wednesday or Monday). The right-to-left order ("aṅkānāṃ vāmato gatiḥ") is the standard rule for word numerals.
Checked against:
- Pañcasiddhāntikā, ed. T. S. Kuppanna Sastry and K. V. Sarma (archive.org scan)
- Neugebauer and Pingree, The Pañcasiddhāntikā of Varāhamihira, vol. 1, 1970 (archive.org scan)
- Indian Antiquary vol. 19 (1890), p. 54: Fleet on the epoch verse and its variant readings
- Wikipedia: Pancha-siddhantika (Śaka 427 = 505 CE)
Verse (śloka) · anuṣṭubhNothing exists without mathematics
बहुभिर्विप्रलापैः किं त्रैलोक्ये सचराचरे ।
यत्किंचिद्वस्तु तत्सर्वं गणितेन विना न हि ॥
bahubhir vipralāpaiḥ kiṃ trailokye sacarācare |
yat kiṃcid vastu tat sarvaṃ gaṇitena vinā na hi ||
Say it: BA-hu-bhir vi-pra-LAA-paih KIM trai-LO-kyay sa-cha-RAA-cha-ray | YAT KIM-chid VAS-tu TAT SAR-vam ga-ni-TAY-na VI-naa na hi
Meaning. What is the use of saying much? Whatever there is in the three worlds, with all their moving and unmoving beings, none of it exists apart from mathematics.
The math. A Jain teacher said: why argue? Everything in the whole world, moving or still, needs numbers and measuring to be understood. Praise of gaṇita (mathematics) as present in everything
Word by word, source and notes
- bahubhiḥ
- with many
- vipralāpaiḥ
- idle words
- kiṃ
- what is the use
- trailokye
- in the three worlds
- sacarācare
- with all moving and unmoving things
- yat kiṃcit
- whatever
- vastu
- thing
- tat sarvaṃ
- all of that
- gaṇitena
- mathematics, calculation
- vinā
- without
- na hi
- surely is not
Source. Mahāvīra (Mahāvīrācārya), Gaṇitasārasaṃgraha 1.16 (Saṃjñādhikāra); c. 850 CE, at the court of the Rāṣṭrakūṭa king Amoghavarṣa.
Good to know. A Jain mathematical textbook, not a Vedic one. Rangacharya's 1912 translation renders gaṇita here as "measurement". The online text is unproofread OCR (it prints "trailokaye"); the reading trailokye is standard.
Checked against:
- Wisdom Library: Gaṇitasārasaṃgraha, ch. 1 Sanskrit (Rangacharya ed., 1912)
- Wisdom Library: Gaṇitasārasaṃgraha, ch. 1 English (Rangacharya tr., 1912)
Verse (śloka) · upajāti (indravajrā family)Bhāskara's squaring shortcuts
खण्डद्वयस्याभिहतिर्द्विनिघ्नी तत्खण्डवर्गैक्ययुता कृतिर्वा ।
इष्टोनयुग्राशिवधः कृतिः स्यादिष्टस्य वर्गेण समन्वितो वा ॥
khaṇḍadvayasyābhihatir dvinighnī tatkhaṇḍavargaikyayutā kṛtir vā |
iṣṭonayugrāśivadhaḥ kṛtiḥ syād iṣṭasya vargeṇa samanvito vā ||
Say it: khan-da-dva-yas-yaa-BHI-ha-tir dvi-NIGH-nee tat-khan-da-var-gai-KYA-yu-taa KRI-tir VAA | ish-to-na-yu-graa-SHI-va-dhah KRI-tih SYAAD ish-TAS-ya var-GAY-na sa-MAN-vi-to VAA
Meaning. Or: the product of two parts (of a number), doubled and added to the sum of the squares of the parts, is the square. Or: the product of the number decreased and increased by any chosen amount, plus the square of that chosen amount, is the square.
The math. To square 297, Bhāskara picks 3: 294 × 300 = 88,200, then add 3 × 3 = 9 to get 88,209, which is much easier than multiplying 297 by 297. (a + b)² = 2ab + a² + b²; n² = (n - d)(n + d) + d², e.g. 297² = 294 × 300 + 9 = 88209
Word by word, source and notes
- khaṇḍadvayasya
- of two parts (of the number)
- abhihatiḥ
- the product
- dvinighnī
- multiplied by two
- tatkhaṇḍavargaikyayutā
- added to the sum of the squares of those parts
- kṛtiḥ
- the square
- vā
- or
- iṣṭa
- a chosen amount
- ūnayugrāśivadhaḥ
- the product of the number decreased and increased (by it)
- syāt
- is
- iṣṭasya vargeṇa
- by the square of the chosen amount
- samanvitaḥ
- increased
Source. Bhāskara II, Līlāvatī 20 (squaring, vargaparikarma); c. 1150 CE. The 297 example is in Bhāskara's own prose comment.
Good to know. The second rule is the same algebraic identity that makes Tirtha's Yāvadūnam squaring work (97² = 94 × 100 + 9 = 9409), so the connection is mathematical, not a source for the 1965 sūtra. K. V. Sarma's edition inserts an extra half-verse (khaṇḍadvayasyābhihatiś caturghnī ...) that other editions lack. The previous verse, Līlāvatī 19, defines the square: samadvighātaḥ kṛtiḥ, "the product of two equal numbers is the square".
Checked against:
- GRETIL: Bhāskara, Līlāvatī (Āpaṭe 1937 and K. V. Sarma 1975 eds.)
- Līlāvatī with Kriyākramakarī, ed. K. V. Sarma, VVRI 1975 (archive.org scan)
- Līlāvatī with Tattvaprakāśikā, ed. L. Jha (Chowkhamba) (archive.org scan)
Verse (śloka) · śārdūlavikrīḍitaThe bee puzzle
पञ्चांशोऽलिकुलात्कदम्बमगमत्त्र्यंशः शिलीन्ध्रं तयो-
र्विश्लेषस्त्रिगुणो मृगाक्षि कुटजं दोलायमानोऽपरः ।
कान्ते केतकमालतीपरिमलप्राप्तैककालप्रिया-
दूताहूत इतस्ततो भ्रमति खे भृङ्गोऽलिसंख्यां वद ॥
pañcāṃśo 'likulāt kadambam agamat tryaṃśaḥ śilīndhraṃ tayor
viśleṣas triguṇo mṛgākṣi kuṭajaṃ dolāyamāno 'paraḥ |
kānte ketakamālatīparimalaprāptaikakālapriyā-
dūtāhūta itas tato bhramati khe bhṛṅgo 'lisaṃkhyāṃ vada ||
Say it: pan-CHAAM-sho LI-ku-laat ka-DAM-bam A-ga-mat TRYAM-shah shi-LEEN-dhram TA-yor | vish-LAY-shas TRI-gu-no mri-GAAK-shi KU-ta-jam do-laa-ya-MAA-no PA-rah | KAAN-tay kay-ta-ka-maa-la-tee-pa-ri-ma-la-praap-tai-ka-kaa-LA-pri-yaa | doo-taa-HOO-ta I-tas TA-to BHRA-ma-ti KHAY BHRING-go li-SAM-khyaam VA-da
Meaning. A fifth of a swarm of bees went to a kadamba flower, a third to a śilīndhra flower, and three times their difference, O fawn-eyed girl, to a kuṭaja flower. One more bee, called at the same moment by the fragrance of the ketaka and the mālatī, wanders here and there in the air. Tell me, lovely one, how many bees there are.
The math. 1/5 + 1/3 + 3 × (1/3 - 1/5) of the bees fly off and 1 bee is left over: that makes 3 + 5 + 6 + 1 = 15 bees. x/5 + x/3 + 3(x/3 - x/5) + 1 = x, so x = 15
Word by word, source and notes
- pañcāṃśaḥ
- a fifth
- alikulāt
- of a swarm of bees
- kadambam agamat
- went to a kadamba flower
- tryaṃśaḥ
- a third
- śilīndhraṃ
- (went) to a śilīndhra flower
- tayoḥ viśleṣaḥ
- the difference of these two
- triguṇaḥ
- three times (that)
- mṛgākṣi
- O fawn-eyed girl
- kuṭajaṃ
- (went) to a kuṭaja flower
- dolāyamānaḥ
- swinging to and fro
- aparaḥ
- one other (bee)
- kānte
- O lovely one
- ketakamālatīparimala...dūtāhūtaḥ
- called at once by the scents of the ketaka and mālatī flowers, like messengers from two sweethearts
- itas tataḥ
- here and there
- bhramati khe
- wanders in the air
- bhṛṅgaḥ
- a bee
- alisaṃkhyāṃ
- the number of bees
- vada
- tell
Source. Bhāskara II, Līlāvatī 55 (example for iṣṭakarma, the rule of false position) in the Āpaṭe numbering used by GRETIL; c. 1150 CE.
Good to know. Verse numbering differs between editions. Bhāskara's method is to assume any number, see what it gives, and scale (false position), not to solve an equation the modern way. The other famous bee problem (Līlāvatī 71, answer 72) involves a square root.
Checked against:
- GRETIL: Bhāskara, Līlāvatī (Āpaṭe 1937 and K. V. Sarma 1975 eds.)
- Līlāvatī, tr. Patwardhan, Naimpally and Singh (MLBD) (archive.org scan)