India has been a cradle not only to refined civilizational best-practices but also to multitudinous scientific developments. Evidence and knowledge of voluminous literature produced in Indian scientific pursuits has been well established by serious researchers. In contrast, there is prevalent ignorance about facts and feats that we have inherited.

Through a series of short articles, we have set forth to cover a few highlights in the development of Jyotiṣa (Astronomy) and Gaṇitā (Mathematics). The development of both these fields can broadly be put in three eras:

Vedic or Pre-Siddhantic Era,

Siddhantic or Classical Era and

Post-Siddhantic or Medieval Era.

Having delved into the Vedic period, we have moved ahead in the timeline and presented an introductory glimpse into the phenomenal breakthroughs in Chandas-śāstra was composed by Piṅgala-nāga around 3rd century BCE. In his chapter eight of Chandas-śāstra, Piṅgala introduces some combinatorial tools called pratyayas which can be employed to study the various possible metres in Sanskrit prosody. The algorithms presented by him form the earliest examples of use of recursion in Indian mathematics. In the previous editions of Parnika, we looked at the algorithm given for Prastāra, Saṅkhyā and Naṣṭa. In the current article we shall delve more into further interesting algorithms or pratyayas enunciated by Piṅgalācārya.

Algorithm#4 ~ Uddiṣṭa

Piṅgalācārya presents the the fourth of the six pratyayas — Uddiṣṭa for finding the row number of a given metrical pattern in the sequence of the n‑syllabled prastāra (ordered sequence of all combinations, as explained in algorithm 1 in previous articles) .

The following sūtras correspond to the procedure of deducing the Uddiṣṭa.प्रतिलोमगणं द्विर्लायम्। ततोग्येकं जह्यात्।

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

This algorithm is essentially a reverse engineering of the previous algorithm Naṣṭa, which was enunciated to find the pattern given a row number. Now in Uddiṣṭa, the steps are concisely expressed to reverse the previous process. The steps presented here in these two sūtras imply essentially the following:

Start with number 1

Scan the pattern from the right beginning with the first L from the right

Double it when an L is encountered

Double and reduce by 1 when a G is encountered

This also is one among the most elegant representations of the algorithm. To illustrate we shall consider the following example: May we employ the Uddiṣṭa algorithm to find the row number of the metrical form “GLLG” in the prastāra (ordered sequence of all combinations) of a 4‑syllabled meter.

We start with 1, and scan from right.

The right-most pattern is a G and hence we skip all Gs, as per the algorithm, until we encounter L

The next syllable, scanning from right, is L; So we get 1 x 2 = 2

Then we find L. So we get 2 x 2 = 4

Finally we have G. We get (4 x 2) − 1 = 7

Hence the combination “GLLG” in the ordered list of a 4‑syllabled meter would be the 7th metrical form in the prastāra. We have already seen that there will be 2 4 total combinations in the ordered list of prastāra and the given combination is the seventh among sixteen possible combinations. You are welcome to try out patterns such as “GLLGGLLG” , “GLGLLGLGGG”, and more such patterns you would like to play with and write to us ( mail at anaadi .org ) your answers.

It is indeed enthralling to know in depth about the rich scientific heritage of the Indian civilization. We shall continue to see other ingenious achievements in Indian mathematics in the following editions of Parnika.

Aum Tat Sat!

## Comments