1# © 2016 and later: Unicode, Inc. and others. 2# License & terms of use: http://www.unicode.org/copyright.html#License 3# 4# File: cy_cy_FONIPA.txt 5# Generated from CLDR 6# 7 8# Transformation from Welsh (cy) to its IPA transcription (cy_FONIPA). 9# Based on description of Northern Welsh in: 10# 11# http://en.wikipedia.org/wiki/Welsh_orthography 12# http://en.wikipedia.org/wiki/Welsh_phonology 13# 14# Note that these rules are NOT complete: to be complete we would have to know 15# the morphological analysis of the word. For example, final ‹au› is pronounced 16# /a/ if it is the noun plural marker, otherwise it is /aɨ/. Similarly in 17# “llongyfarch” (‘congratulating’), the morphological decomposition — “llon + 18# cyfarch” — is needed to know that the ‹ng› is pronounced as /ŋg/, not as 19# /ŋ/. 20# 21# Author: Richard Sproat 22::Lower; 23::NFC; 24[’ [:P:]] → ; 25# Class definitions 26$end = [$ ]; 27# Both orthographic and phonetic vowels 28$vowel = [aeiouwyâêîôûŵŷɑɨəɛɪɔʊ]; 29# W is a placeholder for the glide -- see below 30$cons = [ 31m {m\u0325} n {n\u0325} ŋ {ŋ\u030A} 32p b t d k ɡ 33f v θ ð s ʃ h χ 34l ɬ r {r\u0325} 35{d\u0361ʒ} g W w j 36]; 37# Preprocessing of letters that sometimes occur 38k → c; 39v → f; 40x → s; 41z → s; 42::Null; 43# Consonant transductions: 44# Trigraphs 45ngh → ŋ\u030A; 46# Digraphs 47ch → χ; 48dd → ð; 49ff → f; 50ll → ɬ; 51mh → m\u0325; 52nh → n\u0325; 53ng → ŋ; 54ph → f; 55rh → r\u0325; 56th → θ; 57# Monographs 58b → b; 59c → k; 60d → d; 61f → v; 62g → ɡ; 63h → h; 64j → d\u0361ʒ; # Loan words 65l → l; 66m → m; 67n → n; 68p → p; 69r → r; 70s → s; 71t → t; 72::Null; 73# Transduce ‹si› to /ʃ/ before vowels 74si} $vowel → ʃ; 75::Null; 76# Treatment of glides. 77# First transduce ‹i›, ‹w› to glides prior to vowels. With ‹w› we want to 78# do this also before /r,l/ after /ɡ/ (from Proto-Celtic *w) e.g. “gwlad”, 79# “gwraig”. However the “after g” environment must allow for the following 80# possibilities: 81# 82# ɡ → ŋ via nasal mutation 83# ɡ → 0 via soft mutation 84{i} $vowel → j; 85{w} $vowel → W; # Temporary register 86[ɡŋ] {w} [rl] $vowel → W; # Plain or nasal mutation environment 87^ {w} [rl] $vowel → W; # Soft mutation at the beginning of a word 88# Transduce accented ‹ẃ› to ‹w›: this is used to indicate when a ‹w› that would 89# normally be expected to be a glide, is instead a vowel: 90ẃ → w; 91::Null; 92# Stress placement, needed for vowel quality/quantity prediction 93# Basic rule of stress in Welsh is to place it on the penult, 94# except of course in monosyllables. 95{($vowel+ $cons+ $vowel+ $cons*)} $end → ˈ $1; ## Polysyllabic words 96$end $cons* {($vowel+ $cons*)} $end → ˈ $1; ## Monosyllabic words 97::Null; 98# Transduction of vowels 99# The first rule above overgenerates streams of stress marks. The rule below 100# cleans that up. 101ˈ+ → ˈ; 102# Diphthongs 103# Deal with ‹y› first since we also need to lengthen the /ɨ/ if that is in the 104# correct environment for lengthening. 105# ‹y› is /ɨ/ in final syllable, otherwise /ə/ 106yw } $cons* $end → ɨu; 107yw → əu; 108y} $cons* $end → ɨ; 109y → ə; 110::Null; 111# Diphthongs in long environment 112# Final, or before word-final s 113ˈ { ɨu } s? $end → ɨːu; 114ˈ { aw } s? $end → ɑːu; 115ˈ { ew } s? $end → eːu; 116ˈ { oe } s? $end → ɔːɨ; 117ˈ { ou } s? $end → ɔːɨ; 118ˈ { wy } s? $end → uːɨ; 119# before b, ch, d, dd, g, f, ff, th followed by the end of a word 120# or a vowel 121ˈ { ɨu } [bχdðɡvfθ] $end → ɨːu; 122ˈ { aw } [bχdðɡvfθ] $end → ɑːu; 123ˈ { ew } [bχdðɡvfθ] $end → eːu; 124ˈ { oe } [bχdðɡvfθ] $end → ɔːɨ; 125ˈ { ou } [bχdðɡvfθ] $end → ɔːɨ; 126ˈ { wy } [bχdðɡvfθ] $end → uːɨ; 127ˈ { ɨu } [bχdðɡvfθ] $vowel → ɨːu; 128ˈ { aw } [bχdðɡvfθ] $vowel → ɑːu; 129ˈ { ew } [bχdðɡvfθ] $vowel → eːu; 130ˈ { oe } [bχdðɡvfθ] $vowel → ɔːɨ; 131ˈ { ou } [bχdðɡvfθ] $vowel → ɔːɨ; 132ˈ { wy } [bχdðɡvfθ] $vowel → uːɨ; 133# Diphthongs in other environments 134ae → ɑːɨ; 135ai → ai; 136au → aɨ; ## As plural ending /a/, but we can't predict this 137aw → au; 138ei → əi; 139eu → əɨ; 140ew → ɛu; 141ey → əɨ; 142iw → ɪu; 143oe → ɔɨ; 144oi → ɔi; 145ou → ɔɨ; 146uw → ɨu; 147wy → ʊɨ; 148# Long environments 149# Final, or before word-final s 150ˈ { ɨ } s? $end → ɨː; 151ˈ { a } s? $end → ɑː; 152ˈ { e } s? $end → eː; 153ˈ { i } s? $end → iː; 154ˈ { o } s? $end → oː; 155ˈ { u } s? $end → ɨː; 156ˈ { w } s? $end → uː; 157# before b, ch, d, dd, g, f, ff, th followed by the end of a word 158# or a vowel 159ˈ { ɨ } [bχdðɡvfθ] $end → ɨː; 160ˈ { a } [bχdðɡvfθ] $end → ɑː; 161ˈ { e } [bχdðɡvfθ] $end → eː; 162ˈ { i } [bχdðɡvfθ] $end → iː; 163ˈ { o } [bχdðɡvfθ] $end → oː; 164ˈ { u } [bχdðɡvfθ] $end → ɨː; 165ˈ { w } [bχdðɡvfθ] $end → uː; 166ˈ { ɨ } [bχdðɡvfθ] $vowel → ɨː; 167ˈ { a } [bχdðɡvfθ] $vowel → ɑː; 168ˈ { e } [bχdðɡvfθ] $vowel → eː; 169ˈ { i } [bχdðɡvfθ] $vowel → iː; 170ˈ { o } [bχdðɡvfθ] $vowel → oː; 171ˈ { u } [bχdðɡvfθ] $vowel → ɨː; 172ˈ { w } [bχdðɡvfθ] $vowel → uː; 173# Short environments 174a → a; 175e → ɛ; 176i → ɪ; 177o → ɔ; 178u → ɨ\u031E; 179w → ʊ; 180::Null; 181W → w; 182# Finally, deal with vowels that are marked as long with a circumflex 183# (“to bach”). Do this last because we don't want the other vowel 184# changes messing this up. 185â → ɑː; 186ê → eː; 187î → iː; 188ô → oː; 189û → ɨː; 190ŵ → uː; 191ŷ → ɨː; 192::Null; 193# Move IPA stress marker to start of syllable. 194([$cons w] [l ɬ r {r\u0325}]? j? w?) ˈ → ˈ $1; 195 196