Thursday, 27 April 2017

Yoruba Orthography - A case for a new Yoruba alphabet based on Odù Ifá - an opinion.

How did we end up with the current alphabet? 
According to Rev. Samuel Johnson (the author of “The History of the Yorubas from the Earliest Times to the Beginning of the British Protectorate”)...
“After several fruitless efforts had been made either to invent new characters, or adapt the Arabic, which was already known to Moslem Yorubas, the Roman character was naturally adopted, not only because it is the one best acquainted with, but also because it would obviate the difficulties that must necessarily arise if missionaries were first to learn strange characters before they could undertake scholastic and evangelistic work. With this as basis, special adaptation had to be made for pronouncing some words not to be found in the English or any other European language.”
There you have it! We ended up with the Latin script because it would be easy for the Europeans to learn!
Bishop Samuel Ajayi Crowther will forever be remembered for his great service to the Yoruba Nation by creating the alphabet. Nevertheless, with today's technology and new knowledge in Orthography, we can create a better alphabet based on Odù Ifá that will best reflect the tonal nature of the language.
A new alphabet will allow us to do away with the diacritics (àmìn òkè, àmìn ìsàlẹ̀). The current alphabet has only 25 characters, with Odù Ifá, we have 256 to choose from! Better still, we can ditch alphabets altogether and go for logograph just like the Chinese and Japanese.
Over to Yoruba linguists and orthographers to take this forward. Check the following links for inspiration…
Graphics sourced from Wikipedia.




Cryptography Cont. Ìtọ́wò (Taster) - Simple encryption/decryption

Let's assume that during the Ibadan-Ijaye war of 1861-1862, Kurumi - the Àrẹ Ọ̀nàkakanfò (Generalissimo) of the Yoruba army wanted to communicate securely with his Balógun (General) at the frontline, how would he do it?
He could of course send an Àrokò to the General detailing the line of action he should take. To make it more interesting, let's assume he chose to send a short note saying: 
Ẹ ṢIGUN NI AFẸMỌJU (Strike at dawn)
To avoid the content of the note being read and comprehended by the adversaries he could use a variant of the Caesar cipher customised for the Yoruba alphabet to mangle the text.
The Caesar cipher (named after Julius Caesar) is a substitution cipher where each letter in the original message (called the plaintext) is replaced with a letter corresponding to a certain number of letters up or down in the alphabet to create the ciphertext (mangled text).
Below is the Yoruba alphabet (Upper case):
A B D E Ẹ F G GB H I J K L M N O Ọ P R S Ṣ T U W Y
If we shift the alphabet by 6 character to the right, we end up with:
S Ṣ T U W Y A B D E Ẹ F G GB H I J K L M N O Ọ P R
Now, A is S, B is Ṣ, D is T etc
So the original message “Ẹ ṢIGUN NI AFẸMỌJU” becomes:
W NEAỌH NE SYWGBJẸỌ
For this to work though, the Generals (Balogun) must have been told beforehand to shift the alphabet by 6 characters.
This is a very simple encryption that can be broken easily but it does suffice as an example here.
Next time we will use Odù Ifá to create a more secure encryption.


Cryptography Cont. - Matrix, Ifa’s perspective - it is all about rows and columns! Ayò game is a matrix.

