International Conference on the History of Indian Mathematics 2026

The Patākā
in the Gaṇitakaumudī

Prasad Jawalgekar · Bhumika Mittal · K. Ramasubramanian · Aalok Thakkar

Nārāyaṇa Paṇḍita and the Gaṇitakaumudī
Aṅkapāśa
The Patākā antima m = 3, sthāna n = 3
1
2
4
10
3
5
7
11
13
19
6
8
12
14
16
20
22
9
15
17
21
23
25
18
24
26
27
The Nārācikā Sequence

अन्तिममितवैश्लेषस्थानाङ्कमिताश्च ताः पृथक् स्थाप्याः ।
तासां घातः सूचीपङ्क्तिर्नाराचिका वा स्यात् ॥

antimamitavaiśleṣasthānāṅkamitāśca tāḥ pṛthak sthāpyāḥ | tāsāṃ ghātaḥ sūcīpaṅktir nārācikā vā syāt |

Their product is the needle sequence, the nārācikā. For m and n equal to three it reads 1, 3, 6, 7, 6, 3, 1. Each term counts the sequences that share one digit sum.

Recitations courtesy of Vāgdhenu
Deriving the Nārācikā the door-junction method, kapāṭa-sandhi

Nārāyaṇa writes the vaiśleṣiṇī, a row of ones, once for every place, and multiplies the copies together. Each copy is laid one step across the last and the columns are added. For three places, two passes over 1 1 1 give first 1 2 3 2 1, then the nārācikā, 1 3 6 7 6 3 1.

nārācikā by repeated convolution, giving 1 3 6 7 6 3 1
Drawing the Grid column heights follow the nārācikā, 1, 3, 6, 7, 6, 3, 1
The Ābhyāsikī Sequence

स्थानाहतोऽन्तिमाङ्कः सैकः स्थानोनितश्च तच्छेषम् ।
आभ्यासिक्यां पङ्क्तौ प्रजायते स्थानमानमिह ॥

sthānāhato'ntimāṅkaḥ saikaḥ sthānonitaśca taccheṣam | ābhyāsikyāṃ paṅktau prajāyate sthānamānam iha |

Take the caya 1, 2, 3. Drop its first term, then multiply by three again and again.

1 2  3×3 6  9×3 18  27
Laying the First Row the ābhyāsikī, 1, 2, 3, 6, 9, 18, 27
1
2
3
6
9
18
27
The Guṇottara Sequence

आदौ रूपं विलिखेत् अन्तिमगुणितं पुरः पुनस्तद्वत् ।
स्थानाधिकं तु यावत् पङ्क्तिर्गुणकोत्तराख्येयम् ॥

ādau rūpaṃ vilikhet antimaguṇitaṃ puraḥ punastadvat | sthānādhikaṃ tu yāvat paṅktir guṇakottarākhyeyam |

The powers of three, 1, 3, 9, 27, mark where each stage closes.

1
2
3
6
9
18
27
The Patākā Verses

नाराचपङ्क्त्यङ्कमिताः कोष्ठानामूर्ध्वपङ्क्तयः । तिर्यग्गामी च सर्वासां स्वस्वखण्डावसानमा ॥
पङ्क्तिस्तदाद्यकोष्ठो यः पल्लवोऽथाङ्कयोजनाः । तिर्यक्स्थितायामाद्यायां पङ्क्तिमाभ्यासिकीं लिखेत् ॥

तदन्तिमाङ्कः क्षेपाख्यः पुरःस्थः साध्यनामकः । क्षेपं पुरातनैरङ्कैः क्रमात् संयोजयेत् पृथक् ॥
तानधस्तिर्यग्गायां च कोष्ठपङ्क्त्यां विनिक्षिपेत् । साध्याङ्कस्य पताका स्यात् साध्यं क्षेपं प्रकल्पयेत् ॥

साध्यं पुरःस्थितं कृत्वा क्षेपं प्राग्वत् पुरातनैः । अङ्कैराद्यद्वितीयादिकोष्ठपङ्क्तिगतैर्युतम् ॥
तिर्यङ्निरङ्ककोष्ठेषु साङ्काधःस्थेषु विन्यसेत् । येनाङ्केन युतः क्षेपः साध्याङ्कादधिको यदा ॥
तदा मुक्त्वा तमङ्कं तु योजयेदितरांस्ततः ॥

The Patākā Algorithm

One term of the first row is the kṣepa, an increment; the next is the sādhya, a bound. Add the kṣepa to the earlier numbers and set each sum in the next diagonal cell.

Each keypress advances a stage, as the sādhya rises to 6, 9, 18, 27. A guṇottara term turns golden as its stage closes.

1
2
4
10
3
5
7
11
13
19
6
8
12
14
16
20
22
9
15
17
21
23
25
18
24
26
27
QR code to the interactive patākā on this site
the interactive patākā, on this site
What It Represents the questions this arrangement answers
Complexity of the Algorithm
Our Contributions

धन्यवादः

open for questions