You are on page 1of 12

NOWROSJEE WADIA

COLLEGE.
PRESENTS
SEMINAR ON
PINGALAS ALGORITHM OF BINARY SEQUENCE.
BY
Zoya shaikh
Krupa sable
History of Pingala.
• Pingala was an ancient Indian
scholar and mathematician who
made significant contributions
to the field of Sanskrit prosody
(study of poetic meters) around
the 2nd century BCE. His work
is primarily known through the
"Chandaḥśāstra," a treatise on
metrics and poetic
composition.
Binary Sequence and its uses.
• The use of binary sequences in
Pingala's context was primarily
for encoding patterns of syllabic
lengths in Sanskrit poetry. The
algorithm allowed for the
systematic arrangement of
different poetic meters,
showcasing an early instance of
combinatorics in the realm of
literature.
Machine
Digital Computers: Binary sequences form the basis learning.
for digital computing. Computers use binary code to
represent and process information. Every piece of
data, instructions, and storage within a computer is
ultimately expressed as a binary sequence of 0s and
1s. Genetics
and bio
Communication systems: Binary sequences are informatics.
essential in communication systems, where
information is transmitted using binary-encoded
signals. This includes data transmission over
networks, telecommunications, and wireless Error
detection
communication.
Robotics: Binary sequences are used in programming
and controlling robots.
PINGALAS • To begin with an array of binary
1 0
sequence of length 1 is a table of
ALGORITHM two rows . Row 1=0,row 2=1. 2 1
• Every new array of
increasing length is Sequence
If we replace laghu of
generated using a simple
(L)with’1’ and guru(G) • procedure
The .
existing array
length =1
with ‘0’then it transforms replicated, followed by 1 0 0
the metrical pattern into a adding 1 more column to the
replicated array 2 1 0
binary sequence. A binary
• In the first half of the 3 0 1
sequence is a sequence
new column ‘0’ is
composed of 1’s and 0’s inserted and in the 4 1 1
for example: 1,0,0,1and second half ‘1’.
Sequence of
0,1,0,0 • The procedure can be length=2
repeated in this manner
to generated array of
binary sequence.
1 0 0 0 0
2 1 0 0 0
3 0 1 0 0

Binary sequence of 4
5
1
0
1
0
0
1
0
0

length =4 6
7
1
0
0
1
1
1
0
0
8 1 1 1 0
9 0 0 0 1
10 1 0 0 1
11 0 1 0 1
12 1 1 0 1
13 0 0 1 1
14 1 0 1 1
15 0 1 1 1
16 1 1 1 1
Identify row number associated with a particular binary
sequence Uddista
Steps:
• Start with a number 1 current number=1
• Scanning the binary sequence from the right , locate the first ‘1’in the
sequence.
• Multiply the current number by 2.
• Move the next number to the left when ‘1’ is encountered , double the
current number .if ‘0’is encountered double it and subtract from it .
• Continue this till the end of the binary sequence to arrive at the row
number of the sequence.
Identify the binary sequence associated with a particular
row number Nasta
Step:
• Start with the desired row no.
• Divide it by 2, if it is perfectly divisible place ‘1’ in the sequence
• If the number is not divisible by 2 place ‘0’ in the sequence , add 1 to
the number and divide.
• Repeat the process until the binary sequence of required length is
obtained.
Q1. Find the binary sequence associated with12 array of length 4.
Using the Nasta algorithm of pingala, we obtain the sequence as
follows:
• 12 is divisible by 2 , so we place 1, the new number is 6
• 6 is also divisible by 2, hence we plce 1. the new number is 3
• 3 is not divisible by 2 , so we place 0 and add one to it and divide by 2. the
new number is 2.
• Also, 2 is divided by2 so we place 1.
• The required binary sequence associated with 12 array of length 4 is 1101.
Q2. identify the row position of binary sequence ‘1011’ array
of length .
Using the uddista algorithm of pingala we obtain the sequence as follows:

• The first number,’1’ is found in the first position .therefore , the


number is 1x2=2
• The next number is also ‘1’therefore the number is 2x2=4
• The next number is ‘0’ therefore the number is 4x2-1=7
• The last number is ‘1’ Therefore, the number is 7x2=14
• Therefore the row position of the binary sequence 1011 is 14.
summary
• History of Pingala
• Binary sequence and its uses.
• Understanding Pingalas algorithm
• Example of generating the Pinagalas binary
sequence.
• Learning about Nasta and Uddista algorithm
• Examples on Nasta and Uddista algorithm
Thank you

You might also like