# Metamath Proof Explorer

## Theorem fzmmmeqm

Description: Subtracting the difference of a member of a finite range of integers and the lower bound of the range from the difference of the upper bound and the lower bound of the range results in the difference of the upper bound of the range and the member. (Contributed by Alexander van der Vekens, 27-May-2018)

Ref Expression
Assertion fzmmmeqm ${⊢}{M}\in \left({L}\dots {N}\right)\to {N}-{L}-\left({M}-{L}\right)={N}-{M}$

### Proof

Step Hyp Ref Expression
1 elfz2 ${⊢}{M}\in \left({L}\dots {N}\right)↔\left(\left({L}\in ℤ\wedge {N}\in ℤ\wedge {M}\in ℤ\right)\wedge \left({L}\le {M}\wedge {M}\le {N}\right)\right)$
2 zcn ${⊢}{N}\in ℤ\to {N}\in ℂ$
3 zcn ${⊢}{M}\in ℤ\to {M}\in ℂ$
4 zcn ${⊢}{L}\in ℤ\to {L}\in ℂ$
5 2 3 4 3anim123i ${⊢}\left({N}\in ℤ\wedge {M}\in ℤ\wedge {L}\in ℤ\right)\to \left({N}\in ℂ\wedge {M}\in ℂ\wedge {L}\in ℂ\right)$
6 5 3comr ${⊢}\left({L}\in ℤ\wedge {N}\in ℤ\wedge {M}\in ℤ\right)\to \left({N}\in ℂ\wedge {M}\in ℂ\wedge {L}\in ℂ\right)$
7 6 adantr ${⊢}\left(\left({L}\in ℤ\wedge {N}\in ℤ\wedge {M}\in ℤ\right)\wedge \left({L}\le {M}\wedge {M}\le {N}\right)\right)\to \left({N}\in ℂ\wedge {M}\in ℂ\wedge {L}\in ℂ\right)$
8 1 7 sylbi ${⊢}{M}\in \left({L}\dots {N}\right)\to \left({N}\in ℂ\wedge {M}\in ℂ\wedge {L}\in ℂ\right)$
9 nnncan2 ${⊢}\left({N}\in ℂ\wedge {M}\in ℂ\wedge {L}\in ℂ\right)\to {N}-{L}-\left({M}-{L}\right)={N}-{M}$
10 8 9 syl ${⊢}{M}\in \left({L}\dots {N}\right)\to {N}-{L}-\left({M}-{L}\right)={N}-{M}$