top of page

Combinatorics and Chandas-śāstra‑3

India has been a cra­dle not only to refined civ­i­liza­tion­al best-prac­tices but also to mul­ti­tudi­nous sci­en­tif­ic devel­op­ments. Evi­dence and knowl­edge of volu­mi­nous lit­er­a­ture pro­duced in Indi­an sci­en­tif­ic pur­suits has been well estab­lished by seri­ous researchers. In con­trast, there is preva­lent igno­rance about facts and feats that we have inher­it­ed.

Awak­en­ing Indi­ans to Indi­an Sci­ences is impor­tant to build a bet­ter per­spec­tive about this land and its peo­ple, to own up to what is tru­ly ours and align our actions in coher­ence with the vision and momen­tum set forth by the great Jna­nis of our civ­i­liza­tion. As we pro­tect, pre­serve and cel­e­brate var­i­ous tem­ples, mon­u­ments, arte­facts and places of his­toric emi­nence, so too, we must pre­serve and pro­tect intel­lec­tu­al break­throughs in our Indi­an tra­di­tions through aware­ness, assim­i­la­tion and dis­sem­i­na­tion.

Through a series of short arti­cles, may we enlight­en our­selves in a few “must-know” aspects about our rich sci­en­tif­ic her­itage. We set forth to cov­er a few high­lights in the devel­op­ment of Jyotiṣa (Astron­o­my) and Gaṇitā (Math­e­mat­ics). The devel­op­ment of both these fields can broad­ly be put in three eras:

  1. Vedic or Pre-Sid­dhan­tic Era,

  2. Sid­dhan­tic or Clas­si­cal Era and

  3. Post-Sid­dhan­tic or Medieval Era.

Thus far we have looked at high­lights of Jyotiṣa in the Vedic Era and the devel­op­ment of Gaṇi­ta in the Vedic Era cov­er­ing ear­li­est evi­dence of num­bers, devel­op­ment of Geom­e­try, a broad intro­duc­tion to Śul­ba-sūtras, their con­tents and appli­ca­tions. Very impor­tant­ly, we have also looked at the less­er known fact that a clear enun­ci­a­tion of the so-called ‘Pythagore­an’ the­o­rem, which must right­ly be named the Śul­ba The­o­rem (called bhu­jā-koṭi-karṇa-nyāya in the lat­er lit­er­a­ture) has been described in Baud­hāyana-śul­basū­tra and a vari­ant in Māna­va-śul­basū­tra. We have also sum­marised the over­all math­e­mat­i­cal con­tents of the Śul­ba-sūtras. Hav­ing delved into the Vedic peri­od, we have moved ahead in the time­line and pre­sent­ed an intro­duc­to­ry glimpse into the phe­nom­e­nal break­throughs of Piṅ­galācārya (3rd cen­tu­ry BCE).

Ori­gins of Com­bi­na­torics in Chan­das-śās­tra

The Chan­das-śās­tra has some very inter­est­ing and intri­cate con­nec­tion with math­e­mat­ics. The word chan­das means of prosody, the sci­ence of metres. It has been esti­mat­ed by schol­ars that this Chan­das-śās­tra was com­posed by Piṅ­gala-nāga around 3rd cen­tu­ry BCE, though there could be some uncer­tain­ty in his peri­od. In his Chan­das-śās­tra, Piṅ­gala intro­duces some com­bi­na­to­r­i­al tools called pratyayas which can be employed to study the var­i­ous pos­si­ble metres in San­skrit prosody. The algo­rithms pre­sent­ed by him form the ear­li­est exam­ples of use of recur­sion in Indi­an math­e­mat­ics. In the pre­vi­ous edi­tion of Parni­ka, we looked at the algo­rithm giv­en for Prastāra. In the cur­rent arti­cle we shall delve more into greater under­stand­ing of the oth­er algo­rithms or pratyayas enun­ci­at­ed by Piṅ­galācārya.

Pratyayas in Piṅgala’s Chan­das-śās­tra

In chap­ter eight of Chan­das-śās­tra, Piṅ­gala intro­duces the fol­low­ing six pratyayas:Prastāra: A pro­ce­dure by which all the pos­si­ble met­ri­cal pat­terns with a giv­en num­ber of syl­la­bles are laid out sequen­tial­ly as an array.

Saṅkhyā: The process of find­ing total num­ber of met­ri­cal pat­terns (or rows) in the prastāra.

Naṣṭa: The process of find­ing for any row, with a giv­en num­ber, the cor­re­spond­ing met­ri­cal pat­tern in the prastāra.

Uddiṣṭa: The process for find­ing, for any giv­en met­ri­cal pat­tern, the cor­re­spond­ing row num­ber in the prastāra.

Lagakriyā: The process of find­ing the num­ber of met­ri­cal forms with a giv­en num­ber of laghus (or gurus).

Adhvayo­ga: The process of find­ing the space occu­pied by the prastāra.

Algorithm#2 ~ Saṅkhyā

Piṅ­galācārya presents the the first of the six pratyayas — Saṅkhyā involv­ing the steps for find­ing the total num­ber of pos­si­ble met­ri­cal pat­terns in four terse sūtras. In our schools that teach us mod­ern math­e­mat­ics and com­put­ing, we have learnt that in bina­ry num­ber sys­tem, the total num­ber of pos­si­ble com­bi­na­tions for a n-length bina­ry num­ber is 2n. Sim­i­lar­ly, here we have the bina­ry states of guru and laghu, hence the total num­ber of pat­terns pos­si­ble for a n-syl­la­bled met­ri­cal pat­tern is 2n. The pro­ce­dure out­lined in these sutras is a unique approach to com­pu­ta­tion of 2n.

