Template:IPAc-cmn

[[Wikipedia:IPA for Mandarin|

{{#if:{{{2|}}}|{{#switch:{{{1|}}}|-]AUD|[]AUD|-/AUD|//AUD|AUD=|{{#switch:{{{2|}}}|1|2|3|4|5=|{{#switch:{{{3}}}|1|2|3|4|5={{c-cmn|{{{2}}}|{{{3}}}}}|{{c-cmn|{{{2}}}}}}}}}}} {{#if:{{{3|}}}|{{#switch:{{{3|}}}|1|2|3|4|5=|{{#switch:{{{4}}}|1|2|3|4|5={{c-cmn|{{{3}}}|{{{4}}}}}|{{c-cmn|{{{3}}}}}}}}}}} {{#if:{{{4|}}}|{{#switch:{{{4|}}}|1|2|3|4|5=|{{#switch:{{{5}}}|1|2|3|4|5={{c-cmn|{{{4}}}|{{{5}}}}}|{{c-cmn|{{{4}}}}}}}}}}} {{#if:{{{5|}}}|{{#switch:{{{5|}}}|1|2|3|4|5=|{{#switch:{{{6}}}|1|2|3|4|5={{c-cmn|{{{5}}}|{{{6}}}}}|{{c-cmn|{{{5}}}}}}}}}}} {{#if:{{{6|}}}|{{#switch:{{{6|}}}|1|2|3|4|5=|{{#switch:{{{7}}}|1|2|3|4|5={{c-cmn|{{{6}}}|{{{7}}}}}|{{c-cmn|{{{6}}}}}}}}}}} {{#if:{{{7|}}}|{{#switch:{{{7|}}}|1|2|3|4|5=|{{#switch:{{{8}}}|1|2|3|4|5={{c-cmn|{{{7}}}|{{{8}}}}}|{{c-cmn|{{{7}}}}}}}}}}} {{#if:{{{8|}}}|{{#switch:{{{8|}}}|1|2|3|4|5=|{{#switch:{{{9}}}|1|2|3|4|5={{c-cmn|{{{8}}}|{{{9}}}}}|{{c-cmn|{{{8}}}}}}}}}}} {{#if:{{{9|}}}|{{#switch:{{{9|}}}|1|2|3|4|5=|{{#switch:{{{10}}}|1|2|3|4|5={{c-cmn|{{{9}}}|{{{10}}}}}|{{c-cmn|{{{9}}}}}}}}}}} {{#if:{{{10|}}}|{{#switch:{{{10|}}}|1|2|3|4|5=|{{#switch:{{{11}}}|1|2|3|4|5={{c-cmn|{{{10}}}|{{{11}}}}}|{{c-cmn|{{{10}}}}}}}}}}} {{#if:{{{11|}}}|{{#switch:{{{11|}}}|1|2|3|4|5=|{{#switch:{{{12}}}|1|2|3|4|5={{c-cmn|{{{11}}}|{{{12}}}}}|{{c-cmn|{{{11}}}}}}}}}}} {{#if:{{{12|}}}|{{#switch:{{{12|}}}|1|2|3|4|5=|{{#switch:{{{13}}}|1|2|3|4|5={{c-cmn|{{{12}}}|{{{13}}}}}|{{c-cmn|{{{12}}}}}}}}}}} {{#if:{{{13|}}}|{{#switch:{{{13|}}}|1|2|3|4|5=|{{#switch:{{{14}}}|1|2|3|4|5={{c-cmn|{{{13}}}|{{{14}}}}}|{{c-cmn|{{{13}}}}}}}}}}} {{#if:{{{14|}}}|{{#switch:{{{14|}}}|1|2|3|4|5=|{{#switch:{{{15}}}|1|2|3|4|5={{c-cmn|{{{14}}}|{{{15}}}}}|{{c-cmn|{{{14}}}}}}}}}}} {{#if:{{{15|}}}|{{#switch:{{{15|}}}|1|2|3|4|5=|{{#switch:{{{16}}}|1|2|3|4|5={{c-cmn|{{{15}}}|{{{16}}}}}|{{c-cmn|{{{15}}}}}}}}}}} {{#if:{{{16|}}}|{{#switch:{{{16|}}}|1|2|3|4|5=|{{#switch:{{{17}}}|1|2|3|4|5={{c-cmn|{{{16}}}|{{{17}}}}}|{{c-cmn|{{{16}}}}}}}}}}} {{#if:{{{17|}}}|{{#switch:{{{17|}}}|1|2|3|4|5=|{{#switch:{{{18}}}|1|2|3|4|5={{c-cmn|{{{17}}}|{{{18}}}}}|{{c-cmn|{{{17}}}}}}}}}}} {{#if:{{{18|}}}|{{#switch:{{{18|}}}|1|2|3|4|5=|{{#switch:{{{19}}}|1|2|3|4|5={{c-cmn|{{{18}}}|{{{19}}}}}|{{c-cmn|{{{18}}}}}}}}}}} {{#if:{{{19|}}}|{{#switch:{{{19|}}}|1|2|3|4|5=|{{#switch:{{{20}}}|1|2|3|4|5={{c-cmn|{{{19}}}|{{{20}}}}}|{{c-cmn|{{{19}}}}}}}}}}} {{#if:{{{20|}}}|{{#switch:{{{20|}}}|1|2|3|4|5=|{{#switch:{{{21}}}|1|2|3|4|5={{c-cmn|{{{20}}}|{{{21}}}}}|{{c-cmn|{{{20}}}}}}}}}}} {{#if:{{{21|}}}|{{#switch:{{{21|}}}|1|2|3|4|5=|{{#switch:{{{22}}}|1|2|3|4|5={{c-cmn|{{{21}}}|{{{22}}}}}|{{c-cmn|{{{21}}}}}}}}}}} {{#if:{{{22|}}}|{{#switch:{{{22|}}}|1|2|3|4|5=|{{#switch:{{{23}}}|1|2|3|4|5={{c-cmn|{{{22}}}|{{{23}}}}}|{{c-cmn|{{{22}}}}}}}}}}} {{#if:{{{23|}}}|{{#switch:{{{23|}}}|1|2|3|4|5=|{{#switch:{{{24}}}|1|2|3|4|5={{c-cmn|{{{23}}}|{{{24}}}}}|{{c-cmn|{{{23}}}}}}}}}}} {{#if:{{{24|}}}|{{#switch:{{{24|}}}|1|2|3|4|5=|{{#switch:{{{25}}}|1|2|3|4|5={{c-cmn|{{{24}}}|{{{25}}}}}|{{c-cmn|{{{24}}}}}}}}}}} {{#if:{{{25|}}}|{{#switch:{{{25|}}}|1|2|3|4|5=|{{#switch:{{{26}}}|1|2|3|4|5={{c-cmn|{{{25}}}|{{{26}}}}}|{{c-cmn|{{{25}}}}}}}}}}} {{#if:{{{26|}}}|{{#switch:{{{26|}}}|1|2|3|4|5=|{{#switch:{{{27}}}|1|2|3|4|5={{c-cmn|{{{26}}}|{{{27}}}}}|{{c-cmn|{{{26}}}}}}}}}}} {{#if:{{{27|}}}|{{#switch:{{{27|}}}|1|2|3|4|5=|{{#switch:{{{28}}}|1|2|3|4|5={{c-cmn|{{{27}}}|{{{28}}}}}|{{c-cmn|{{{27}}}}}}}}}}} {{#if:{{{28|}}}|{{#switch:{{{28|}}}|1|2|3|4|5=|{{#switch:{{{29}}}|1|2|3|4|5={{c-cmn|{{{28}}}|{{{29}}}}}|{{c-cmn|{{{28}}}}}}}}}}} {{#if:{{{29|}}}|{{#switch:{{{29|}}}|1|2|3|4|5=|{{#switch:{{{30}}}|1|2|3|4|5={{c-cmn|{{{29}}}|{{{30}}}}}|{{c-cmn|{{{29}}}}}}}}}}} {{#if:{{{30|}}}|{{#switch:{{{30|}}}|1|2|3|4|5=|{{#switch:{{{31}}}|1|2|3|4|5={{c-cmn|{{{30}}}|{{{31}}}}}|{{c-cmn|{{{30}}}}}}}}}}} {{#if:{{{31|}}}|{{#switch:{{{31|}}}|1|2|3|4|5=|{{#switch:{{{32}}}|1|2|3|4|5={{c-cmn|{{{31}}}|{{{32}}}}}|{{c-cmn|{{{31}}}}}}}}}}} {{#if:{{{32|}}}|{{#switch:{{{32|}}}|1|2|3|4|5=|{{#switch:{{{33}}}|1|2|3|4|5={{c-cmn|{{{32}}}|{{{33}}}}}|{{c-cmn|{{{32}}}}}}}}}}} {{#if:{{{33|}}}|{{#switch:{{{33|}}}|1|2|3|4|5=|{{#switch:{{{34}}}|1|2|3|4|5={{c-cmn|{{{33}}}|{{{34}}}}}|{{c-cmn|{{{33}}}}}}}}}}} {{#if:{{{34|}}}|{{#switch:{{{34|}}}|1|2|3|4|5=|{{#switch:{{{35}}}|1|2|3|4|5={{c-cmn|{{{34}}}|{{{35}}}}}|{{c-cmn|{{{34}}}}}}}}}}} {{#if:{{{35|}}}|{{#switch:{{{35|}}}|1|2|3|4|5=|{{#switch:{{{36}}}|1|2|3|4|5={{c-cmn|{{{35}}}|{{{36}}}}}|{{c-cmn|{{{35}}}}}}}}}}} {{#if:{{{36|}}}|{{#switch:{{{36|}}}|1|2|3|4|5=|{{#switch:{{{37}}}|1|2|3|4|5={{c-cmn|{{{36}}}|{{{37}}}}}|{{c-cmn|{{{36}}}}}}}}}}} {{#if:{{{37|}}}|{{#switch:{{{37|}}}|1|2|3|4|5=|{{#switch:{{{38}}}|1|2|3|4|5={{c-cmn|{{{37}}}|{{{38}}}}}|{{c-cmn|{{{37}}}}}}}}}}} {{#if:{{{38|}}}|{{#switch:{{{38|}}}|1|2|3|4|5=|{{#switch:{{{39}}}|1|2|3|4|5={{c-cmn|{{{38}}}|{{{39}}}}}|{{c-cmn|{{{38}}}}}}}}}}} {{#if:{{{39|}}}|{{#switch:{{{39|}}}|1|2|3|4|5=|{{#switch:{{{40}}}|1|2|3|4|5={{c-cmn|{{{39}}}|{{{40}}}}}|{{c-cmn|{{{39}}}}}}}}}}} {{#if:{{{40|}}}|{{#switch:{{{40|}}}|1|2|3|4|5=|{{#switch:{{{41}}}|1|2|3|4|5={{c-cmn|{{{40}}}|{{{41}}}}}|{{c-cmn|{{{40}}}}}}}}}}} {{#switch:{{{1}}} This template is used to produce a phonetic or phonemic representation (using the IPA system) of Mandarin Chinese words or sounds, using Pinyin input to avoid the need to search for the correct phonetic symbols. The result is wikilinked to IPA for Mandarin. Optionally, an audio file can also be specified.
 * -]
 * []
 * -]AUD
 * []AUD=]
 * \/AUD
 * //AUD=/
 * ]}}]] {{#switch:{{{1}}}
 * -]AUD|[]AUD
 * -/AUD
 * //AUD
 * AUD= ([[Image:Ltspkr.png|link=|alt=]] listen) }}
 * ]}}]] {{#switch:{{{1}}}
 * -]AUD|[]AUD
 * -/AUD
 * //AUD
 * AUD= ([[Image:Ltspkr.png|link=|alt=]] listen) }}

