MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  sadeq Unicode version

Theorem sadeq 12663
Description: Any element of a sequence sum only depends on the values of the argument sequences up to and including that point. (Contributed by Mario Carneiro, 9-Sep-2016.)
Hypotheses
Ref Expression
sadeq.a  |-  ( ph  ->  A  C_  NN0 )
sadeq.b  |-  ( ph  ->  B  C_  NN0 )
sadeq.n  |-  ( ph  ->  N  e.  NN0 )
Assertion
Ref Expression
sadeq  |-  ( ph  ->  ( ( A sadd  B
)  i^i  ( 0..^ N ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )

Proof of Theorem sadeq
Dummy variables  m  c  n are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 inass 3379 . . . . . . . 8  |-  ( ( A  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) )  =  ( A  i^i  ( ( 0..^ N )  i^i  (
0..^ N ) ) )
2 inidm 3378 . . . . . . . . 9  |-  ( ( 0..^ N )  i^i  ( 0..^ N ) )  =  ( 0..^ N )
32ineq2i 3367 . . . . . . . 8  |-  ( A  i^i  ( ( 0..^ N )  i^i  (
0..^ N ) ) )  =  ( A  i^i  ( 0..^ N ) )
41, 3eqtri 2303 . . . . . . 7  |-  ( ( A  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) )  =  ( A  i^i  ( 0..^ N ) )
54fveq2i 5528 . . . . . 6  |-  ( `' (bits  |`  NN0 ) `  ( ( A  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) )  =  ( `' (bits  |`  NN0 ) `  ( A  i^i  (
0..^ N ) ) )
6 inass 3379 . . . . . . . 8  |-  ( ( B  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) )  =  ( B  i^i  ( ( 0..^ N )  i^i  (
0..^ N ) ) )
72ineq2i 3367 . . . . . . . 8  |-  ( B  i^i  ( ( 0..^ N )  i^i  (
0..^ N ) ) )  =  ( B  i^i  ( 0..^ N ) )
86, 7eqtri 2303 . . . . . . 7  |-  ( ( B  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) )  =  ( B  i^i  ( 0..^ N ) )
98fveq2i 5528 . . . . . 6  |-  ( `' (bits  |`  NN0 ) `  ( ( B  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) )  =  ( `' (bits  |`  NN0 ) `  ( B  i^i  (
0..^ N ) ) )
105, 9oveq12i 5870 . . . . 5  |-  ( ( `' (bits  |`  NN0 ) `  ( ( A  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) )  +  ( `' (bits  |`  NN0 ) `  ( ( B  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) ) )  =  ( ( `' (bits  |`  NN0 ) `  ( A  i^i  (
0..^ N ) ) )  +  ( `' (bits  |`  NN0 ) `  ( B  i^i  (
0..^ N ) ) ) )
1110oveq1i 5868 . . . 4  |-  ( ( ( `' (bits  |`  NN0 ) `  ( ( A  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) )  +  ( `' (bits  |`  NN0 ) `  ( ( B  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) ) )  mod  ( 2 ^ N ) )  =  ( ( ( `' (bits  |`  NN0 ) `  ( A  i^i  (
0..^ N ) ) )  +  ( `' (bits  |`  NN0 ) `  ( B  i^i  (
0..^ N ) ) ) )  mod  (
2 ^ N ) )
12 inss1 3389 . . . . . 6  |-  ( A  i^i  ( 0..^ N ) )  C_  A
13 sadeq.a . . . . . 6  |-  ( ph  ->  A  C_  NN0 )
1412, 13syl5ss 3190 . . . . 5  |-  ( ph  ->  ( A  i^i  (
0..^ N ) ) 
C_  NN0 )
15 inss1 3389 . . . . . 6  |-  ( B  i^i  ( 0..^ N ) )  C_  B
16 sadeq.b . . . . . 6  |-  ( ph  ->  B  C_  NN0 )
1715, 16syl5ss 3190 . . . . 5  |-  ( ph  ->  ( B  i^i  (
0..^ N ) ) 
C_  NN0 )
18 eqid 2283 . . . . 5  |-  seq  0
( ( c  e.  2o ,  m  e. 
NN0  |->  if (cadd ( m  e.  ( A  i^i  ( 0..^ N ) ) ,  m  e.  ( B  i^i  (
0..^ N ) ) ,  (/)  e.  c
) ,  1o ,  (/) ) ) ,  ( n  e.  NN0  |->  if ( n  =  0 ,  (/) ,  ( n  - 
1 ) ) ) )  =  seq  0
( ( c  e.  2o ,  m  e. 
NN0  |->  if (cadd ( m  e.  ( A  i^i  ( 0..^ N ) ) ,  m  e.  ( B  i^i  (
0..^ N ) ) ,  (/)  e.  c
) ,  1o ,  (/) ) ) ,  ( n  e.  NN0  |->  if ( n  =  0 ,  (/) ,  ( n  - 
1 ) ) ) )
19 sadeq.n . . . . 5  |-  ( ph  ->  N  e.  NN0 )
20 eqid 2283 . . . . 5  |-  `' (bits  |`  NN0 )  =  `' (bits  |`  NN0 )
2114, 17, 18, 19, 20sadadd3 12652 . . . 4  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) )  mod  ( 2 ^ N ) )  =  ( ( ( `' (bits  |`  NN0 ) `  ( ( A  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) )  +  ( `' (bits  |`  NN0 ) `  ( ( B  i^i  ( 0..^ N ) )  i^i  ( 0..^ N ) ) ) )  mod  ( 2 ^ N ) ) )
22 eqid 2283 . . . . 5  |-  seq  0
( ( c  e.  2o ,  m  e. 
NN0  |->  if (cadd ( m  e.  A ,  m  e.  B ,  (/) 
e.  c ) ,  1o ,  (/) ) ) ,  ( n  e. 
NN0  |->  if ( n  =  0 ,  (/) ,  ( n  -  1 ) ) ) )  =  seq  0 ( ( c  e.  2o ,  m  e.  NN0  |->  if (cadd ( m  e.  A ,  m  e.  B ,  (/)  e.  c ) ,  1o ,  (/) ) ) ,  ( n  e.  NN0  |->  if ( n  =  0 ,  (/) ,  ( n  - 
1 ) ) ) )
2313, 16, 22, 19, 20sadadd3 12652 . . . 4  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  mod  (
2 ^ N ) )  =  ( ( ( `' (bits  |`  NN0 ) `  ( A  i^i  (
0..^ N ) ) )  +  ( `' (bits  |`  NN0 ) `  ( B  i^i  (
0..^ N ) ) ) )  mod  (
2 ^ N ) ) )
2411, 21, 233eqtr4a 2341 . . 3  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) )  mod  ( 2 ^ N ) )  =  ( ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  mod  (
2 ^ N ) ) )
25 inss1 3389 . . . . . . . 8  |-  ( ( ( A  i^i  (
0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  C_  ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )
26 sadcl 12653 . . . . . . . . 9  |-  ( ( ( A  i^i  (
0..^ N ) ) 
C_  NN0  /\  ( B  i^i  ( 0..^ N ) )  C_  NN0 )  ->  ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  C_  NN0 )
2714, 17, 26syl2anc 642 . . . . . . . 8  |-  ( ph  ->  ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  C_  NN0 )
2825, 27syl5ss 3190 . . . . . . 7  |-  ( ph  ->  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) )  C_  NN0 )
29 fzofi 11036 . . . . . . . . 9  |-  ( 0..^ N )  e.  Fin
3029a1i 10 . . . . . . . 8  |-  ( ph  ->  ( 0..^ N )  e.  Fin )
31 inss2 3390 . . . . . . . 8  |-  ( ( ( A  i^i  (
0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  C_  ( 0..^ N )
32 ssfi 7083 . . . . . . . 8  |-  ( ( ( 0..^ N )  e.  Fin  /\  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  C_  ( 0..^ N ) )  ->  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  Fin )
3330, 31, 32sylancl 643 . . . . . . 7  |-  ( ph  ->  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  Fin )
34 elfpw 7157 . . . . . . 7  |-  ( ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin )  <->  ( ( ( ( A  i^i  (
0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  C_  NN0 
/\  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  Fin )
)
3528, 33, 34sylanbrc 645 . . . . . 6  |-  ( ph  ->  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  ( ~P
NN0  i^i  Fin )
)
36 bitsf1o 12636 . . . . . . . 8  |-  (bits  |`  NN0 ) : NN0
-1-1-onto-> ( ~P NN0  i^i  Fin )
37 f1ocnv 5485 . . . . . . . 8  |-  ( (bits  |`  NN0 ) : NN0 -1-1-onto-> ( ~P NN0  i^i  Fin )  ->  `' (bits  |`  NN0 ) : ( ~P NN0  i^i 
Fin ) -1-1-onto-> NN0 )
38 f1of 5472 . . . . . . . 8  |-  ( `' (bits  |`  NN0 ) : ( ~P NN0  i^i  Fin ) -1-1-onto-> NN0  ->  `' (bits  |` 
NN0 ) : ( ~P NN0  i^i  Fin )
--> NN0 )
3936, 37, 38mp2b 9 . . . . . . 7  |-  `' (bits  |`  NN0 ) : ( ~P NN0  i^i  Fin )
--> NN0
4039ffvelrni 5664 . . . . . 6  |-  ( ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin )  ->  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  NN0 )
4135, 40syl 15 . . . . 5  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  NN0 )
4241nn0red 10019 . . . 4  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  RR )
43 2rp 10359 . . . . . 6  |-  2  e.  RR+
4443a1i 10 . . . . 5  |-  ( ph  ->  2  e.  RR+ )
4519nn0zd 10115 . . . . 5  |-  ( ph  ->  N  e.  ZZ )
4644, 45rpexpcld 11268 . . . 4  |-  ( ph  ->  ( 2 ^ N
)  e.  RR+ )
4741nn0ge0d 10021 . . . 4  |-  ( ph  ->  0  <_  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )
48 fvres 5542 . . . . . . . . 9  |-  ( ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  NN0  ->  ( (bits  |`  NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  =  (bits `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) ) )
4941, 48syl 15 . . . . . . . 8  |-  ( ph  ->  ( (bits  |`  NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  =  (bits `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) ) )
50 f1ocnvfv2 5793 . . . . . . . . 9  |-  ( ( (bits  |`  NN0 ) : NN0
-1-1-onto-> ( ~P NN0  i^i  Fin )  /\  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  ( ~P
NN0  i^i  Fin )
)  ->  ( (bits  |` 
NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )
5136, 35, 50sylancr 644 . . . . . . . 8  |-  ( ph  ->  ( (bits  |`  NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )
5249, 51eqtr3d 2317 . . . . . . 7  |-  ( ph  ->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )
5331a1i 10 . . . . . . 7  |-  ( ph  ->  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) )  C_  ( 0..^ N ) )
5452, 53eqsstrd 3212 . . . . . 6  |-  ( ph  ->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  C_  ( 0..^ N ) )
5541nn0zd 10115 . . . . . . 7  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  ZZ )
56 bitsfzo 12626 . . . . . . 7  |-  ( ( ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  ZZ  /\  N  e.  NN0 )  ->  ( ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) )  <->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  C_  ( 0..^ N ) ) )
5755, 19, 56syl2anc 642 . . . . . 6  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) )  <->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )  C_  ( 0..^ N ) ) )
5854, 57mpbird 223 . . . . 5  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) ) )
59 elfzolt2 10883 . . . . 5  |-  ( ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) )  -> 
( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  <  (
2 ^ N ) )
6058, 59syl 15 . . . 4  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  <  (
2 ^ N ) )
61 modid 10993 . . . 4  |-  ( ( ( ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) )  e.  RR  /\  (
2 ^ N )  e.  RR+ )  /\  (
0  <_  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  /\  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  <  (
2 ^ N ) ) )  ->  (
( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  mod  (
2 ^ N ) )  =  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )
6242, 46, 47, 60, 61syl22anc 1183 . . 3  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) )  mod  ( 2 ^ N ) )  =  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )
63 inss1 3389 . . . . . . . 8  |-  ( ( A sadd  B )  i^i  ( 0..^ N ) )  C_  ( A sadd  B )
64 sadcl 12653 . . . . . . . . 9  |-  ( ( A  C_  NN0  /\  B  C_ 
NN0 )  ->  ( A sadd  B )  C_  NN0 )
6513, 16, 64syl2anc 642 . . . . . . . 8  |-  ( ph  ->  ( A sadd  B ) 
C_  NN0 )
6663, 65syl5ss 3190 . . . . . . 7  |-  ( ph  ->  ( ( A sadd  B
)  i^i  ( 0..^ N ) )  C_  NN0 )
67 inss2 3390 . . . . . . . 8  |-  ( ( A sadd  B )  i^i  ( 0..^ N ) )  C_  ( 0..^ N )
68 ssfi 7083 . . . . . . . 8  |-  ( ( ( 0..^ N )  e.  Fin  /\  (
( A sadd  B )  i^i  ( 0..^ N ) )  C_  ( 0..^ N ) )  -> 
( ( A sadd  B
)  i^i  ( 0..^ N ) )  e. 
Fin )
6930, 67, 68sylancl 643 . . . . . . 7  |-  ( ph  ->  ( ( A sadd  B
)  i^i  ( 0..^ N ) )  e. 
Fin )
70 elfpw 7157 . . . . . . 7  |-  ( ( ( A sadd  B )  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin ) 
<->  ( ( ( A sadd 
B )  i^i  (
0..^ N ) ) 
C_  NN0  /\  (
( A sadd  B )  i^i  ( 0..^ N ) )  e.  Fin )
)
7166, 69, 70sylanbrc 645 . . . . . 6  |-  ( ph  ->  ( ( A sadd  B
)  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin ) )
7239ffvelrni 5664 . . . . . 6  |-  ( ( ( A sadd  B )  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin )  ->  ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  e.  NN0 )
7371, 72syl 15 . . . . 5  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  NN0 )
7473nn0red 10019 . . . 4  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  RR )
7573nn0ge0d 10021 . . . 4  |-  ( ph  ->  0  <_  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )
76 fvres 5542 . . . . . . . . 9  |-  ( ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  NN0  ->  ( (bits  |`  NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  =  (bits `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) ) )
7773, 76syl 15 . . . . . . . 8  |-  ( ph  ->  ( (bits  |`  NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  =  (bits `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) ) )
78 f1ocnvfv2 5793 . . . . . . . . 9  |-  ( ( (bits  |`  NN0 ) : NN0
-1-1-onto-> ( ~P NN0  i^i  Fin )  /\  ( ( A sadd 
B )  i^i  (
0..^ N ) )  e.  ( ~P NN0  i^i 
Fin ) )  -> 
( (bits  |`  NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  =  ( ( A sadd  B )  i^i  ( 0..^ N ) ) )
7936, 71, 78sylancr 644 . . . . . . . 8  |-  ( ph  ->  ( (bits  |`  NN0 ) `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  =  ( ( A sadd  B )  i^i  ( 0..^ N ) ) )
8077, 79eqtr3d 2317 . . . . . . 7  |-  ( ph  ->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  =  ( ( A sadd  B )  i^i  ( 0..^ N ) ) )
8167a1i 10 . . . . . . 7  |-  ( ph  ->  ( ( A sadd  B
)  i^i  ( 0..^ N ) )  C_  ( 0..^ N ) )
8280, 81eqsstrd 3212 . . . . . 6  |-  ( ph  ->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  C_  ( 0..^ N ) )
8373nn0zd 10115 . . . . . . 7  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  ZZ )
84 bitsfzo 12626 . . . . . . 7  |-  ( ( ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  ZZ  /\  N  e.  NN0 )  ->  (
( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) )  <->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  C_  ( 0..^ N ) ) )
8583, 19, 84syl2anc 642 . . . . . 6  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) )  <->  (bits `  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )  C_  ( 0..^ N ) ) )
8682, 85mpbird 223 . . . . 5  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) ) )
87 elfzolt2 10883 . . . . 5  |-  ( ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  e.  ( 0..^ ( 2 ^ N ) )  ->  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  <  ( 2 ^ N ) )
8886, 87syl 15 . . . 4  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  <  ( 2 ^ N ) )
89 modid 10993 . . . 4  |-  ( ( ( ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  e.  RR  /\  ( 2 ^ N
)  e.  RR+ )  /\  ( 0  <_  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  /\  ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  <  (
2 ^ N ) ) )  ->  (
( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  mod  ( 2 ^ N ) )  =  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )
9074, 46, 75, 88, 89syl22anc 1183 . . 3  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  mod  (
2 ^ N ) )  =  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) ) )
9124, 62, 903eqtr3rd 2324 . 2  |-  ( ph  ->  ( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  =  ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )
92 f1of1 5471 . . . . 5  |-  ( `' (bits  |`  NN0 ) : ( ~P NN0  i^i  Fin ) -1-1-onto-> NN0  ->  `' (bits  |` 
NN0 ) : ( ~P NN0  i^i  Fin ) -1-1-> NN0 )
9336, 37, 92mp2b 9 . . . 4  |-  `' (bits  |`  NN0 ) : ( ~P NN0  i^i  Fin ) -1-1-> NN0
94 f1fveq 5786 . . . 4  |-  ( ( `' (bits  |`  NN0 ) : ( ~P NN0  i^i 
Fin ) -1-1-> NN0  /\  ( ( ( A sadd 
B )  i^i  (
0..^ N ) )  e.  ( ~P NN0  i^i 
Fin )  /\  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin ) ) )  -> 
( ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  =  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  <->  ( ( A sadd  B )  i^i  (
0..^ N ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )
9593, 94mpan 651 . . 3  |-  ( ( ( ( A sadd  B
)  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin )  /\  ( ( ( A  i^i  (
0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) )  e.  ( ~P NN0  i^i  Fin ) )  ->  (
( `' (bits  |`  NN0 ) `  ( ( A sadd  B
)  i^i  ( 0..^ N ) ) )  =  ( `' (bits  |`  NN0 ) `  (
( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  (
0..^ N ) ) )  i^i  ( 0..^ N ) ) )  <-> 
( ( A sadd  B
)  i^i  ( 0..^ N ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )
9671, 35, 95syl2anc 642 . 2  |-  ( ph  ->  ( ( `' (bits  |`  NN0 ) `  (
( A sadd  B )  i^i  ( 0..^ N ) ) )  =  ( `' (bits  |`  NN0 ) `  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )  <->  ( ( A sadd  B )  i^i  (
0..^ N ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) ) )
9791, 96mpbid 201 1  |-  ( ph  ->  ( ( A sadd  B
)  i^i  ( 0..^ N ) )  =  ( ( ( A  i^i  ( 0..^ N ) ) sadd  ( B  i^i  ( 0..^ N ) ) )  i^i  ( 0..^ N ) ) )
Colors of variables: wff set class
Syntax hints:    -> wi 4    <-> wb 176    /\ wa 358  caddwcad 1369    = wceq 1623    e. wcel 1684    i^i cin 3151    C_ wss 3152   (/)c0 3455   ifcif 3565   ~Pcpw 3625   class class class wbr 4023    e. cmpt 4077   `'ccnv 4688    |` cres 4691   -->wf 5251   -1-1->wf1 5252   -1-1-onto->wf1o 5254   ` cfv 5255  (class class class)co 5858    e. cmpt2 5860   1oc1o 6472   2oc2o 6473   Fincfn 6863   RRcr 8736   0cc0 8737   1c1 8738    + caddc 8740    < clt 8867    <_ cle 8868    - cmin 9037   2c2 9795   NN0cn0 9965   ZZcz 10024   RR+crp 10354  ..^cfzo 10870    mod cmo 10973    seq cseq 11046   ^cexp 11104  bitscbits 12610   sadd csad 12611
This theorem is referenced by:  smuval2  12673  smueqlem  12681
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1533  ax-5 1544  ax-17 1603  ax-9 1635  ax-8 1643  ax-13 1686  ax-14 1688  ax-6 1703  ax-7 1708  ax-11 1715  ax-12 1866  ax-ext 2264  ax-rep 4131  ax-sep 4141  ax-nul 4149  ax-pow 4188  ax-pr 4214  ax-un 4512  ax-inf2 7342  ax-cnex 8793  ax-resscn 8794  ax-1cn 8795  ax-icn 8796  ax-addcl 8797  ax-addrcl 8798  ax-mulcl 8799  ax-mulrcl 8800  ax-mulcom 8801  ax-addass 8802  ax-mulass 8803  ax-distr 8804  ax-i2m1 8805  ax-1ne0 8806  ax-1rid 8807  ax-rnegex 8808  ax-rrecex 8809  ax-cnre 8810  ax-pre-lttri 8811  ax-pre-lttrn 8812  ax-pre-ltadd 8813  ax-pre-mulgt0 8814  ax-pre-sup 8815
This theorem depends on definitions:  df-bi 177  df-or 359  df-an 360  df-3or 935  df-3an 936  df-xor 1296  df-tru 1310  df-had 1370  df-cad 1371  df-ex 1529  df-nf 1532  df-sb 1630  df-eu 2147  df-mo 2148  df-clab 2270  df-cleq 2276  df-clel 2279  df-nfc 2408  df-ne 2448  df-nel 2449  df-ral 2548  df-rex 2549  df-reu 2550  df-rmo 2551  df-rab 2552  df-v 2790  df-sbc 2992  df-csb 3082  df-dif 3155  df-un 3157  df-in 3159  df-ss 3166  df-pss 3168  df-nul 3456  df-if 3566  df-pw 3627  df-sn 3646  df-pr 3647  df-tp 3648  df-op 3649  df-uni 3828  df-int 3863  df-iun 3907  df-disj 3994  df-br 4024  df-opab 4078  df-mpt 4079  df-tr 4114  df-eprel 4305  df-id 4309  df-po 4314  df-so 4315  df-fr 4352  df-se 4353  df-we 4354  df-ord 4395  df-on 4396  df-lim 4397  df-suc 4398  df-om 4657  df-xp 4695  df-rel 4696  df-cnv 4697  df-co 4698  df-dm 4699  df-rn 4700  df-res 4701  df-ima 4702  df-iota 5219  df-fun 5257  df-fn 5258  df-f 5259  df-f1 5260  df-fo 5261  df-f1o 5262  df-fv 5263  df-isom 5264  df-ov 5861  df-oprab 5862  df-mpt2 5863  df-1st 6122  df-2nd 6123  df-riota 6304  df-recs 6388  df-rdg 6423  df-1o 6479  df-2o 6480  df-oadd 6483  df-er 6660  df-map 6774  df-pm 6775  df-en 6864  df-dom 6865  df-sdom 6866  df-fin 6867  df-sup 7194  df-oi 7225  df-card 7572  df-cda 7794  df-pnf 8869  df-mnf 8870  df-xr 8871  df-ltxr 8872  df-le 8873  df-sub 9039  df-neg 9040  df-div 9424  df-nn 9747  df-2 9804  df-3 9805  df-n0 9966  df-z 10025  df-uz 10231  df-rp 10355  df-fz 10783  df-fzo 10871  df-fl 10925  df-mod 10974  df-seq 11047  df-exp 11105  df-hash 11338  df-cj 11584  df-re 11585  df-im 11586  df-sqr 11720  df-abs 11721  df-clim 11962  df-sum 12159  df-dvds 12532  df-bits 12613  df-sad 12642
  Copyright terms: Public domain W3C validator