File: INST_UPPERCASE.doc

package info (click to toggle)
hol-light 20131026-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 26,264 kB
  • ctags: 4,620
  • sloc: ml: 400,325; cpp: 438; java: 279; lisp: 261; makefile: 256; sh: 190; yacc: 108; perl: 78; ansic: 57; sed: 39
file content (54 lines) | stat: -rw-r--r-- 1,623 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
\DOC INST

\TYPE {INST : (term * term) list -> thm -> thm}

\SYNOPSIS
Instantiates free variables in a theorem.

\DESCRIBE
When {INST [t1,x1; ...; tn,xn]} is applied to a theorem, it gives a new
theorem that systematically replaces free instances of each variable {xi} with
the corresponding term {ti} in both assumptions and conclusion.
{
               A |- t
   -----------------------------------  INST_TYPE [t1,x1;...;tn,xn]
    A[t1,...,tn/x1,...,xn]
        |- t[t1,...,tn/x1,...,xn]
}
Bound variables will be renamed if necessary to avoid capture. All variables 
are substituted in parallel, so there is no problem if there is an overlap 
between the terms {ti} and {xi}.

\FAILURE
Fails if any of the pairs {ti,xi} in the instantiation list has {xi} and {ti}
with different types, or {xi} a non-variable. Multiple instances of the same
{xi} in the list are not trapped, but only the first one will be used
consistently.

\EXAMPLE
Here is a simple example
{
  # let th = SPEC_ALL ADD_SYM;;
  val th : thm = |- m + n = n + m
  # INST [`1`,`m:num`; `x:num`,`n:num`] th;;
  val it : thm = |- 1 + x = x + 1
}
\noindent and here is one where bound variable renaming is needed.
{
  # let th = SPEC_ALL LE_EXISTS;;
  val th : thm = |- m <= n <=> (?d. n = m + d)
  # INST [`d:num`,`m:num`] th;;
  val it : thm = |- d <= n <=> (?d'. n = d + d')
}

\USES
This is the most efficient way to obtain instances of a theorem; though
sometimes more convenient, {SPEC} and {SPECL} are significantly slower.

\COMMENTS
This is one of HOL Light's 10 primitive inference rules.

\SEEALSO
INST_TYPE, ISPEC, ISPECL, SPEC, SPECL.

\ENDDOC