diff options
| author | aarne <aarne@cs.chalmers.se> | 2008-09-16 08:01:47 +0000 |
|---|---|---|
| committer | aarne <aarne@cs.chalmers.se> | 2008-09-16 08:01:47 +0000 |
| commit | c09783e60443d5443e9a1d1609b08c31da5f9d91 (patch) | |
| tree | 27d6f513dae149877bc7418fbe3fc0131a95bef5 /examples | |
| parent | e112fd188f905d90b727101fdbfa21478f4c9d18 (diff) | |
restored the summer school and Resource-HOWTO documents
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/jem-math/LexMath.gf | 16 | ||||
| -rw-r--r-- | examples/jem-math/LexMathFre.gf | 18 | ||||
| -rw-r--r-- | examples/jem-math/LexMathSwe.gf | 18 | ||||
| -rw-r--r-- | examples/jem-math/MathFre.gf | 8 | ||||
| -rw-r--r-- | examples/jem-math/MathI.gf | 51 | ||||
| -rw-r--r-- | examples/jem-math/MathSwe.gf | 8 |
6 files changed, 119 insertions, 0 deletions
diff --git a/examples/jem-math/LexMath.gf b/examples/jem-math/LexMath.gf new file mode 100644 index 000000000..f6f22bb46 --- /dev/null +++ b/examples/jem-math/LexMath.gf @@ -0,0 +1,16 @@ +interface LexMath = open Syntax in { + +oper + zero_PN : PN ; + successor_N2 : N2 ; + sum_N2 : N2 ; + product_N2 : N2 ; + even_A : A ; + odd_A : A ; + prime_A : A ; + equal_A2 : A2 ; + small_A : A ; + great_A : A ; + divisible_A2 : A2 ; + number_N : N ; +} diff --git a/examples/jem-math/LexMathFre.gf b/examples/jem-math/LexMathFre.gf new file mode 100644 index 000000000..fefacda1e --- /dev/null +++ b/examples/jem-math/LexMathFre.gf @@ -0,0 +1,18 @@ +instance LexMathFre of LexMath = + open SyntaxFre, ParadigmsFre, (L = LexiconFre) in { + +oper + zero_PN = mkPN "zéro" ; + successor_N2 = mkN2 (mkN "successeur") genitive ; + sum_N2 = mkN2 (mkN "somme") genitive ; + product_N2 = mkN2 (mkN "produit") genitive ; + even_A = mkA "pair" ; + odd_A = mkA "impair" ; + prime_A = mkA "premier" ; + equal_A2 = mkA2 (mkA "égal") dative ; + small_A = L.small_A ; + great_A = L.big_A ; + divisible_A2 = mkA2 (mkA "divisible") (mkPrep "par") ; + number_N = mkN "entier" ; + +} diff --git a/examples/jem-math/LexMathSwe.gf b/examples/jem-math/LexMathSwe.gf new file mode 100644 index 000000000..1c5d7d802 --- /dev/null +++ b/examples/jem-math/LexMathSwe.gf @@ -0,0 +1,18 @@ +instance LexMathSwe of LexMath = + open SyntaxSwe, ParadigmsSwe, (L = LexiconSwe) in { + +oper + zero_PN = mkPN "noll" neutrum ; + successor_N2 = mkN2 (mkN "efterföljare" "efterföljare") (mkPrep "till") ; + sum_N2 = mkN2 (mkN "summa") (mkPrep "av") ; + product_N2 = mkN2 (mkN "produkt" "produkter") (mkPrep "av") ; + even_A = mkA "jämn" ; + odd_A = mkA "udda" "udda" ; + prime_A = mkA "prim" ; + equal_A2 = mkA2 (mkA "lika" "lika") (mkPrep "med") ; + small_A = L.small_A ; + great_A = L.big_A ; + divisible_A2 = mkA2 (mkA "delbar") (mkPrep "med") ; + number_N = mkN "tal" "tal" ; + +} diff --git a/examples/jem-math/MathFre.gf b/examples/jem-math/MathFre.gf new file mode 100644 index 000000000..3804142dc --- /dev/null +++ b/examples/jem-math/MathFre.gf @@ -0,0 +1,8 @@ +--# -path=.:present + +concrete MathFre of Math = MathI with + (Syntax = SyntaxFre), + (Mathematical = MathematicalFre), + (LexMath = LexMathFre) ; + + diff --git a/examples/jem-math/MathI.gf b/examples/jem-math/MathI.gf new file mode 100644 index 000000000..848b583aa --- /dev/null +++ b/examples/jem-math/MathI.gf @@ -0,0 +1,51 @@ +incomplete concrete MathI of Math = open + Syntax, + Mathematical, + LexMath, + Prelude in { + +lincat + Prop = S ; + Exp = NP ; + +lin + And = mkS and_Conj ; + Or = mkS or_Conj ; + If a = mkS (mkAdv if_Subj a) ; + + Zero = mkNP zero_PN ; + Successor = funct1 successor_N2 ; + + Sum = funct2 sum_N2 ; + Product = funct2 product_N2 ; + + Even = pred1 even_A ; + Odd = pred1 odd_A ; + Prime = pred1 prime_A ; + + Equal = pred2 equal_A2 ; + Less = predC small_A ; + Greater = predC great_A ; + Divisible = pred2 divisible_A2 ; + +oper + funct1 : N2 -> NP -> NP = \f,x -> mkNP the_Art (mkCN f x) ; + funct2 : N2 -> NP -> NP -> NP = \f,x,y -> mkNP the_Art (mkCN f (mkNP and_Conj x y)) ; + + pred1 : A -> NP -> S = \f,x -> mkS (mkCl x f) ; + pred2 : A2 -> NP -> NP -> S = \f,x,y -> mkS (mkCl x f y) ; + predC : A -> NP -> NP -> S = \f,x,y -> mkS (mkCl x f y) ; + +lincat + Var = Symb ; +lin + X = MkSymb (ss "x") ; + Y = MkSymb (ss "y") ; + + EVar x = mkNP (SymbPN x) ; + EInt i = mkNP (IntPN i) ; + + ANumberVar x = mkNP a_Art (mkCN (mkCN number_N) (mkNP (SymbPN x))) ; + TheNumberVar x = mkNP the_Art (mkCN (mkCN number_N) (mkNP (SymbPN x))) ; + +} diff --git a/examples/jem-math/MathSwe.gf b/examples/jem-math/MathSwe.gf new file mode 100644 index 000000000..1011a8985 --- /dev/null +++ b/examples/jem-math/MathSwe.gf @@ -0,0 +1,8 @@ +--# -path=.:present + +concrete MathSwe of Math = MathI with + (Syntax = SyntaxSwe), + (Mathematical = MathematicalSwe), + (LexMath = LexMathSwe) ; + + |
