Metamath Proof Explorer


Theorem ablpnpcan

Description: Cancellation law for mixed addition and subtraction. ( pnpcan analog.) (Contributed by NM, 29-May-2015)

Ref Expression
Hypotheses ablsubadd.b 𝐵 = ( Base ‘ 𝐺 )
ablsubadd.p + = ( +g𝐺 )
ablsubadd.m = ( -g𝐺 )
ablsubsub.g ( 𝜑𝐺 ∈ Abel )
ablsubsub.x ( 𝜑𝑋𝐵 )
ablsubsub.y ( 𝜑𝑌𝐵 )
ablsubsub.z ( 𝜑𝑍𝐵 )
ablpnpcan.g ( 𝜑𝐺 ∈ Abel )
ablpnpcan.x ( 𝜑𝑋𝐵 )
ablpnpcan.y ( 𝜑𝑌𝐵 )
ablpnpcan.z ( 𝜑𝑍𝐵 )
Assertion ablpnpcan ( 𝜑 → ( ( 𝑋 + 𝑌 ) ( 𝑋 + 𝑍 ) ) = ( 𝑌 𝑍 ) )

Proof

Step Hyp Ref Expression
1 ablsubadd.b 𝐵 = ( Base ‘ 𝐺 )
2 ablsubadd.p + = ( +g𝐺 )
3 ablsubadd.m = ( -g𝐺 )
4 ablsubsub.g ( 𝜑𝐺 ∈ Abel )
5 ablsubsub.x ( 𝜑𝑋𝐵 )
6 ablsubsub.y ( 𝜑𝑌𝐵 )
7 ablsubsub.z ( 𝜑𝑍𝐵 )
8 ablpnpcan.g ( 𝜑𝐺 ∈ Abel )
9 ablpnpcan.x ( 𝜑𝑋𝐵 )
10 ablpnpcan.y ( 𝜑𝑌𝐵 )
11 ablpnpcan.z ( 𝜑𝑍𝐵 )
12 1 2 3 ablsub4 ( ( 𝐺 ∈ Abel ∧ ( 𝑋𝐵𝑌𝐵 ) ∧ ( 𝑋𝐵𝑍𝐵 ) ) → ( ( 𝑋 + 𝑌 ) ( 𝑋 + 𝑍 ) ) = ( ( 𝑋 𝑋 ) + ( 𝑌 𝑍 ) ) )
13 4 5 6 5 7 12 syl122anc ( 𝜑 → ( ( 𝑋 + 𝑌 ) ( 𝑋 + 𝑍 ) ) = ( ( 𝑋 𝑋 ) + ( 𝑌 𝑍 ) ) )
14 ablgrp ( 𝐺 ∈ Abel → 𝐺 ∈ Grp )
15 4 14 syl ( 𝜑𝐺 ∈ Grp )
16 eqid ( 0g𝐺 ) = ( 0g𝐺 )
17 1 16 3 grpsubid ( ( 𝐺 ∈ Grp ∧ 𝑋𝐵 ) → ( 𝑋 𝑋 ) = ( 0g𝐺 ) )
18 15 5 17 syl2anc ( 𝜑 → ( 𝑋 𝑋 ) = ( 0g𝐺 ) )
19 18 oveq1d ( 𝜑 → ( ( 𝑋 𝑋 ) + ( 𝑌 𝑍 ) ) = ( ( 0g𝐺 ) + ( 𝑌 𝑍 ) ) )
20 1 3 grpsubcl ( ( 𝐺 ∈ Grp ∧ 𝑌𝐵𝑍𝐵 ) → ( 𝑌 𝑍 ) ∈ 𝐵 )
21 15 6 7 20 syl3anc ( 𝜑 → ( 𝑌 𝑍 ) ∈ 𝐵 )
22 1 2 16 grplid ( ( 𝐺 ∈ Grp ∧ ( 𝑌 𝑍 ) ∈ 𝐵 ) → ( ( 0g𝐺 ) + ( 𝑌 𝑍 ) ) = ( 𝑌 𝑍 ) )
23 15 21 22 syl2anc ( 𝜑 → ( ( 0g𝐺 ) + ( 𝑌 𝑍 ) ) = ( 𝑌 𝑍 ) )
24 13 19 23 3eqtrd ( 𝜑 → ( ( 𝑋 + 𝑌 ) ( 𝑋 + 𝑍 ) ) = ( 𝑌 𝑍 ) )