Usage
The number of parameters is always limited to 41.

Normal usage:
 *   produces
 *   produces

With an audio file:
 *   produces

To change the delimiters (for example, if several instances of the template need to be strung together because of the limit on the number of parameters): The full range of special values for the first parameter (changing the delimiters and/or specifying that the next parameter is an audio file) is as follows:
 *   produces
 * -- [- -] // /- -/ AUD -]AUD //AUD -/AUD

The following initials are used as in Pinyin, and represent their normal sounds in Standard Mandarin:
 * b p m f d t n l g k h j q x	zh ch sh r z c s

Each final should be entered as a whole parameter, and as if it were not preceded by an initial, though in most cases either form is acceptable:
 * yong (or iong), wa</tt> (or ua</tt>), etc.

But note that the finals with ‹ü›, despite usually being written with ‹u› in Pinyin, must use one of yu ü v</tt> here. Similarly, the true final ‹u› must be entered wu</tt>, and ‹i› as yi</tt>. The null final of shi, ri, etc. is i</tt>. Erhua is indicated simply with an ‹-r› as part of the final, e.g., angr</tt>.


 * i</tt> = ɨ
 * ai</tt> = ai̯
 * an</tt> = an
 * a</tt> = ɑ
 * ang</tt> = ɑŋ
 * ao</tt> = ɑʊ̯
 * ei</tt> = ei̯
 * en</tt> = ən
 * ê</tt> = ɛ
 * <tt>e</tt> = ɤ
 * <tt>eng</tt> = ɤŋ
 * <tt>yi</tt> = i
 * <tt>yin, in</tt> = in
 * <tt>ying, ing</tt> = iŋ
 * <tt>ya, ia</tt> = ja
 * <tt>yang, iang</tt> = jɑŋ
 * <tt>yao, iao</tt> = jɑʊ̯


 * <tt>ye, ie</tt> = jɛ
 * <tt>yan, ian</tt> = jɛn
 * <tt>you, iu</tt> = joʊ̯
 * <tt>yo, io</tt> = jɔ
 * <tt>yong, iong</tt> = jʊŋ
 * <tt>ou</tt> = oʊ̯
 * <tt>o</tt> = ɔ
 * <tt>wu</tt> = u
 * <tt>yue, üe, ve</tt> = ɥɛ
 * <tt>yuan, üan, van</tt> = ɥɛn
 * <tt>ong</tt> = ʊŋ
 * <tt>wa, ua</tt> = wa
 * <tt>wai, uai</tt> = wai̯
 * <tt>wan, uan</tt> = wan
 * <tt>wang, uang</tt> = wɑŋ
 * <tt>wei, ui</tt> = wei̯
 * <tt>wen, un</tt> = wən


 * <tt>weng, ueng</tt> = wɤŋ
 * <tt>wo, uo</tt> = wɔ
 * <tt>yu, ü, v</tt> = y
 * <tt>yun, ün, vn</tt> = yn
 * <tt>er, ar, air, anr, yir</tt> = ɑɻ
 * <tt>angr</tt> = ɑ̃ɻ
 * <tt>aor</tt> = ɑʊ̯ɻ
 * <tt>ir, eir, enr</tt> = əɻ
 * <tt>engr</tt> = ə̃ɻ
 * <tt>or, e'r</tt> = ɤɻ
 * <tt>yar, iar, yanr, ianr</tt> = jɑɻ
 * <tt>yangr, iangr</tt> = jɑ̃ɻ
 * <tt>yaor, iaor</tt> = jɑʊ̯ɻ
 * <tt>yinr, inr</tt> = jəɻ
 * <tt>yer, ier</tt> = jɛɻ
 * <tt>yingr, ingr</tt> = jɤ̃ɻ


 * <tt>your, iur</tt> = joʊ̯ɻ
 * <tt>yor, ior</tt> = jɔɻ
 * <tt>yongr, iongr</tt> = jʊ̃ɻ
 * <tt>our</tt> = oʊ̯ɻ
 * <tt>yuanr, üanr, vanr</tt> = ɥɑɻ
 * <tt>yur, ür, vr, yunr, ünr, vnr</tt> = ɥəɻ
 * <tt>yuer, üer, ver</tt> = ɥɛɻ
 * <tt>ongr, weng, uengr</tt> = ʊ̃ɻ
 * <tt>war, uar, wair, uair, wanr, uanr</tt> = wɑɻ
 * <tt>wangr, uangr</tt> = wɑ̃ɻ
 * <tt>weir, uir, wenr, unr</tt> = wəɻ
 * <tt>wor, uor, wur, wor, uor</tt> = wɔɻ
 * <tt>M</tt> = m̩
 * <tt>N</tt> = n̩
 * <tt>NG</tt> = ŋ̩

The tones are indicated by their traditional tone number, entered as the parameter after the final:
 * <tt>1 2 3 4 5</tt>

The unaspirated plosive/affricate consonants may be capitalized to represent their voicing in toneless (tone 5) syllables:
 * <tt>B D G J ZH Z</tt>

The following parameters have special meanings:
 * <tt>-</tt> (hyphen) for a space between words
 * <tt>.</tt> (period) for a syllable break
 * <tt>'</tt> (apostrophe) for a primary stress mark (placed before the stressed syllable)
 * <tt>,</tt> (comma) for a secondary stress mark (placed before the stressed syllable)

Other values used as parameters will be displayed unconverted. (The conversion system is coded in Template:c-cmn. The tones are encoded in Template:tone-cmn)