Metamath Proof Explorer


Theorem smufval

Description: The multiplication of two bit sequences as repeated sequence addition. (Contributed by Mario Carneiro, 9-Sep-2016)

Ref Expression
Hypotheses smuval.a φA0
smuval.b φB0
smuval.p P=seq0p𝒫0,m0psaddn0|mAnmBn0ifn=0n1
Assertion smufval φAsmulB=k0|kPk+1

Proof

Step Hyp Ref Expression
1 smuval.a φA0
2 smuval.b φB0
3 smuval.p P=seq0p𝒫0,m0psaddn0|mAnmBn0ifn=0n1
4 nn0ex 0V
5 4 elpw2 A𝒫0A0
6 1 5 sylibr φA𝒫0
7 4 elpw2 B𝒫0B0
8 2 7 sylibr φB𝒫0
9 simp1l x=Ay=Bp𝒫0m0x=A
10 9 eleq2d x=Ay=Bp𝒫0m0mxmA
11 simp1r x=Ay=Bp𝒫0m0y=B
12 11 eleq2d x=Ay=Bp𝒫0m0nmynmB
13 10 12 anbi12d x=Ay=Bp𝒫0m0mxnmymAnmB
14 13 rabbidv x=Ay=Bp𝒫0m0n0|mxnmy=n0|mAnmB
15 14 oveq2d x=Ay=Bp𝒫0m0psaddn0|mxnmy=psaddn0|mAnmB
16 15 mpoeq3dva x=Ay=Bp𝒫0,m0psaddn0|mxnmy=p𝒫0,m0psaddn0|mAnmB
17 16 seqeq2d x=Ay=Bseq0p𝒫0,m0psaddn0|mxnmyn0ifn=0n1=seq0p𝒫0,m0psaddn0|mAnmBn0ifn=0n1
18 17 3 eqtr4di x=Ay=Bseq0p𝒫0,m0psaddn0|mxnmyn0ifn=0n1=P
19 18 fveq1d x=Ay=Bseq0p𝒫0,m0psaddn0|mxnmyn0ifn=0n1k+1=Pk+1
20 19 eleq2d x=Ay=Bkseq0p𝒫0,m0psaddn0|mxnmyn0ifn=0n1k+1kPk+1
21 20 rabbidv x=Ay=Bk0|kseq0p𝒫0,m0psaddn0|mxnmyn0ifn=0n1k+1=k0|kPk+1
22 df-smu smul=x𝒫0,y𝒫0k0|kseq0p𝒫0,m0psaddn0|mxnmyn0ifn=0n1k+1
23 4 rabex k0|kPk+1V
24 21 22 23 ovmpoa A𝒫0B𝒫0AsmulB=k0|kPk+1
25 6 8 24 syl2anc φAsmulB=k0|kPk+1