Metamath Proof Explorer


Theorem plymulx0

Description: Coefficients of a polynomial multiplied by Xp . (Contributed by Thierry Arnoux, 25-Sep-2018)

Ref Expression
Assertion plymulx0 F Poly 0 𝑝 coeff F × f X p = n 0 if n = 0 0 coeff F n 1

Proof

Step Hyp Ref Expression
1 eldifi F Poly 0 𝑝 F Poly
2 ax-resscn
3 1re 1
4 plyid 1 X p Poly
5 2 3 4 mp2an X p Poly
6 5 a1i F Poly 0 𝑝 X p Poly
7 simprl F Poly 0 𝑝 x y x
8 simprr F Poly 0 𝑝 x y y
9 7 8 readdcld F Poly 0 𝑝 x y x + y
10 7 8 remulcld F Poly 0 𝑝 x y x y
11 1 6 9 10 plymul F Poly 0 𝑝 F × f X p Poly
12 0re 0
13 eqid coeff F × f X p = coeff F × f X p
14 13 coef2 F × f X p Poly 0 coeff F × f X p : 0
15 11 12 14 sylancl F Poly 0 𝑝 coeff F × f X p : 0
16 15 feqmptd F Poly 0 𝑝 coeff F × f X p = n 0 coeff F × f X p n
17 cnex V
18 17 a1i F Poly 0 𝑝 V
19 plyf F Poly F :
20 1 19 syl F Poly 0 𝑝 F :
21 plyf X p Poly X p :
22 5 21 ax-mp X p :
23 22 a1i F Poly 0 𝑝 X p :
24 simprl F Poly 0 𝑝 x y x
25 simprr F Poly 0 𝑝 x y y
26 24 25 mulcomd F Poly 0 𝑝 x y x y = y x
27 18 20 23 26 caofcom F Poly 0 𝑝 F × f X p = X p × f F
28 27 fveq2d F Poly 0 𝑝 coeff F × f X p = coeff X p × f F
29 28 fveq1d F Poly 0 𝑝 coeff F × f X p n = coeff X p × f F n
30 29 adantr F Poly 0 𝑝 n 0 coeff F × f X p n = coeff X p × f F n
31 5 a1i F Poly 0 𝑝 n 0 X p Poly
32 1 adantr F Poly 0 𝑝 n 0 F Poly
33 simpr F Poly 0 𝑝 n 0 n 0
34 eqid coeff X p = coeff X p
35 eqid coeff F = coeff F
36 34 35 coemul X p Poly F Poly n 0 coeff X p × f F n = i = 0 n coeff X p i coeff F n i
37 31 32 33 36 syl3anc F Poly 0 𝑝 n 0 coeff X p × f F n = i = 0 n coeff X p i coeff F n i
38 elfznn0 i 0 n i 0
39 coeidp i 0 coeff X p i = if i = 1 1 0
40 38 39 syl i 0 n coeff X p i = if i = 1 1 0
41 40 oveq1d i 0 n coeff X p i coeff F n i = if i = 1 1 0 coeff F n i
42 ovif if i = 1 1 0 coeff F n i = if i = 1 1 coeff F n i 0 coeff F n i
43 41 42 eqtrdi i 0 n coeff X p i coeff F n i = if i = 1 1 coeff F n i 0 coeff F n i
44 43 adantl F Poly 0 𝑝 n 0 i 0 n coeff X p i coeff F n i = if i = 1 1 coeff F n i 0 coeff F n i
45 44 sumeq2dv F Poly 0 𝑝 n 0 i = 0 n coeff X p i coeff F n i = i = 0 n if i = 1 1 coeff F n i 0 coeff F n i
46 velsn i 1 i = 1
47 46 bicomi i = 1 i 1
48 47 a1i F Poly 0 𝑝 n 0 i 0 n i = 1 i 1
49 35 coef2 F Poly 0 coeff F : 0
50 1 12 49 sylancl F Poly 0 𝑝 coeff F : 0
51 50 ad2antrr F Poly 0 𝑝 n 0 i 0 n coeff F : 0
52 fznn0sub i 0 n n i 0
53 52 adantl F Poly 0 𝑝 n 0 i 0 n n i 0
54 51 53 ffvelrnd F Poly 0 𝑝 n 0 i 0 n coeff F n i
55 54 recnd F Poly 0 𝑝 n 0 i 0 n coeff F n i
56 55 mulid2d F Poly 0 𝑝 n 0 i 0 n 1 coeff F n i = coeff F n i
57 55 mul02d F Poly 0 𝑝 n 0 i 0 n 0 coeff F n i = 0
58 48 56 57 ifbieq12d F Poly 0 𝑝 n 0 i 0 n if i = 1 1 coeff F n i 0 coeff F n i = if i 1 coeff F n i 0
59 58 sumeq2dv F Poly 0 𝑝 n 0 i = 0 n if i = 1 1 coeff F n i 0 coeff F n i = i = 0 n if i 1 coeff F n i 0
60 eqeq2 0 = if n = 0 0 coeff F n 1 i = 0 n if i 1 coeff F n i 0 = 0 i = 0 n if i 1 coeff F n i 0 = if n = 0 0 coeff F n 1
61 eqeq2 coeff F n 1 = if n = 0 0 coeff F n 1 i = 0 n if i 1 coeff F n i 0 = coeff F n 1 i = 0 n if i 1 coeff F n i 0 = if n = 0 0 coeff F n 1
62 oveq2 n = 0 0 n = 0 0
63 0z 0
64 fzsn 0 0 0 = 0
65 63 64 ax-mp 0 0 = 0
66 62 65 eqtrdi n = 0 0 n = 0
67 elsni i 0 i = 0
68 67 adantl n = 0 i 0 i = 0
69 ax-1ne0 1 0
70 69 nesymi ¬ 0 = 1
71 eqeq1 i = 0 i = 1 0 = 1
72 70 71 mtbiri i = 0 ¬ i = 1
73 68 72 syl n = 0 i 0 ¬ i = 1
74 47 notbii ¬ i = 1 ¬ i 1
75 74 biimpi ¬ i = 1 ¬ i 1
76 iffalse ¬ i 1 if i 1 coeff F n i 0 = 0
77 73 75 76 3syl n = 0 i 0 if i 1 coeff F n i 0 = 0
78 66 77 sumeq12rdv n = 0 i = 0 n if i 1 coeff F n i 0 = i 0 0
79 snfi 0 Fin
80 79 olci 0 0 0 Fin
81 sumz 0 0 0 Fin i 0 0 = 0
82 80 81 ax-mp i 0 0 = 0
83 78 82 eqtrdi n = 0 i = 0 n if i 1 coeff F n i 0 = 0
84 83 adantl F Poly 0 𝑝 n 0 n = 0 i = 0 n if i 1 coeff F n i 0 = 0
85 simpll F Poly 0 𝑝 n 0 ¬ n = 0 F Poly 0 𝑝
86 33 adantr F Poly 0 𝑝 n 0 ¬ n = 0 n 0
87 simpr F Poly 0 𝑝 n 0 ¬ n = 0 ¬ n = 0
88 87 neqned F Poly 0 𝑝 n 0 ¬ n = 0 n 0
89 elnnne0 n n 0 n 0
90 86 88 89 sylanbrc F Poly 0 𝑝 n 0 ¬ n = 0 n
91 1nn0 1 0
92 91 a1i F Poly 0 𝑝 n 1 0
93 simpr F Poly 0 𝑝 n n
94 93 nnnn0d F Poly 0 𝑝 n n 0
95 93 nnge1d F Poly 0 𝑝 n 1 n
96 elfz2nn0 1 0 n 1 0 n 0 1 n
97 92 94 95 96 syl3anbrc F Poly 0 𝑝 n 1 0 n
98 97 snssd F Poly 0 𝑝 n 1 0 n
99 50 ad2antrr F Poly 0 𝑝 n i 1 coeff F : 0
100 oveq2 i = 1 n i = n 1
101 46 100 sylbi i 1 n i = n 1
102 101 adantl F Poly 0 𝑝 n i 1 n i = n 1
103 nnm1nn0 n n 1 0
104 103 ad2antlr F Poly 0 𝑝 n i 1 n 1 0
105 102 104 eqeltrd F Poly 0 𝑝 n i 1 n i 0
106 99 105 ffvelrnd F Poly 0 𝑝 n i 1 coeff F n i
107 106 recnd F Poly 0 𝑝 n i 1 coeff F n i
108 107 ralrimiva F Poly 0 𝑝 n i 1 coeff F n i
109 fzfi 0 n Fin
110 109 olci 0 n 0 0 n Fin
111 110 a1i F Poly 0 𝑝 n 0 n 0 0 n Fin
112 sumss2 1 0 n i 1 coeff F n i 0 n 0 0 n Fin i 1 coeff F n i = i = 0 n if i 1 coeff F n i 0
113 98 108 111 112 syl21anc F Poly 0 𝑝 n i 1 coeff F n i = i = 0 n if i 1 coeff F n i 0
114 50 adantr F Poly 0 𝑝 n coeff F : 0
115 103 adantl F Poly 0 𝑝 n n 1 0
116 114 115 ffvelrnd F Poly 0 𝑝 n coeff F n 1
117 116 recnd F Poly 0 𝑝 n coeff F n 1
118 100 fveq2d i = 1 coeff F n i = coeff F n 1
119 118 sumsn 1 coeff F n 1 i 1 coeff F n i = coeff F n 1
120 3 117 119 sylancr F Poly 0 𝑝 n i 1 coeff F n i = coeff F n 1
121 113 120 eqtr3d F Poly 0 𝑝 n i = 0 n if i 1 coeff F n i 0 = coeff F n 1
122 85 90 121 syl2anc F Poly 0 𝑝 n 0 ¬ n = 0 i = 0 n if i 1 coeff F n i 0 = coeff F n 1
123 60 61 84 122 ifbothda F Poly 0 𝑝 n 0 i = 0 n if i 1 coeff F n i 0 = if n = 0 0 coeff F n 1
124 59 123 eqtrd F Poly 0 𝑝 n 0 i = 0 n if i = 1 1 coeff F n i 0 coeff F n i = if n = 0 0 coeff F n 1
125 37 45 124 3eqtrd F Poly 0 𝑝 n 0 coeff X p × f F n = if n = 0 0 coeff F n 1
126 30 125 eqtrd F Poly 0 𝑝 n 0 coeff F × f X p n = if n = 0 0 coeff F n 1
127 126 mpteq2dva F Poly 0 𝑝 n 0 coeff F × f X p n = n 0 if n = 0 0 coeff F n 1
128 16 127 eqtrd F Poly 0 𝑝 coeff F × f X p = n 0 if n = 0 0 coeff F n 1