SUBST_CONV : {redex :term, residue :thm} list -> term -> conv
A1 |- t1 = v1 ... An |- tn = vn
------------------------------------------------------------------
A1 u ... u An |- t[t1,...,tn/x1,...,xn] = t[v1,...,vn/x1,...,xn]
SUBST_CONV [{redex = x1, residue = A1|-t1=v1},...,
{redex = xn, residue = An|-tn=vn}]
t[x1,...,xn]
t[t1,...,tn/x1,...,xn]
A1 u ... u An |- t[t1,...,tn/x1,...,xn] = t[v1,...,vn/x1,...,xn]
The occurrence of ti at the places marked by the variable xi must be free (i.e. ti must not contain any bound variables). SUBST_CONV automatically renames bound variables to prevent free variables in vi becoming bound after substitution.
- val thm0 = SPEC (Term`0`) ADD1
and thm1 = SPEC (Term`1`) ADD1
and x = Term`x:num` and y = Term`y:num`;
> val thm0 = |- SUC 0 = 0 + 1 : thm
val thm1 = |- SUC 1 = 1 + 1 : thm
val x = `x` : term
val y = `y` : term
- SUBST_CONV [{redex=x, residue=thm0},{redex=y,residue=thm1}]
(Term`(x + y) > SUC 1`)
(Term`(SUC 0 + SUC 1) > SUC 1`);
> val it = |- SUC 0 + SUC 1 > SUC 1 = (0 + 1) + 1 + 1 > SUC 1 : thm
- SUBST_CONV [x |-> thm0, y |-> thm1]
(Term`(x + y) > SUC 1`)
(Term`(SUC 0 + SUC 1) > SUC 1`);