Before we get into the practical applications of the things we have learned over the past few posts, we must examine one major Mathematical concept called “Matrix” (not the sci-fi film).
A matrix (plural matrices) is simply a rectangular array of numbers, symbols, or expressions, arranged in rows and columns. 
If you have ever used a spreadsheet software (e.g Microsoft Excel) before, then you have seen a matrix in action. The application of matrices in computing - especially in cryptography is widespread. We shall delve more into the inner workings of this amazing mathematical concept at a later date.
For example, the dimensions of the matrix below are 2 × 3 (read "two by three"), because there are two rows and three columns.
[5 7 9]
[3 2 6]
The Ayò game is a very good example of a matrix (2 × 6 matrix or 4 x 8 matrix). If you have never played Ayò game, you should try it. Don't wait before the Europeans or Americans repackage it and sell it to you!
Odù Ifá is a 16 x 16 (16 rows by 16 columns) matrix of binary numbers.
As usual, Ifá knows about mathematics and has something to say about matrix....
Èjì-Ogbè says...
Ọ̀rúnmìlà ni o di ẹlẹ́sẹ̀ mu ẹsẹ̀;
Mo ni o di ẹlẹ́sẹ̀ mu ẹsẹ̀;
O ni ogún mu ẹsẹ̀ tirẹ̀ ko bá já.
Ọ̀rúnmìlà ni o di ẹlẹ́sẹ̀ mu ẹsẹ̀;
Mo ni o di ẹlẹ́sẹ̀ mu ẹsẹ̀;
O ni ọgbọ̀n mu ẹsẹ̀ tirẹ̀ ko bá já.
Ọ̀rúnmìlà ni o di ẹlẹ́sẹ̀ mu ẹsẹ̀;
Mo ni o di ẹlẹ́sẹ̀ mu ẹsẹ̀;
Mo ni ogójì mu ẹsẹ̀ tirẹ̀ ko bá já.
Mo ni njẹ baba mi Àgbọ̀nníregùn ta ni i ba ti rẹ já?
O ni ẹẹwadọta ni kan ni o bá ẹsẹ̀ ti rẹ já.
Nitori ti a ki ka owó ka owó ki a gbàgbé ẹẹwadọta.
Ifá ni òun ko ni jẹ́ ki a gbàgbé ẹni ti o ba da Ifa yi.
Oluwarẹ si nfẹ ṣe ohun kan yio ba ẹsẹ̀ já ni ohun ti o nfẹ ṣe na yi.
Translation...
Orunmila says each should take his own row;
I say each should take his own row;
He says that Twenty Cowries takes his own row but cannot finish it.
Orunmila says each should take his own row;
I say each should take his own row;
He says that Thirty Cowries takes his own row but cannot finish it.
Orunmila says each should take his own row;
I say each should take his own row;
He says that Forty Cowries takes his own row but cannot finish it.
I say, "Well then, my father Agbonniregun, who can complete his row?"
He says Fifty Cowries alone can complete his row,
Because we cannot count money and forget Fifty Cowries.
Ifa says he will not allow the person for whom this figure was cast to be forgotten.
This person wants to do something; he will "complete his row" in the thing he wants to do.




The signature of all Odu Ifa.

The signature of all Odu Ifa.
- Credit to: Prof Adélékè Adéẹ̀kọ́




Cryptography cont.- ASCII Codes and Odu Ifa, What is the uniqueness of 256? Coincidence?

In the last few posts, we have seen how to map Odu Ifa to binary digits and from binary digits to decimal.
Since we humans mostly write in words (letters, emails, text messages etc), how do we convert these numbers to alphabetic characters?
In the early days of computing, computers could only crunch numbers. When people got fed up with just crunching numbers, they started looking for ways of representing alphabetic chraracters with numbers.
In 1960 the ASCII (American Standard Code for Information Interchange) character encoding standard was developed by the Americans to map the English alphabetic characters to numbers. The current ASCII standards map all the printable and non-printable characters on your keyboard to numbers (since computers only understand "1" and "0").
This is where it gets interesting...
The ASCII uses 256 binary digits just like Odu Ifa! Probably the Americans got their inspiration from Orunmila... Who knows?
What this mean is that every Odu Ifa sign maps to every key on your keyboard and more!
See the attached graphic for ASCII codes that map decimals to symbols.
Below are few examples (Note: Odus are read from right to left)...
(Symbol == Decimal == Binary == Odu Ifa)
Lowercase characters:
a == 97 == 01100001 == Ògúndá-Èdí
b == 98 == 01100010 == Ìrẹtẹ̀-Èdi
c == 99 == 01100011 == Ìrosùn-Èdí
d == 100 == 01100100 == Òtúra-Èdí
e == 101 == 01100101 == Ọ̀̀sẹ́-Èdí
Uppercase characters:
A == 65 == 01000001 == Ògúndá-Òtúra
B == 66 == 01000010 == Ìrẹtẹ̀-Òtúra
C == 67 == 01000011 == Ìrosùn-Òtúra
D == 68 == 01000100 == Òtúrá Méjì
E == 69 == 01000101 == Ọ̀̀sẹ́-Òtúra
Numerals:
0 == 48 == 00110000 == Ogbè-Ìrosùn
1 == 49 == 00110001 == Ògúndá-Ìrosùn
2 == 50 == 00110010 == Ìrẹtẹ̀-Ìrosùn
3 == 51 == 00110011 == Ìrosùn Méjì
4 == 52 == 00110100 == Òtúra-Ìrosùn
5 == 53 == 00110101 == Ọ̀̀sẹ́-Ìrosùn
For all the ASCII codes (decimal, octal, hexadecimal, binary and symbol) see: http://www.ascii-code.com


Cryptography - From Odu Signs to Numbers (Binary and Decimal)...

