Metamath Proof Explorer


Theorem lgsmulsqcoprm

Description: The Legendre (Jacobi) symbol is preserved under multiplication with a square of an integer coprime to the second argument. Theorem 9.9(d) in ApostolNT p. 188. (Contributed by AV, 20-Jul-2021)

Ref Expression
Assertion lgsmulsqcoprm AA0BB0NAgcdN=1A2B/LN=B/LN

Proof

Step Hyp Ref Expression
1 zsqcl AA2
2 1 adantr AA0A2
3 simpl BB0B
4 simpl NAgcdN=1N
5 2 3 4 3anim123i AA0BB0NAgcdN=1A2BN
6 zcn AA
7 sqne0 AA20A0
8 6 7 syl AA20A0
9 8 biimpar AA0A20
10 simpr BB0B0
11 9 10 anim12i AA0BB0A20B0
12 11 3adant3 AA0BB0NAgcdN=1A20B0
13 lgsdir A2BNA20B0A2B/LN=A2/LNB/LN
14 5 12 13 syl2anc AA0BB0NAgcdN=1A2B/LN=A2/LNB/LN
15 3anass AA0NAgcdN=1AA0NAgcdN=1
16 15 biimpri AA0NAgcdN=1AA0NAgcdN=1
17 16 3adant2 AA0BB0NAgcdN=1AA0NAgcdN=1
18 lgssq AA0NAgcdN=1A2/LN=1
19 17 18 syl AA0BB0NAgcdN=1A2/LN=1
20 19 oveq1d AA0BB0NAgcdN=1A2/LNB/LN=1B/LN
21 3 4 anim12i BB0NAgcdN=1BN
22 21 3adant1 AA0BB0NAgcdN=1BN
23 lgscl BNB/LN
24 22 23 syl AA0BB0NAgcdN=1B/LN
25 24 zcnd AA0BB0NAgcdN=1B/LN
26 25 mullidd AA0BB0NAgcdN=11B/LN=B/LN
27 14 20 26 3eqtrd AA0BB0NAgcdN=1A2B/LN=B/LN