X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=matita%2Fmatita%2Flib%2Flambda-delta%2Fsyntax%2Flength.ma;fp=matita%2Fmatita%2Flib%2Flambda-delta%2Fsyntax%2Flength.ma;h=91e1bd78c01aa5d8274920530a81698acbe153f9;hb=baccd5a2f3b79c295b1f9444575bfb351577634e;hp=0000000000000000000000000000000000000000;hpb=1cd2f9aa6e0aee9eb4939b39c985b6ad6605092b;p=helm.git diff --git a/matita/matita/lib/lambda-delta/syntax/length.ma b/matita/matita/lib/lambda-delta/syntax/length.ma new file mode 100644 index 000000000..91e1bd78c --- /dev/null +++ b/matita/matita/lib/lambda-delta/syntax/length.ma @@ -0,0 +1,22 @@ +(* + ||M|| This file is part of HELM, an Hypertextual, Electronic + ||A|| Library of Mathematics, developed at the Computer Science + ||T|| Department of the University of Bologna, Italy. + ||I|| + ||T|| + ||A|| This file is distributed under the terms of the + \ / GNU General Public License Version 2 + \ / + V_______________________________________________________________ *) + +include "lambda-delta/syntax/lenv.ma". + +(* LENGTH *******************************************************************) + +(* the length of a local environment *) +let rec length L ≝ match L with +[ LSort ⇒ 0 +| LPair L _ _ ⇒ length L + 1 +]. + +interpretation "length (local environment)" 'card L = (length L).