1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 (* Initial invocation: - Patience on us to gain peace and perfection! - *)
17 include "preamble.ma".
19 (* TERM STRUCTURE ***********************************************************)
21 (* Policy: term metavariables: A, B, C, D, M, N
22 de Bruijn indexes : i, j
24 inductive term: Type[0] ≝
25 | VRef: nat → term (* variable reference by index *)
26 | Abst: term → term (* function formation *)
27 | Appl: term → term → term (* function application *)
30 interpretation "term construction (variable reference by index)"
31 'VariableReferenceByIndex i = (VRef i).
33 interpretation "term construction (abstraction)"
34 'Abstraction A = (Abst A).
36 interpretation "term construction (application)"
37 'Application C A = (Appl C A).
39 notation "hvbox( # term 90 i )"
40 non associative with precedence 55
41 for @{ 'VariableReferenceByIndex $i }.
43 notation "hvbox( 𝛌 . term 55 A )"
44 non associative with precedence 55
45 for @{ 'Abstraction $A }.
47 notation > "hvbox( 𝛌 term 55 A )"
48 non associative with precedence 55
49 for @{ 'Abstraction $A }.
51 notation "hvbox( @ term 55 C . break term 55 A )"
52 non associative with precedence 55
53 for @{ 'Application $C $A }.