The fol­low­ing sūtras cor­re­spond to the pro­ce­dure of cal­cu­lat­ing Saṅkhyā.

द्विरर्धे। रूपे शून्यम्। द्विःशून्ये। तावदर्धे तद्गुणितम्।

(छन्दःशास्त्रम् ८.२८-३१)

Piṅ­galācārya gives an opti­mal algo­rithm for find­ing 2n by means of mul­ti­pli­ca­tion and squar­ing oper­a­tions that are much less than n in num­ber. The steps pre­sent­ed here are essen­tial­ly the fol­low­ing:

  1. Halve the num­ber and mark “2”.

  2. If the num­ber can­not be halved per­fect­ly deduct one and mark “0”

[Pro­ceed till you reach zero. Now we have a string of mark­ers in 0s and 2s.

Start with 1 and scan the sequence of marks from the last to first.]

  1. If “0” is the mark­er, mul­ti­ply the cur­rent val­ue by 2

  2. If “2” is the mark­er, square the cur­rent val­ue

To illus­trate we shall con­sid­er the fol­low­ing exam­ple:

May we employ the Saṅkhyā algo­rithm to find the total num­ber of com­bi­na­tions in a 6‑syllabled meter.

  1. 6 ÷ 2 = 3 and mark “2”

  2. Here, 3 can­not be per­fect­ly halved. So,

3 – 1 = 2 and mark “0”

  1. 2 ÷ 2 = 1 and mark “2”

  2. 1 – 1 = 0 and mark “0”

Now we have the mark­er-string “2 0 2 0”. Then we do the fol­low­ing steps to arrive at the total val­ue, by scan­ning the mark­er-string from last to first.StepCur­rent Val­ueMark­erOper­a­tiona.10Mul­ti­ply by 2; so 1 x 2b.22Square cur­rent val­ue; so 2 x 2c. 40Mul­ti­ply by 2; so 4 x 2d.82Square cur­rent val­ue; so 8 x 8 Hence final val­ue is 64

High­light of the algo­rithm:

When­ev­er we find the n‑th pow­er of a num­ber, it typ­i­cal­ly involves n mul­ti­pli­ca­tion oper­a­tions. Where­as this method involves much less than n mul­ti­pli­ca­tions. Hence Piṅ­galācārya gives an opti­mal algo­rithm for find­ing 2n by means of mul­ti­pli­ca­tion and squar­ing oper­a­tions that are much less than n in num­ber.

Sum of Saṅkhyās:

Fol­low­ing the above algo­rithm, Piṅ­gala gives two inter­est­ing math­e­mat­i­cal results. In the very next sūtra he gives the sum of all the saṅkhyās Sr for r = 1, 2, … n.द्विर्द्यूनं तदन्तानाम्। (छन्दःशास्त्रम् ८.३२)

S 1 + S 2 + S 3 + … + S n = 2S n − 2

Then comes the fol­low­ing sūtra with one more math­e­mat­i­cal rela­tion­ship.परे पूर्णम्। (छन्दःशास्त्रम् ८.३३)

S 1 + S 2 + S 3 + … + S n = 2S n − 1

Togeth­er, the two sūtras imply S n = 2 n and 1 + 2 + 2 2 + … + 2 n = 2 n+1 − 1. This clear­ly is the for­mu­la for the sum of a geo­met­ric series.

Saṅkhyās in the case of asym­met­ric met­ri­cal usage in prosody:

Math­e­mat­i­cal inquis­i­tive­ness of Piṅ­galācārya con­tin­ues to shine in fur­ther vers­es where he presents the math­e­mat­i­cal results in the case of asym­met­ric choice of meters employed in con­struc­tion of the vers­es. The saṅkhyā 2 n dis­cussed above is for the case of syl­lab­ic metres of n-syl­la­bles which are sama-vṛt­tas – metres which have the same pat­tern in all the four pādas or quar­ters. Ard­hasama-vṛt­tas are those metres which are not sama, but whose halves are the same. Viṣa­ma-vṛt­tas are those which are nei­ther sama nor ard­hasama.

In the fifth Chap­ter of Chan­daḥ-śās­tra, Piṅ­galācārya has dealt with the saṅkhyā of Ard­hasama-vṛt­tas and Viṣa­ma-vṛt­tas in the fol­low­ing sūtras:समं तावत्कृत्वः कृतमर्धसमम्। विषमं च। राश्यूनम्।

(छन्दःशास्त्रम् ५.३‑५)

The num­ber of Ard­hasama-vṛt­tas with n‑syllables in each pāda is

( 2 n ) 2 − 2 n

In the same way, the num­ber of Viṣa­ma-vṛt­tas with n‑syllables in each pāda is

( 2 2n ) 2 − [ ( ( 2 n ) 2 − 2 n ) + 2 n ] = ( 2 2n ) 2 − 2 2n

It is indeed enthralling to know in depth about the rich sci­en­tif­ic her­itage of the Indi­an civ­i­liza­tion. We shall con­tin­ue to learn about the oth­er algo­rithms or pratyayas enun­ci­at­ed by Piṅ­galācārya in the fol­low­ing edi­tions.

Aum Tat Sat!

2 views0 comments

Recent Posts

See All

Indi­a’s Inspir­ing Sci­en­tif­ic Her­itage A primer series into the devel­op­ment of Jyotiṣa & Gaṇitā in India Through a series of short arti­cles, we have set forth to cov­er a few high­lights in th

bottom of page