let i be Element of NAT ; :: thesis: for e1, e2 being NAT * -defined to-naturals homogeneous Function
for p being FinSequence of NAT holds dom (primrec e1,e2,i,p) c= (1 + (arity e1)) -tuples_on NAT
let e1, e2 be NAT * -defined to-naturals homogeneous Function; :: thesis: for p being FinSequence of NAT holds dom (primrec e1,e2,i,p) c= (1 + (arity e1)) -tuples_on NAT
set f1 = e1;
set f2 = e2;
let p be FinSequence of NAT ; :: thesis: dom (primrec e1,e2,i,p) c= (1 + (arity e1)) -tuples_on NAT
per cases
( i in dom p or not i in dom p )
;
suppose A1:
i in dom p
;
:: thesis: dom (primrec e1,e2,i,p) c= (1 + (arity e1)) -tuples_on NAT consider F being
Function of
NAT ,
(HFuncs NAT ) such that A2:
primrec e1,
e2,
i,
p = F . (p /. i)
and A3:
(
i in dom p &
Del p,
i in dom e1 implies
F . 0 = (p +* i,0 ) .--> (e1 . (Del p,i)) )
and A4:
( ( not
i in dom p or not
Del p,
i in dom e1 ) implies
F . 0 = {} )
and A5:
for
m being
Element of
NAT holds
S1[
m,
F . m,
F . (m + 1),
p,
i,
e2]
by Def13;
defpred S2[
Element of
NAT ]
means dom (F . $1) c= (1 + (arity e1)) -tuples_on NAT ;
A6:
S2[
0 ]
proof
per cases
( Del p,i in dom e1 or not Del p,i in dom e1 )
;
suppose A7:
Del p,
i in dom e1
;
:: thesis: S2[ 0 ]then A8:
dom (F . 0 ) = {(p +* i,0 )}
by A1, A3, FUNCOP_1:19;
dom e1 c= (arity e1) -tuples_on NAT
by Th24;
then A9:
len (Del p,i) = arity e1
by A7, FINSEQ_1:def 18;
p <> <*> NAT
by A1;
then
len p <> 0
;
then consider n being
Nat such that A10:
len p = n + 1
by NAT_1:6;
A11:
len (Del p,i) = n
by A1, A10, FINSEQ_3:118;
dom p = dom (p +* i,0 )
by FUNCT_7:32;
then
len (p +* i,0 ) = 1
+ (arity e1)
by A9, A10, A11, FINSEQ_3:31;
then
p +* i,
0 is
Element of
(1 + (arity e1)) -tuples_on NAT
by FINSEQ_2:110;
hence
S2[
0 ]
by A8, ZFMISC_1:37;
:: thesis: verum end; end;
end; A12:
now let m be
Element of
NAT ;
:: thesis: ( S2[m] implies S2[b1 + 1] )assume A13:
S2[
m]
;
:: thesis: S2[b1 + 1]set pc =
(p +* i,m) ^ <*((F . m) . (p +* i,m))*>;
per cases
( ( p +* i,m in dom (F . m) & (p +* i,m) ^ <*((F . m) . (p +* i,m))*> in dom e2 ) or not p +* i,m in dom (F . m) or not (p +* i,m) ^ <*((F . m) . (p +* i,m))*> in dom e2 )
;
suppose A14:
(
p +* i,
m in dom (F . m) &
(p +* i,m) ^ <*((F . m) . (p +* i,m))*> in dom e2 )
;
:: thesis: S2[b1 + 1]then
F . (m + 1) = (F . m) +* ((p +* i,(m + 1)) .--> (e2 . ((p +* i,m) ^ <*((F . m) . (p +* i,m))*>)))
by A1, A5;
then
dom (F . (m + 1)) = (dom (F . m)) \/ (dom ((p +* i,(m + 1)) .--> (e2 . ((p +* i,m) ^ <*((F . m) . (p +* i,m))*>))))
by FUNCT_4:def 1;
then A15:
dom (F . (m + 1)) = (dom (F . m)) \/ {(p +* i,(m + 1))}
by FUNCOP_1:19;
dom (p +* i,m) =
dom p
by FUNCT_7:32
.=
dom (p +* i,(m + 1))
by FUNCT_7:32
;
then A16:
len (p +* i,m) = len (p +* i,(m + 1))
by FINSEQ_3:31;
len (p +* i,m) = 1
+ (arity e1)
by A13, A14, FINSEQ_1:def 18;
then
p +* i,
(m + 1) is
Element of
(1 + (arity e1)) -tuples_on NAT
by A16, FINSEQ_2:110;
then
{(p +* i,(m + 1))} c= (1 + (arity e1)) -tuples_on NAT
by ZFMISC_1:37;
hence
S2[
m + 1]
by A13, A15, XBOOLE_1:8;
:: thesis: verum end; end; end;
for
m being
Element of
NAT holds
S2[
m]
from NAT_1:sch 1(A6, A12);
hence
dom (primrec e1,e2,i,p) c= (1 + (arity e1)) -tuples_on NAT
by A2;
:: thesis: verum end; end;