let n, i be Element of NAT ; ( i < n implies ( (n -BinarySequence (2 to_power i)) . (i + 1) = 1 & ( for j being Element of NAT st j in Seg n & j <> i + 1 holds
(n -BinarySequence (2 to_power i)) . j = 0 ) ) )
assume A1:
i < n
; ( (n -BinarySequence (2 to_power i)) . (i + 1) = 1 & ( for j being Element of NAT st j in Seg n & j <> i + 1 holds
(n -BinarySequence (2 to_power i)) . j = 0 ) )
deffunc H1( Nat) -> FinSequence of BOOLEAN = $1 -BinarySequence (2 to_power i);
set B = n -BinarySequence (2 to_power i);
defpred S1[ Nat] means ( i < $1 implies H1($1) . (i + 1) = TRUE );
A2:
now for n being Nat st S1[n] holds
S1[n + 1]let n be
Nat;
( S1[n] implies S1[n + 1] )assume A3:
S1[
n]
;
S1[n + 1]hence
S1[
n + 1]
;
verum end;
A17:
S1[ 0 ]
;
for n being Nat holds S1[n]
from NAT_1:sch 2(A17, A2);
hence
(n -BinarySequence (2 to_power i)) . (i + 1) = 1
by A1; for j being Element of NAT st j in Seg n & j <> i + 1 holds
(n -BinarySequence (2 to_power i)) . j = 0
defpred S2[ Nat] means ( i < $1 implies for j being Element of NAT st i + 1 <= j & j <= $1 holds
H1($1) . (j + 1) = FALSE );
let j be Element of NAT ; ( j in Seg n & j <> i + 1 implies (n -BinarySequence (2 to_power i)) . j = 0 )
assume that
A18:
j in Seg n
and
A19:
j <> i + 1
; (n -BinarySequence (2 to_power i)) . j = 0
A20:
1 <= j
by A18, FINSEQ_1:1;
A21:
now for n being Nat st S2[n] holds
S2[n + 1]let n be
Nat;
( S2[n] implies S2[n + 1] )assume A22:
S2[
n]
;
S2[n + 1]hence
S2[
n + 1]
;
verum end;
A41:
S2[ 0 ]
;
A42:
for n being Nat holds S2[n]
from NAT_1:sch 2(A41, A21);
defpred S3[ Nat] means ( i < $1 implies for j being Element of NAT st 1 <= j & j < i + 1 holds
H1($1) . j = FALSE );
A43:
now for n being Nat st S3[n] holds
S3[n + 1]let n be
Nat;
( S3[n] implies S3[n + 1] )assume A44:
S3[
n]
;
S3[n + 1]now ( i < n + 1 implies for j being Element of NAT st 1 <= j & j < i + 1 holds
H1(n + 1) . j = FALSE )assume A45:
i < n + 1
;
for j being Element of NAT st 1 <= j & j < i + 1 holds
H1(n + 1) . b2 = FALSE then A46:
i <= n
by NAT_1:13;
let j be
Element of
NAT ;
( 1 <= j & j < i + 1 implies H1(n + 1) . b1 = FALSE )assume that A47:
1
<= j
and A48:
j < i + 1
;
H1(n + 1) . b1 = FALSE per cases
( n = 0 or ( n > 0 & i < n ) or ( n > 0 & i = n ) )
by A46, XXREAL_0:1;
suppose A49:
(
n > 0 &
i < n )
;
H1(n + 1) . b1 = FALSE then reconsider n9 =
n as non
zero Nat ;
A50:
dom H1(
n)
= Seg n
by Lm1;
A51:
i <= n
by A45, NAT_1:13;
j <= i
by A48, NAT_1:13;
then
j <= n
by A51, XXREAL_0:2;
then A52:
j in dom H1(
n)
by A47, A50, FINSEQ_1:1;
2
to_power i < 2
to_power n
by A49, POWER:39;
hence H1(
n + 1)
. j =
(H1(n9) ^ <*FALSE*>) . j
by BINARI_3:27
.=
H1(
n)
. j
by A52, FINSEQ_1:def 7
.=
FALSE
by A44, A47, A48, A49
;
verum end; end; end; hence
S3[
n + 1]
;
verum end;
A57:
S3[ 0 ]
;
A58:
for n being Nat holds S3[n]
from NAT_1:sch 2(A57, A43);
A59:
j <= n
by A18, FINSEQ_1:1;