X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fbasic_1A%2Ftlt%2Fdefs.ma;fp=matita%2Fmatita%2Fcontribs%2Flambdadelta%2Fbasic_1A%2Ftlt%2Fdefs.ma;h=d40e8fd36053e593052f31b8684d2b24ad9ac2be;hb=d2545ffd201b1aa49887313791386add78fa8603;hp=0000000000000000000000000000000000000000;hpb=57ae1762497a5f3ea75740e2908e04adb8642cc2;p=helm.git diff --git a/matita/matita/contribs/lambdadelta/basic_1A/tlt/defs.ma b/matita/matita/contribs/lambdadelta/basic_1A/tlt/defs.ma new file mode 100644 index 000000000..d40e8fd36 --- /dev/null +++ b/matita/matita/contribs/lambdadelta/basic_1A/tlt/defs.ma @@ -0,0 +1,43 @@ +(**************************************************************************) +(* ___ *) +(* ||M|| *) +(* ||A|| A project by Andrea Asperti *) +(* ||T|| *) +(* ||I|| Developers: *) +(* ||T|| The HELM team. *) +(* ||A|| http://helm.cs.unibo.it *) +(* \ / *) +(* \ / This file is distributed under the terms of the *) +(* v GNU General Public License Version 2 *) +(* *) +(**************************************************************************) + +(* This file was automatically generated: do not edit *********************) + +include "basic_1A/T/defs.ma". + +definition wadd: + ((nat \to nat)) \to (nat \to (nat \to nat)) +\def + \lambda (f: ((nat \to nat))).(\lambda (w: nat).(\lambda (n: nat).(match n +with [O \Rightarrow w | (S m) \Rightarrow (f m)]))). + +rec definition weight_map (f: (nat \to nat)) (t: T) on t: nat \def match t +with [(TSort _) \Rightarrow O | (TLRef n) \Rightarrow (f n) | (THead k u t0) +\Rightarrow (match k with [(Bind b) \Rightarrow (match b with [Abbr +\Rightarrow (S (plus (weight_map f u) (weight_map (wadd f (S (weight_map f +u))) t0))) | Abst \Rightarrow (S (plus (weight_map f u) (weight_map (wadd f +O) t0))) | Void \Rightarrow (S (plus (weight_map f u) (weight_map (wadd f O) +t0)))]) | (Flat _) \Rightarrow (S (plus (weight_map f u) (weight_map f +t0)))])]. + +definition weight: + T \to nat +\def + weight_map (\lambda (_: nat).O). + +definition tlt: + T \to (T \to Prop) +\def + \lambda (t1: T).(\lambda (t2: T).(lt (weight t1) (weight t2))). +