Monday, April 8, 2013

chinese character stroke count

I was organizing all the databases for my "I love cantonese" website. I am proud. I have done a lot to allow users inputing chinese using cantonese syllables.

There are 5 databases that I have created. The first one is the cantonese database which is based on the syllable to choose the chinese character having the same consonant, vowel and tone. It was original in files but I exported the data to the database to allow searching relatively faster and maintaining easier. The second database is based on the first one which allows user to search the syllable of a given character, kind of the reverse process of the first one. Using syllable to look for character and oppositely using character to look for its syllable and allow user to see some characters have mulitple syllables.

The third one is for looking up the meaning of each character and I called it the context database. The fourth one is the dictionary database which I use CEDICT and add and modify it as needed. The last one is the radical database which collect characters under each radical and there are only 214 radicals. The problem is that some radicals have over hundreds characters which make it hard to search for one desired and this is the problem leading me to find the character stroke count as most people further classify characters using the number of stroke count. However there are tens of thousands of the characters which is intimidating to input the number of strokes character by character. Luckily I found on internet a way to do it.

There is a file in unicode to tell me the number of stroke count and I used it, it work beautifully and I will integrate this later to help the search. Please stay tuned.

Thursday, January 31, 2013

三六九

終於完成三六九的網上遊戲,細時很喜歡玩,相信小朋友會喜歡。三六九遊戲可以鍛練腦筋。
連結: http://pcwong.org/game369.html

Thursday, December 20, 2012

Mandarin Chinese Input

These days I was working on tranlating the system in Cantonese Chinese Input to Mandarin Chinese Input. The first step is to identify the consonants and vowels. There are very many different versions and after researching on the topic, I find these facts are most correct:
21 consonants plus 1 zero consonant meaning that the vowels are pronounced as they are:
‘b’, ‘p’, ‘m’, ‘f’, ‘d’, ‘t’, ‘n’, ‘l’, ‘g’, ‘k’, ‘h’, ‘z’, ‘c’, ‘s’, ‘zh’, ‘ch’, ‘sh’, ‘r’, ‘j’, ‘q’, ‘x’ and ‘x’ is not considered as no consonant. ‘-’ can be used. ‘x’ is like ‘s’ but in mandarin, they are different in terms of emphasis, light/heavy s.
There are 38 vowels and in many versions, only 35 vowels as several vowels do not have their consonant part. The following is a scanned copy of Mr. Wong or Mr. Huang if pronounced in Mandarin:
List of Mandarin Vowels 
List of Mandarin Vowels
I organised the syllable table with the consonants and vowels with the single vowels addition as follows:
Mandarin Pinyin Syllable Table
Figure My mandarin Pinyin Syllable Table
I have verified with other versions:
One Pinyin Chart
One Pinyin Chart
Another Pinyin Chart
Another Pinyin Chart
More Pinyin Syllable Table
More Pinyin Syllable Table
Some versions add consonants ‘y’ and ‘w’ but the original scheme is to add ‘y’ and ‘w’ to the no consonant vowels like ‘u’ for ‘wu’ and ‘ü’ for ‘yu’ or even ‘ia’ as ‘ya’. Changing the syllable table makes pinyin more confusing.
Not all combinations are valid syllables and invalid ones are now excluded. Some version do a count to say the total is 412, some says 409 and I got 420 but some syllables do not have characters but maybe I have not found characters under those syllables, they are ‘lo’, ‘shong’, ‘rua’, ‘ruang’,’ nun’, ‘nia’, ‘lün’, ‘diang’, ‘ê’ for ‘e’, and ‘kei’. Some use ‘m’ and ‘n’ as vowels and will come to 420-10+2=412 as well. But with ‘ong’ being ‘weng’, there will only be 411. I am not sure about the 412 total for some version meant those syllables I listed. Please let me know for those who is knowledgeable in the area.
Please test drive my design at:
http://pcwong.org/mandarin/
and http://pcwong.org/mandarin/pinyin.html for pinyin input.
Have fun!