Now that we know how to generate random Odus with Ọ̀pẹ̀lẹ̀, how do we translate these Odus to numbers?
Odus are marked with “|” and “||”. Where “|” is the binary number “0” and “||” is “1”.
For example Ogbè has the following signature:
|
|
|
|
And Ọ̀̀ṣá is represented as:
| |
|
|
|
Òtúrá is marked as:
|
| |
|
|
We can therefore summarise the representation of the first sixteen Odus as follows:
Decimal == Binary == Yoruba
00 == 0000 == Ogbè
01 == 0001 == Ògúndá
02 == 0010 == Ìrẹtẹ̀
03 == 0011 == Ìrosùn
04 == 0100 == Òtúra
05 == 0101 == Ọ̀̀sẹ́
06 == 0110 == Èdí
07 == 0111 == Ọ̀̀bàrà
08 == 1000 == Ọ̀̀ṣá
09 == 1001 == Ìwòrì
10 == 1010 == Ọ̀̀fún
11 == 1011 == Ìká
12 == 1100 == Ọ̀̀wọ́nrín
13 == 1101 == Òtúrúpọ̀n
14 == 1110 == Ọ̀̀kànràn
15 == 1111 == Òyèkú
́
Since Ifá speaks only in binary (Odu Èjì Ogbè says… Èjèèji ni mo gbè, n ò gbe ọ̀kan ṣoṣo mọ́ i.e “I will only support two, I will not support one”), each Odu must be paired.
For example, after pairing the main Odus, we get the following (see graphic for the main Odus signature)…
Èjì Ogbè (also called Ògbè Méjì): 00000000
Ògúndá Méjì : 00010001
Ìrẹtẹ̀ Méjì : 00100010
Ìrosùn Méjì : 00110011
Òtúrá Méjì : 01000100
Ọ̀̀sẹ́ Méjì : 01010101
Èdí Méjì : 01100110
Ọ̀̀bàrà Méjì : 01110111
Ọ̀̀ṣá Meji: 10001000
Ìwòrì Méjì : 10011001
Ọ̀̀fún Méjì : 10101010
Ìká Méjì :10111011
Ọ̀̀wọ́nrín Méjì :11001100
Òtúrúpọ̀n Méjì :11011101
Ọ̀̀kànràn Méjì :11101110
Ọ̀yẹ̀kú Méjì : 11111111
The other 240 minor Odus are derived from the main 16 Odus.
For example (note: the binary notation and the marks are read from right to left)

Ogbè-Ògúndá : 0001-0000
|   |
|   |
|   |
||  |
Ọ̀yẹ̀kú-Ìrẹtẹ̀ : 0010-1111
|   ||
|   ||
||  ||
|   ||
Computers also speak in binary and binary numbers can be converted to decimal, hexadecimal, octal etc.
Without getting into too much maths, below are the decimal values of the 16 main Odus…
00000000 = 00
00010001 = 17
00100010 = 34
00110011 = 51
01000100 = 68
01010101 = 85
01100110 = 102
01110111 = 119
10001000 = 136
10011001 = 153
10101010 = 170
10111011 = 187
11001100 = 204
11011101 = 221
11101110 = 238
11111111 = 255
Next time we will look into matrix and how to put these numbers into use.


Cryptography - Inspiration from Odu Ifa (Ọ̀pẹ̀lẹ̀ Chain)

The cornerstone of all modern encryption systems is the generation of random numbers. If you want to encrypt any data, you must use cryptographic keys and a key is nothing but a random number that can encrypt or decrypt your data.
A strong key is a key that is very difficult to predict due to the random nature of the number chosen out of endless number series.
Believe it or not, the Ọ̀pẹ̀lẹ̀ chain (see graphic) is a random number generator. Out of the box, this ingenious device can generate 256 random Odus! These 256 Odus can be combined multiple times ad infinitum to generate pseudorandom numbers.
Ọ̀pẹ̀lẹ̀ is a simple but practical device that embodies Number Theory and Probability Theory.
Each toss of the Ọ̀pẹ̀lẹ̀ chain produces a random binary code. Mapping these binary codes to decimal and hexadecimal numbers will be explained in the next post.
Below is a quick and dirty computer code (in Javascript) that simulates the tossing of the Ọ̀pẹ̀lẹ̀ chain to generate random binary codes. You can run it in your browser by saving it on your computer (e.g as opele.html). Each time the browser is refreshed (by pressing F5 or the refresh button), a new random code is displayed.
<html>
<head>
<script language="javascript">
var odu = ["|", "||"];
for (i=0; i<4; i++) {
    var odu1 = odu[Math.floor(Math.random() * odu.length)];
    var odu2 = odu[Math.floor(Math.random() * odu.length)];
    document.write("<b>" + odu1 + "&nbsp&nbsp&nbsp&nbsp" + odu2 + "</b>" + "<br>");
}
</script>
</head>
</html>
A similar logic with the Python programming language is as follows...
import random
odu = ['|', '||']
def difa():
for x in range(4)
    print "%2s %2s" %(random.choice(odu), random.choice(odu))
if __name__ == '__main__':
    difa()