Abstract
The study of permutations and combinations was widespread in India, with applications in diverse areas such as medicine, prosody, music, etc. In the current paper, we present a study of three combinatorial techniques (pratyayas) known as prastāra, uddiṣṭa and naṣṭa—usually found in texts on prosody and music—as discussed in Munīśvara’s hitherto unpublished Nisṛṣṭārthadūtī commentary on Bhāskara’s celebrated mathematical text Līlāvatī. This paper brings to light Munīśvara’s lucid discussion on the application of these techniques in the context of numbers.
Similar content being viewed by others
Avoid common mistakes on your manuscript.
1 Introduction
Permutations and combinations have been studied in India from ancient times, with applications in areas as diverse as medicine, prosody, music, sculpture, architecture, perfumery, etc. A number of prior studies have detailed various aspects of the history and development of this discipline in India. For instance, Datta and Singh (1992) provide a general overview of the history and development of this topic in India by outlining the contributions of various scholars. Sridharan (2005, 2006) and Sridharan et al. (2010), among others, discuss the application of combinatorics in prosody and music in the form of combinatorial techniques known as pratyayas, particularly as found in the Chandas-śāstra of Piṅgala and the Saṅgīta-ratnākara of Śārṅgadeva. These papers also discuss the mathematical rationale of the combinatorial techniques employed.
In the current paper, we intend to bring to light relevant portions of the hitherto unpublished NisṛṣṭārthadūtīFootnote 1 commentary by Munīśvara on Bhāskara’s celebrated mathematical text Līlāvatī, which contributes to our understanding of three pratyayas—prastāra, uddiṣṭa and naṣṭa. In the relatively short Aṅkapāśa chapter of the Līlāvatī, consisting of only eleven verses,Footnote 2 Bhāskara discusses permutations involving a set of distinct digits, instead of musical notes employed in texts such as the Saṅgīta-ratnākara. He further discusses permutations involving a set of digits, all not necessarily distinct, and also presents a number of examples. His relatively brief treatment of the topic does not contain any discussion on pratyayas. However, in his commentary, Munīśvara includes a discussion on pratyayas, wherein he explains the construction of the prastāra and elaborates upon the naṣṭa and uddiṣṭa processes by compiling all the necessary rules from various sources and presenting them with his own modifications.Footnote 3 In this paper, we attempt to bring to light Munīśvara’s discussion of this topic which helps in developing a better understanding of the interplay between numbers, music and mathematics.
2 Bhāskara’s rule for permutations
In the Nisṛṣṭārthadūtī, Munīśvara embeds his discussion of the three pratyayas—prastāra, uddiṣṭa and naṣṭa—in his commentary on the first verse of the Aṅkapāśa chapter of the Līlāvatī. In this verse, Bhāskara gives the following prescription for determining the number of possible permutations of a set of distinct digits:
स्थानान्तमेकादिचयाङ्कघातः
सङ्ख्याविभेदा नियतैस्स्युरङ्कैः ।
भक्तोङ्कमित्याङ्कसमासनिघ्नः
स्थानेषु युक्तो मितिसंयुतिस्स्यात् ॥
sthānāntamekādicayāṅkaghātaḥ
saṅkhyāvibhedā niyataissyuraṅkaiḥ |
bhaktoṅkamityāṅkasamāsanighnaḥ
sthāneṣu yukto mitisaṃyutissyāt ∥
The product of the numbers starting with and increasing by one, unto the end of the positions, would be the possible variations of numbers (saṅkhyāvibheda) [that can be formed] with [all of] the given digits. That [saṅkhyāvibheda] divided by the number of digits, multiplied by the sum of the digits, and [the result] added in place [according to place value], would be the sum of the [various] numbers formed.
The above verse, composed in the indravajrā metre, is packed with mathematical content. It furnishes two basic rules pertaining to permutation. First, given n distinct digits, the verse describes how to determine the count of numbers which can be formed using all of the digits. Secondly, it describes how to determine the sum of all the numbers so formed. Only the first rule is relevant to this paper, and we briefly explain it below.
In Indian mathematical texts, the term sthāna generally refers to the place value position of any digit in a given number. However, in the above verse, it is to be taken to refer to the number of given digits which are sought to be permuted. Given n distinct digits, the verse states that the count of numbers which can be formed using all the digits is the product of all the numbers from 1 to n. In modern mathematics, this permutation is usually represented by the notation \({}^{n}P_n\). Using the factorial notation (n!) to represent the product of the first n integers, the rule given in the verse can be represented mathematically as follows:
We can prove the rationale for this rule by arguing in the following manner.Footnote 4 Given a single digit, it is obvious that only one number can be formed from it. Given two digits, two numbers can be formed by interchanging the position of the digits.Footnote 5 When we have three digits, the third digit can be placed in three places (i.e. the units, tens, or hundreds place), while the first two digits occupy the other two positions. However, as the first two digits can be ordered in \(2 = 2!\) ways, the count of numbers which can be formed with three digits equals \(2!\times 3 = 3! = 6.\) Given four digits, the fourth digit can be placed in four different positions. However, as the other three digits can be ordered in 3! ways, we obtain \(3!\times 4 = 4! = 24\) possible numbers which can be formed from the given four digits. Continuing in like manner, given n digits, we can form \((n-1)!\times n = n!\) different numbers.
In the course of commenting upon the above verse, Munīśvara also discusses the construction of a prastāra, as well as the uddiṣṭa and naṣṭa processes. In the coming sections, we present Munīśvara’s discussion by quoting relevant verses from his commentary and attempt to explain their significance. Munīśvara commences his discussion with a brief description of how a prastāra is to be constructed with a set of given digits. This is explained in the next section.
3 Constructing the prastāra
3.1 What is a prastāra?
Before entering into the mathematical aspects of constructing a prastāra, we would like to briefly discuss the etymological derivation of the word prastāra, which will help us to appreciate how meaningfully the technical term has been coined to subtly indicate the process involved. The word prastāra stems from the verbal root स्तृ which has different shades of meaning such as, to spread, strew, cover, expand and so on. In the texts dealing with grammar, the verb is defined as:
स्तृ (स्वादिः उभयपदी सकर्मकः अनिट्)
स्तृञ् आच्छादने ।
By adding a prefix and a suffix to this verb we get the word prastāra:
प्र + स्तृ+ घञ् = प्रस्तारः ।
It is essentially a technical term (paribhāṣā) that is used to refer to the process of listing out all the possible variations that one can have with a given set of variables. Some possible variables can be:
-
Syllables (guru, laghu, etc.)
-
Musical notes (sa, ri, ga, ma, etc.)
-
Digits (1, 2, 3, 4, etc.)
Thus, naturally, we find the word prastāra appearing in texts dealing with prosody, music, dance, and mathematics. Though primarily employed to refer to the process of generating the variations (karaṇa-vyutpatti), it can also be used to refer to the patterns that are generated (karma-vyutpatti).
Historically, Bharata’s Nāṭyaśāstra (a treatise on performing arts) is one of the earliest extant texts in which we encounter the term prastāra. The term is also employed in the Vṛttaratnākara, a text on prosody written by Kedārabhaṭṭa (14th century CE), as well as the Saṅgīta-ratnākara, a text dealing with musicology, authored by Śārṅgadeva (13th century CE). In the Līlāvatī, Bhāskara employs the term saṅkhyāvibheda to refer to the total number of possible variations, which is equivalent to the number of rows in the prastāra.
3.2 Algorithm for constructing a prastāra
The Nisṛṣṭārthadūtī, elaborating upon Bhāskara’s rule given in Sect. 2, shows how to systematically list the various permutations of a given set of digits. The text gives the following general rule for the construction of a prastāra:
न्यसेदग्र्यादधो मूले मौलौ पूर्वं विलक्षणम् ।
यथोर्ध्वं पुरतः पूर्वं क्रमादित्यसमे क्रमे ॥Footnote 6
nyasedagryādadho mūle
maulau pūrvaṃ vilakṣaṇam |
yathordhvaṃ purataḥ pūrvaṃ
kramādityasame krame ∥
Below the higher [order entity] as per the original sequence, place the immediately preceding [entity] which is different [from those appearing to the right] in the immediately preceding row.Footnote 7 To the front of that (i.e., to the right of it) write down the [pattern] as above. Before (i.e., to the left) to that, place the [remaining] digits in increasing order. This is the procedure in the case of distinct entities.
The Nisṛṣṭārthadūtī further clarifies the algorithm through the following one and half verses:Footnote 8
उद्दिष्टाङ्कान् क्रमान्न्यस्य स्थाप्यः पूर्वः परादधः।
स चेदुपरि तत्पूर्वः पुरस्तूपरिवर्तिनः॥
उद्दिष्टाङ्कक्रमात् पृष्ठे शेषाः प्रस्तार ईदृशः।
uddiṣṭāṅkān kramānnyasya
sthāpyaḥ pūrvaḥ parādadhaḥ |
sa cedupari tatpūrvaḥ
purastūparivartinaḥ ∥
uddiṣṭāṅkakramāt pṛṣṭhe
śeṣāḥ prastāra īdṛśaḥ |
Having placed the intended digits in order, [in order to get the next pattern] place the previous digit below the next one. If it is lying in front (i.e., rightwards), then the previous to that [has to be placed]. Next to that, place those digits which are in the above/previous pattern. Towards the left/back, place all the remaining digits in the intended order. Thus is how the prastāra [is generated].
All the patterns formed by permuting a given set of distinct digits can be enumerated in the form of an array. The above verses present a systematic method of enumeration of all the sequences of a given set of digits. The procedure outlined here, which in effect is a sorting algorithm which reverses the starting pattern, can be summarised in the following manner:
-
1.
Consider a set of n distinct digits (aṅkas), in a given sequence, denoted by \(a_1, a_2, \ldots a_n,\) where \(n\le 10.\) Alternately, consider a n-digit number \(a_1\,a_2 \ldots a_n\) with distinct digits, where also \(n\le 10.\) Though not stated explicitly in the verse, for convenience, we may refer to this original or starting sequence as the mūla-paṅkti.Footnote 9
-
2.
For generating all possible patterns of the above set of digits in successive rows, start scanning the mūla-paṅkti from the left. Moving left to right, compare each consecutive pair of digits \(a_p\) and \(a_q.\) If \(q>p\), then place \(a_{q-1}\) below \(a_q.\) If \(a_{q-1}\) already appears to the right of \(a_q,\) then place the immediately preceding digit \(a_{q-2}\) below \(a_q.\) If that also appears to the right, then consider \(a_{q-3}\) and so on. This is indicated by the word vilakṣaṇam in the first verse. The same thing is stated more clearly in the next verse by the phrase sa cedupari tatpūrvaḥ.
-
3.
Bring down the digits to the right of \(a_q\) without modification. This process is indicated by the phrase purastūparivartinaḥ. Whereas the word puraḥ normally means “in the front”, here it is to be taken in the sense of “to the right” of \(a_q.\)
-
4.
To the left, arrange the remaining digits (\(a_i\)) in the ascending order of i, indicated by the phrase uddiṣṭāṅkakramāt in the verse.
-
5.
Repeat the process until the original order of the digits is reversed.
The last point in the above algorithm has not been stated explicitly in either the Nisṛṣṭārthadūtī or the Saṅgīta-ratnākara. This is likely because one cannot proceed any further after obtaining the reverse order. In other words, we cannot find any consecutive pair of digits \(a_p\) and \(a_q,\) as we scan from the left, where \(q>p.\) This is evident in the last rows of Figs. 1b and 2. However, this point has indeed been stated explicitly by Nārāyaṇa Paṇḍita in the Aṅkapāśa chapter of his Gaṇita-kaumudī, which we briefly discuss in Sect. 3.4.
3.3 Illustration of prastāra with an example
Munīśvara illustrates the procedure of constructing a prastāra by solving one of the problems posed by Bhāskara in the following verse of the Līlāvatī:
द्विकाष्टकाभ्यां त्रिनवाष्टकैर्वा
निरन्तरं द्व्यादिनवावसानैः ।
सङ्ख्याविभेदाः कति संभवन्ति
तत्सङ्ख्यकैक्यानि पृथग्वदाशु ॥
dvikāṣṭakābhyāṃ trinavāṣṭakairvā
nirantaraṃ dvyādinavāvasānaiḥ |
saṅkhyāvibhedāḥ kati saṃbhavanti
tatsaṅkhyakaikyāni pṛthagvadāśu ∥
How many different numbers are possible [to be generated] with [the digits] two and eight; three, nine and eight; and [the digits] starting with two and ending with nine (2 to 9)? Separately, quickly tell the sums of those [generated] numbers [in each of the above three cases].
The above verse poses three problems: How many varieties of numbers are possible, and what would be their total sum, with the digits (i) 2 and 8, (ii) 3, 9 and 8, and (iii) 2 to 9? As a solution to the second problem, Munīśvara lists out the various possible patterns as shown in Fig. 1a. In order to facilitate the readers to have a feel for the various patterns which emerge as we write out the prastāra, we also list out the pattern in its general form, denoting the three digits as \(a_1,a_2\) and \(a_3,\) in Fig. 1b. It can be observed that the starting pattern gets completely reversed at the end of the prastāra. This method can be extended to depict permutations involving any number of digits. For enhanced comprehension, we also depict a general prastāra constructed employing four digits \(a_1,a_2,a_3\) and \(a_4\) in Fig. 2.
3.4 Nārāyaṇa’s algorithm for constructing a prastāra
Nārāyaṇa Paṇḍita gives the following algorithm for the construction of a prastāra in the Aṅkapāśa chapter of his Gaṇita-kaumudī:
लघुपूर्वोद्दिष्टाङ्क-
न्यासोFootnote 10 यः स क्रमाह्वयो ज्ञेयः ।
न्यस्याऽल्पमाद्यान्महतः
अधस्ताच्छेषं यथोपरि तथा स्यात्Footnote 11 ॥ ४९॥
मूलक्रमं तदूने यावत् क्रममुत्क्रमं याति ।
अङ्कप्रस्तारविधिश्चैवं मूर्तिप्रभेदानाम् ॥५०॥
सरिगमपधनीत्येषां वीणाया निक्वणानां च ।
laghupūrvoddiṣṭāṅka-
nyāso yaḥ sa kramāhvayo jñeyaḥ |
nyasyā’lpamādyānmahataḥ
adhastāccheṣaṃ yathopari tathā syāt ∥49∥
mūlakramaṃ tadūne yāvat kramamutkramaṃ yāti |
aṅkaprastāravidhiścaivaṃ mūrtiprabhedānām ∥50∥
sarigamapadhanītyeṣāṃ vīṇāyā nikvaṇānāṃ ca |
It is to be known that arranging the given numbers (uddiṣṭāṅka) with the small ones at the beginning [of the sequence] (i.e., in ascending order) is termed as [mūla]krama. Having constructed [the mūlakrama, in order to obtain the successive rows of the prastāra, as we start scanning each row from the left], when we first encounter an element which is of higher order (mahat) [than the preceding one], place right below that (adhastāt) the element that is preceding (alpam) [immediately or otherwise in the mūlakrama], such that the remaining [places to the right of this] would be filled with the same [numbers/entities] as above. Towards the left of that (tadūne) [the remaining entities are to be placed] as per mūlakrama. [This operation is to be continued] till the sequence of the [mūla]krama gets completely reversed. This is the rule for generating the permutations of numbers. The same [rule] is applicable for finding the variations in idols as well as [the svarās] Sa, Ri, Ga, Ma, Pa, Dha, Ni, etc., and the musical notes (nikvaṇa) of the Vīṇā.
It may be noted that Nārāyaṇa’s algorithm explicitly mentions the last point of the algorithm given by us in Sect. 3.2, noting that the operation has to be continued until the starting order is completely reversed. In addition, a couple of other points are also noteworthy in Nārāyaṇa’s exposition of the algorithm. Firstly, he does not explicitly state the conditional clause corresponding to the second point in the algorithm outlined by us in Sect. 3.2. That is, if \(q>p\) in two consecutive digits \(a_p\) and \(a_q,\) we place \(a_{q-1},a_{q-2}\) or so on below \(a_q\) only if they do not appear to the right of \(a_q,\) the condition brought out by the phrase ‘sa cedupari tatpūrvaḥ’ employed by Munīśvara. However, this clause can be indirectly inferred by interpreting Nārāyaṇa’s verse as in Footnote 11. Secondly, Nārāyaṇa clearly states that the given elements must be initially arranged in an ascending sequence, called krama, prior to the construction of the prastāra.Footnote 12
We shall briefly demonstrate the construction of a prastāra using Nārāyaṇa’s algorithm with two examples—one with distinct digits (7, 3 and 9), and the other with repeating digits (5, 3, 5 and 3). As per the prescription of Nārāyaṇa, we would have to first arrange these digits in ascending order as 3, 7, 9 and 3, 3, 5, 5 respectively. These two sequences would form the first rows of their respective prastāras. The construction of the rest of the prastāra would then continue as outlined by us in the algorithm given in Sect. 3.2.Footnote 13 The generated prastāras are showin in Fig. 3.
3.5 Remarks
This concludes the discussion on the construction of a prastāra. Next, in principle, we should move on to the discussion of the other two pratyayas, namely, uddiṣṭa and naṣṭa. However, these two processes cannot be explained without the construction of a table called the khaṇḍa-meru. Hence, following in the footsteps on Munīśvara, we too shall first describe the procedure for constructing a khaṇḍa-meru in the next section.
4 Constructing the khaṇḍameru
4.1 The need for the khaṇḍameru
Before getting into the verse given by Munīśvara, which explains the need for the construction of the khaṇḍameru, we briefly explain the formation of the word meru and its significance in the present context. The word meru is formed by adding a suffix to the verbal root मि (डुमिञ् प्रक्षेपणे), which can have different meanings such as, to arrange, scatter or throw. Technically speaking, its formation is explained as follows:
मि + रु = मेरुः (suffix prescribed by the sūtra मिपीभ्यां रुः)
Essentially the word meru refers to a certain arrangement of objects in a structured manner, though the objects themselves may be widely varying. In the study of prosody, the term refers to the arrangement of groups of laghu and guru syllables. In fact, in the Chandas-śāstra, the term meru refers to the specific arrangement of binomial coefficients, more popularly known today as the Pascal’s triangle. In the study of aṅkapāśa, which is the topic of discussion of this paper, the word meru refers to a certain kind of arrangement of numbers involving factorials of integers and their multiples. In order to distinguish this meru from the one used in the study of prosody, this meru is generally referred to as the khaṇḍameru.Footnote 14
As we saw earlier, a prastāra is essentially the sequential layout of various possible patterns in the form of rows. The technical terms naṣṭa and uddiṣṭa refer to the processes of finding out the pattern, given a row number, and vice versa respectively. As will be evident soon, in order to carry out either process, the khaṇḍameru is an extremely useful tool—particularly for beginners. With sufficient practice, one could perhaps dispense away with the construction of the khaṇḍameru, and execute the process mentally, at least for lower orders of the prastāra. Outlining the purpose of the khaṇḍameru, Munīśvara states:
तच्छुद्ध्यर्थं नष्टोद्दिष्टसूचको मेरुश्च अभियुक्तैरुक्तः ।
tacchuddhyarthaṃ naṣṭoddiṣṭasūcako meruśca abhiyuktairuktaḥ |
In order to verify it, the meru, the indicator of naṣṭa and uddiṣṭa, has been given by [earlier] scholars.
In this succinct half verse cited by Munīśvara, two purposes are laid out for the construction of the khaṇḍameru:
-
1.
Executing the process of naṣṭa and uddiṣṭa.
-
2.
Verifying the correctness of the prastāra that has been laid down.
The earlier purpose is indicated by the word sūcaka, whereas the latter is indicated by the word śuddhyartham. With the above background in mind, the method to construct the khaṇḍameru is described in the following section.
4.2 The algorithm for constructing the khaṇḍameru
The Nisṛṣṭārthadūtī gives the following rule for constructing a khaṇḍameru:
इष्टाङ्कमितकोष्ठाद्या पङ्क्तिर्व्येकादिका अधः ।
आद्यपङ्क्त्यादिकोष्ठे तु लिखेदेकं परेषु खम् ॥
सङ्ख्याङ्कास्तदधः पङ्क्तौ द्वित्र्यादिगुणितानधः ।
iṣṭāṅkamitakoṣṭhādyā
paṅktirvyekādikā adhaḥ |
ādyapaṅktyādikoṣṭhe tu
likhedekaṃ pareṣu kham ∥
saṅkhyāṅkāstadadhaḥ paṅktau
dvitryādiguṇitānadhaḥ |
The first row would have cells equal to the number of desired digits. The rows below would have cells lesser than that by one, [two], etc. Write down [the number] ‘one’ in the first cell of the first row, and zeros in others [to the right of it]. In the row below that, write down the factorials (saṅkhyāṅkāḥ) of the digits [starting from one]. Their multiples (twice, thrice and so forth) should be written down [further in the corresponding cells] below.
Before we address the mathematical aspects of the above verse, we would like to briefly comment upon a grammatical issue. In the third line of the verse cited above, Munīśvara employs the term saṅkhyāṅkāḥ to refer to a factorial. This is perhaps a truncated form of the expressions saṅkhyāvibhedāṅkāḥ and saṅkhyāvibhedāḥ employed by Bhāskara. Thus, the term saṅkhyāṅkāḥ can be understood as a madhyama-pada-lopi-samāsa, just as the word tribhajyā is more often than not written simply as trijyā for convenience. Alternatively, the compound saṅkhyāṅkāḥ can be understood to have been coined in the following manner:
[उद्दिष्टैः / दत्तैः] अङ्कैः परस्परविनिमयेन उत्पन्नाः सङ्ख्याः = सङ्ख्याङ्काः।Footnote 15
With the given digits, by mutually interchanging their positions, the number that is obtained [is saṅkhyāṅka].
This way of explaining the formation of the compound has the advantage of preserving the meanings of the words aṅka and saṅkhyā as digit and number respectively, the senses in which they are generally employed, though there is no steadfast rule.
With regards to its mathematical content, the above verse describes the construction of a khaṇḍameru in its most general form through the use of the word iṣṭāṅka or “the desired number of digits”. If n be the desired number of digits, the verse states that the first row of the khaṇḍameru should have n cells, of which, the first cell is to be filled with the number 1 and the rest of the \(n-1\) cells are to be filled with the number 0. The second row contains \(n-1\) cells, which are filled with the factorials of the numbers 1 to \(n-1.\) In the succeeding rows, the successive multiples (twice, thrice, etc.) of the factorials are placed. The general khaṇḍameru thus formed is depicted in Fig. 4a. A sample khaṇḍameru of nine digits is depicted in Fig. 4b.
The khaṇḍameru is critical to the uddiṣṭa and naṣṭa processes and the entire rationale for these procedures, involving the factorial representation of integers, is explained by Sridharan et al. (2010). In the coming sections, we shall outline only the procedure for the uddiṣṭa and naṣṭa processes, involving the application of the khaṇḍameru, as described in the Nisṛṣṭārthadūtī.
5 Uddiṣṭa process
The word uddiṣṭa means “indicated”. The uddiṣṭa process enables one to directly determine the row number of a given or an intended pattern in a prastāra which was constructed using the procedure described in Sect. 3.2. Thus, this process allows one to avoid the laborious process of generating the entire prastāra. Munīśvara explains the procedure using the following verses:
इष्टाङ्कसम्मितान् लोष्टान् आद्यपङ्क्तौ न्यसेद्बुधः ।
मूलक्रमान्त्याद् यत्सङ्ख्यः उद्दिष्टोन्त्योऽङ्कको भवेत् ॥
तत्सङ्ख्ये कोष्ठके लोष्टं क्षिपेदन्त्यं पुनः पुनः ।
उभयत्रापि लब्धोऽङ्को लोपनीय इति क्रमात् ॥
लोष्टकोष्ठाङ्कयोगे स्यात् सङ्ख्योद्दिष्टप्रबोधकृत् ।
iṣṭāṅkasammitān loṣṭān
ādyapaṅktau nyasedbudhaḥ |
mūlakramāntyād yatsaṅkhyaḥ
uddiṣṭontyo’ṅkako bhavet ∥
tatsaṅkhye koṣṭhake loṣṭaṃ
kṣipedantyaṃ punaḥ punaḥ |
ubhayatrāpi labdho’ṅko
lopanīya iti kramāt ∥
loṣṭakoṣṭhāṅkayoge syāt
saṅkhyoddiṣṭaprabodhakṛt |
The intelligent onesFootnote 16 must place clay pellets (loṣta), equal to the number of desired digits [that are considered for permutation], in the first row [of the khaṇḍameru]. Considering the last digit of the intended/given (uddiṣṭa) pattern, whatever is its rank in the original sequence from the end, in the cell having that count (tatsaṅkhye koṣṭhake) [from the top], place the clay pellet. The digit for which the number/cell has been found should be erased from both [the original sequence and the given sequence]. [The process has to be repeated] again and again taking the [new] last digit [until all the digits are exhausted]. The sum of the numbers in the cells having clay pellets gives the row number of the intended pattern.
The above verses explain the procedure of employing the khaṇḍameru in order to obtain the position of the intended pattern in the prastāra. The algorithm works as follows:
-
1.
Given a pattern with n digits, firstly construct an appropriately sized khaṇḍameru. The number of cells in the first row would be equal to the number of digits n.
-
2.
Place one clay pellet in each cell of the first row (iṣṭāṅkasammitān loṣṭān ādyapaṅktau nyaset).
-
3.
Consider the last digit of the intended pattern and determine its position in the mūla-paṅkti from the right (reverse order). Let this position be m.
-
4.
Move the clay pellet in the nth column of the khaṇḍameru to the mth row.
-
5.
Erase the digit from the intended sequence as well as the mūla-paṅkti.
-
6.
Now, consider the new last (\(n-1\))th digit in the intended sequence and repeat the above procedure.
-
7.
The sum of the numbers in the cells containing clay pellets at the end of the procedure will give the row number of the intended pattern in the prastāra.
We illustrate the above algorithm with the following example.
5.1 Example
Find the row number corresponding to the pattern \(a_1\,a_4\,a_3\,a_2,\) given the original sequence (mūla-paṅkti) is \(a_1\,a_2\,a_3\,a_4.\)
To determine the serial number of the intended sequence in the prastāra constructed using the method described in Sect. 3.2, we employ the algorithm described above in the following manner:
-
1.
First, we construct a khaṇḍameru as described in Sect. 4.2. As the intended pattern contains four digits, the first row of the khaṇḍameru will contain four cells as shown in Fig. 5a, with one clay pellet in each cell of the first row.
-
2.
Now, the last digit of the intended sequence is \(a_2.\) The position of \(a_2\) in the mūla-paṅkti from the right is 3. Thus, in the fourth column of the khaṇḍameru, we place the clay pellet in the third row, in the cell containing the number 12, as shown in Fig. 5b.
-
3.
Next, erasing \(a_2\) from the mūla-paṅkti as well as the intended sequence, we obtain the new mūla-paṅkti \(a_1\,a_3\,a_4\) and the new intended sequence \(a_1\,a_4\,a_3.\) Now, we note that \(a_3\) is the last (3rd) digit in the intended sequence and the second digit from the right in the mūla-paṅkti. Thus, in the third column of the khaṇḍameru, we place the clay pellet in the second row, in the cell containing the number 2, as shown in Fig. 5b.
-
4.
The new mūla-paṅkti and intended sequence are \(a_1\,a_4\) and \(a_1\,a_4\) respectively. The last (2nd) digit \(a_4\) in the intended sequence is in the first position from the right in the mūla-paṅkti. Hence, in the second column of the khaṇḍameru, we leave the clay pellet as it is in the first row in the cell containing the number 0, as shown in Fig. 5b.
-
5.
The new mūla-paṅkti and intended sequence are \(a_1\) and \(a_1\) respectively. There is nothing to be done at this stage. The final clay pellet will remain as it is in the first row of the first column of the khaṇḍameru, containing the number 1, as shown in Fig. 5b.
-
6.
Adding all the numbers in the cells containing the clay pellets, we obtain the row number of the intended sequence in the prastāra as \(12 + 2 + 0 + 1 = 15.\) It is easily verified from Fig. 2 that the intended sequence \(a_1\,a_4\,a_3\,a_2\) is indeed in the 15th row in the constructed prastāra.
6 Naṣṭa process
The naṣṭa process is the inverse of the uddiṣṭa process. The word naṣṭa literally means “annihilated” or “lost”. This process helps to quickly determine the pattern associated with a given row number of the prastāra. The Nisṛṣṭārthadūtī gives the following procedure for this exercise:
पृष्टे नष्टे नष्टसङ्ख्या भवेद्यैः
मूलैकाङ्केनान्वितैः कोष्ठकाङ्कैः ।
अङ्केष्वेतान् लोष्ठकान् स्थापयित्वा
लोष्टादन्त्यात् कोष्टकेऽधः क्रमेण ॥
लोष्टो यत्सङ्ख्येऽस्ति मूलक्रमान्त्यात्
तत्सङ्ख्यो यः स्थाप्यतामीप्सितान्त्यात् ।
स प्राक्पङ्क्तौ लोपनीयः सुधीभिः
एवं भूयोऽभीप्सितोऽयं क्रमः स्यात् ॥
pṛṣṭe naṣṭe naṣṭasaṅkhyā bhavedyaiḥ
mūlaikāṅkenānvitaiḥ koṣṭhakāṅkaiḥ |
aṅkeṣvetān loṣṭhakān sthāpayitvā
loṣṭādantyāt koṣṭake’dhaḥ krameṇa ∥
loṣṭo yatsaṅkhye’sti mūlakramāntyāt
tatsaṅkhyo yaḥ sthāpyatāmīpsitāntyāt |
sa prākpaṅktau lopanīyaḥ sudhībhiḥ
evaṃ bhūyo’bhīpsito’yaṃ kramaḥ syāt ∥
When the lost [pattern corresponding to the given row number] is asked [to be found], then by combining whichever cell-numbers (i.e., numbers in the cells) along with [the number] one in the top row (mūlaikāṅka), the [row] number corresponding to the lost pattern (naṣṭa-saṅkhyā) is obtained, place clay pellets (loṣṭa) on [those] numbers/cells [in the khaṇḍameru]. After that, starting from the last pellet [among those], in whichever row downwards [from the top row] the pellet is found, at that row-count whatever digit is found in the mūla-paṅkti from the last, that would be placed in the last position of the desired [pattern]. That [digit] has to be erased from the mūla-paṅkti. Again (bhūyaḥ), [the process is] repeated [until the first pellet is reached]. The pattern [obtained] would be that one which was desired.
The word naṣṭasaṅkhyā that we find right at the beginning of the verses quoted above needs some explanation. This is a compound word (samasta-pada) that can be compounded in many ways:
नष्टा या सङ्ख्या सा = नष्टसङ्ख्या ।
नष्टा सङ्ख्या यस्याः सा = नष्टसङ्ख्या ।
नष्टस्य सङ्ख्या = नष्टसङ्ख्या ।
Of the three derivations given, the third is the most suitable in this context, with a slight emendation for the sake of greater clarity. The meaning obtained from the first derivation is not relevant in this context, as there is no number which is lost here. The second derivation (which is a bahuvrīhi compound) is also not meaningful, as we are not referring to any third party here, who has lost or forgotten a number (say the registration number). The third derivation is close to the meaning that is intended in the present context. The intended meaning becomes quite clear by emending the third derivation by supplying a word:
नष्टस्य [क्रमस्य] सङ्ख्या = नष्टसङ्ख्या ।
The [row] number correspondingFootnote 17 to the lost [pattern or krama].
The aim of the naṣṭa process is to determine the sequence in which the elements (digits here) are arranged in the desired row number. In fact, both the desired row number and the digits that constitute that row are already known. Only the pattern (krama) is lost. Hence, for greater clarity, the derivation of the compound naṣṭasaṅkhyā in this context may be stated as:
नष्टक्रमपङ्क्तिसङ्ख्या = नष्टसङ्ख्या ।
The above derivation may technically be referred to as madhyama-pada-lopi-samāsa.
We now move on to explain the procedure of employing the khaṇḍameru to obtain the pattern (with n digits) corresponding to a desired row number m in the prastāra. The algorithm works as follows:
-
1.
First, construct a khaṇḍameru as described in Sect. 4.2. The number of cells in the first row would be equal to the number of digits n.
-
2.
Through careful inspection, select one number from each column of the khaṇḍameru, including the number 1 from the first column, such that their sum equals the desired row number m.Footnote 18 Place clay pellets in the corresponding cells of the khaṇḍameru by dropping them down, wherever required, from their original position in the cells of the first row.
-
3.
Let \(r_1, r_2, \ldots, r_n\) correspond to the row numbers containing the clay pellets in each column, from the first to the last.
-
4.
Scan the mūla-paṅkti from the right and determine the \(r_n\)th digit. This will correspond to the nth (last) digit of the pattern in the mth row.
-
5.
Delete this digit from the mūla-paṅkti and scan the modified mūla-paṅkti from the right and determine the \(r_{n-1}\)th digit. This will correspond to the (\(n-1\))th (penultimate) digit of the pattern in the mth row.
-
6.
Repeat the process to determine the entire pattern.
The above algorithm is best understood with the help of the following example.
6.1 Example
Determine the lost pattern of the 17th row of a prastāra constructed using four digits, with the mūla-paṅkti \(a_1\,a_2\,a_3\,a_4.\)
The above problem can be solved by employing the given algorithm in the following manner:
-
1.
First, we construct a khaṇḍameru as described in Sect. 4.2. This is shown in Fig. 6a.
-
2.
To determine the pattern in the 17th row of the prastāra we should pick one number from each column such that their total is 17. Thus, the unique combination we obtain is \(1 + 0 + 4 + 12 = 17.\)
-
3.
The rows in which the above numbers occur are given by \(r_1 = 1,r_2 = 1,r_3=3\) and \(r_4=3.\)
-
4.
Scanning the mūla-paṅkti from the right, we determine the digit at the \(r_4\)th position. This corresponds to \(a_2,\) the third digit from the right. Thus, \(a_2\) is the fourth (last) digit in the 17th row of the prastāra.
-
5.
Eliminate \(a_2\) from the mūla-paṅkti. The new mūla-paṅkti will be \(a_1\,a_3\,a_4.\) Scanning the new mūla-paṅkti from the right, determine the digit in the \(r_3\)th position. This corresponds to \(a_1,\) the third digit from the right. Thus, \(a_1\) is the third (penultimate) digit in the 17th row of the prastāra.
-
6.
Eliminate \(a_1\) from the mūla-paṅkti. The new mūla-paṅkti will be \(a_3\,a_4.\) Scanning the new mūla-paṅkti from the right, determine the digit in the \(r_2\)th position. This corresponds to \(a_4,\) the first digit from the right. Thus, \(a_4\) is the second digit in the 17th row of the prastāra.
-
7.
Eliminate \(a_4\) from the mūla-paṅkti. The new mūla-paṅkti will be \(a_3.\) As the only remaining digit, \(a_3\) will correspond to the first digit in the 17th row of the prastāra.
-
8.
Thus, the pattern in the 17th row of the prastāra is \(a_3\,a_4\,a_1\,a_2,\) as verifiable from Fig. 2.
7 Discussion
Paṇḍit Sudhākara Dvivedī has been extremely generous in his praise for Munīśvara’s Nisṛṣṭārthadūtī, employing the epithet uttamottama to describe it as the best among the excellent commentaries on Bhāskara’s Līlāvatī.Footnote 19 A study of Munīśvara’s commentary on the Aṅkapāśa chapter of the Līlavatī does no harm to the veracity of this claim. In his commentary, Munīśvara lucidly explains the rationale for the rules of permutation given by Bhāskara. Notwithstanding Bhāskara’s discussion of permutations mainly in the context of sets of numbers, Munīśvara, following in the footsteps of Nārāyaṇa Paṇḍita, brings in combinatorial techniques developed in the context of prosody and music—such as the construction of a prastāra, and the uddiṣṭa and naṣṭa processes—and discusses their application in the numerical context. To this end, he presents a number of verses which discuss these processes in a detailed and unambiguous fashion. In addition, he works out examples to facilitate the understanding of the processes. As a net result, the Nisṛṣṭārthadūtī serves as an important text to understand the development of combinatorial techniques in the Indian historical context. In light of the importance of this text, we intend to bring out further studies of this text in the future. For instance, Munīśvara also discusses the construction of a prastāra with a set of digits containing repetitions (i.e., the set may contain more than one instance of one or more digits). We hope to discuss this interesting topic in an upcoming paper.
Notes
The Nisṛṣṭārthadūtī is perhaps the most extensive and comprehensive commentary on the Līlāvatī. Paṇḍit Sudhākara Dvivedī has called it the “best among the excellent” commentaries of the Līlāvatī. For a brief overview of Munīśvara and the Nisṛṣṭārthadūtī, see Kolachana et al. (2017). This commentary is yet to be published. The authors obtained copies of two manuscripts of the Nisṛṣṭārthadūtī from the Sarasvati Bhavana Library, Sampurnanand Sanskrit University, Varanasi.
A more extensive discussion of aṅkapāśa, consisting of over 90 verses, is carried out by Nārāyaṇa Paṇḍita (14th century CE) in his Gaṇita-kaumudī.
From the way these verses are presented in the Nisṛṣṭārthadūtī, it appears as though Munīśvara is quoting an earlier author or text. However, we have been unable to trace these verses in earlier literature, except in the case of one verse and a half (see Sect. 3.2) which are clearly a modification of two verses appearing in the Saṅgīta-ratnākara.
Based on Gaṇeśa’s argument in his Buddhivilāsinī, expanded here for greater clarity. See Apte (1937).
That is, the second digit can be placed either to the left or to the right of the first digit, to generate two different numbers.
The verse can be understood in the following manner: [प्रस्तारे यस्मात् क्रमात् अग्रिमक्रमः लेख्यः तत्र]—मूले (मूलक्रमानुसारेण) अग्र्यात् अधः, [यत् अग्र्यात्] पूर्वं [तत्], [यच्च] मौलौ (पूर्वपङ्क्तौ) [अग्रिमाङ्केभ्यः] विलक्षणं [पूर्वं] न्यसेत्। [तस्मात्] पुरतः यथोर्ध्वं [तथा]। पूर्वं [तु] क्रमात् न्यसेत्। इति असमे क्रमे (असमानाम् अङ्कानां क्रमे) [भवति]।
The previous row which forms the basis (mūla) for the construction of the next row.
Here, Munīśvara appears to have been inspired by similar verses (62–63) in the Saṅgīta-ratnākara, appearing in the Grāmamūrchanā-kramatānaprakaraṇa, which is the fourth section of the first chapter called the Svargatādhyāya. It appears that Munīśvara has modified these verses suitably to address a problem involving digits rather than musical notes. See Shastri (1940, p. 130).
The cue for coining this word has been taken from other verses in the Nisṛṣṭārthadūtī. See for instance the verses quoted in Sect. 5.
This portion of the verse can be understood as follows (vigrahavākya): लघुपूर्वः यथा स्यात् तथा उद्दिष्टाङ्कस्य न्यासः। In the case of ordinal sets, such as numbers, svaras, etc., deciding on what constitutes laghu is straightforward. Whereas in the case of nominal sets, such as the set of weapons of Viṣṇu, we may have to assign an order to the elements of the set for constructing a prastāra, since there is no natural order to them.
The prose order here is—शेषं यथोपरि स्यात् तथा अल्पं आद्यानमहतोऽधस्तात् न्यस्य।
Commencing the operation after arranging the numbers in ascending order is particularly convenient in constructing a prastāra with repeating elements, as shown in Fig. 3b.
In fact, once we start with numbers in the ascending order, the second step of the algorithm can also be stated and executed in a simpler manner making use of this natural sequence.
The word meru is employed in the spiritual tradition as well. There, it refers to a three-dimensional representation of what is known as the Śrī-cakra, which is essentially an arrangement of geometrical patterns.
The formation of compounds by swapping the sequence of the words that constitute the compound is grammatically permitted by the following sūtra of Pāṇinī: राजदन्तादिषु परम् (2.2.31). Thus, we have the examples दन्तानां राजा राजदन्तः and वनस्य अग्रे अग्रेवनम्.
For translation, we have considered the word budhaḥ as jātyekavacanam (collective singular).
The sixth case usually denotes a relation. Here the relation is one of one-to-one correspondence between the row number and the sequence or pattern (krama).
The appropriate numbers can be quickly identified by starting with the largest number (say \(k_n\)) lesser than the desired row number m in the last (nth) column of the khaṇḍameru. The next number (\(k_{n-1}\)) can be identified by selecting the largest number lesser than \(m-k_n\) in the \((n-1)\)th column of the khaṇḍameru. The third number (\(k_{n-2}\)) can be idenitified by selecting the largest number lesser than \(m-k_n - k_{n-1}\) in the \((n-2)\)th column of the khaṇḍameru. This process must be repeated to obtain one number from each column, such that their sum equals m.
See Dvivedi (1933, p. 91).
References
Āpte, D. (1937). Bhāskarācārya’s Līlāvatī with the commentaries Buddhivilāsinī and Līlāvatīvivaraṇa (Vol. 2). Ānandāśrama Sanskrit Series 107. Vināyaka Gaṇeśa Āpṭe.
Bag, A. K. (1979). Mathematics in Ancient and Medieval India. Chaukhambha Orientalia.
Colebrooke, H. T. (1817). Algebra, with arithmetic and mensuration, from the Sanscrit of Brahmegupta and Bháscara. John Murray.
Datta, B., & Singh, A. N. (1992). Use of permutations and combinations in India. Indian Journal of History of Science, 27(3), 231–249.
Dvivedi, P. (Ed.). (1942). The Gaṇita-kaumudī by Nārāyaṇa Paṇḍita. Varanasi (formerly Benares)
Dvivedi, S. (1933). Gaṇakataraṅgiṇī (2nd ed.).
Kolachana, A., Mahesh, K., & Ramasubramanian, K. (2017). Novel proofs for summations in the Nisṛṣṭārthadūtī. Indian Journal of History of Science, 52(2), 124–137.
Munīśvara. (1779). Līlāvatī with the commentary Nisṛṣṭārthadūtī. Sanskrit. Catalogue No. 35861. Mansucript. Sarasvati Bhavana Library of Sampurnanand Sanskrit University.
Munīśvara. (1879). Līlāvatī with the commentary Nisṛṣṭārthadūtī. Sanskrit. Catalogue No. 37313. Mansucript. Sarasvati Bhavana Library of Sampurnanand Sanskrit University.
Patwardhan, K. S., Naimpally, S. A., & Singh, S. L. (2014). Līlāvatī of Bhāskarācāryā (1st ed.). Motilal Banarasidass Publishers Private Limited.
Rao, A. B. P. (2014). Bhāskarācārya’s Līlāvatī (Vol. II). Chinmaya International Foundation Shodha Sansthan.
Roychaudhuri, B. (2007). The dictionary of Hindustani classical music (3rd ed.). Motilal Banarasidass Publishers Pvt. Ltd.
Śarmā, H. (Ed.). (1893–94). Śrutabodha of Kālidāsa and Vṛttaratnākara of Kedārabhaṭṭa. Hariprasāda Śarmā.
Sarma, K. V. (1975). Līlāvatī of Bhāskarācāryā with Kriyākramakarī of Śaṅkara and Nārāyaṇa. Vishveshvaranand Vedic Research Institute.
Śāstrī, N. (Ed.). (1942). Vṛttaratnākara of Kedāra with the commentary Ratnaprabhā. Meharchand Lakshmanadas.
Shastri, S. (Ed.). (1940). Saṅgītaratnākara of Niśśaṅka-Śārṅgadeva with the commentary of Kallinātha and Siṃhabhūpāla. Adyar Library.
Sridharan, R. (2005). Sanskrit prosody, Piṅgala Sūtras and binary arithmetic. In R. Sridharan, G. Emch, & M. D. Srinivas (Eds.), Contributions to the history of mathematics in India (pp. 33–62). Hindustan Book Agency.
Sridharan, R. (2006). Pratyayas for Mātrāvṛttas and Fibonacci numbers. Mathematics Teacher, 42, 120–137.
Sridharan, R., Sridharan, R., & Srinivas, M. D. (2010). Combinatorial methods in Indian music: Pratyayas in Saṅgītaratnākara of Sārṅgadeva. In C. S. Seshadri (Ed.), Studies in the history of Indian mathematics (pp. 55–112). Springer.
Taylor, J. (1816). Lilawati. Literary Society of Bombay.
Acknowledgements
We would like to place on record our sincere gratitude to the Ministry of Education, Government of India, for the generous support extended to carry out research activities on Indian science and technology by way of initiating the Science and Heritage Initiative (SandHI) at IIT Bombay. We would also like to thank the anonymous referee for reviewing our paper and making constructive suggestions.
Author information
Authors and Affiliations
Corresponding author
Rights and permissions
About this article
Cite this article
Mahesh, K., Kolachana, A. & Ramasubramanian, K. Combinatorial techniques in Munīśvara’s Nisṛṣṭārthadūtī. Indian J Hist. Sci. 56, 171–181 (2021). https://doi.org/10.1007/s43539-021-00019-9
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s43539-021-00019-9