Metamath Proof Explorer


Theorem xmettri

Description: Triangle inequality for the distance function of a metric space. Definition 14-1.1(d) of Gleason p. 223. (Contributed by Mario Carneiro, 20-Aug-2015)

Ref Expression
Assertion xmettri ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → ( 𝐴 𝐷 𝐵 ) ≤ ( ( 𝐴 𝐷 𝐶 ) +𝑒 ( 𝐶 𝐷 𝐵 ) ) )

Proof

Step Hyp Ref Expression
1 simpl ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → 𝐷 ∈ ( ∞Met ‘ 𝑋 ) )
2 simpr3 ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → 𝐶𝑋 )
3 simpr1 ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → 𝐴𝑋 )
4 simpr2 ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → 𝐵𝑋 )
5 xmettri2 ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐶𝑋𝐴𝑋𝐵𝑋 ) ) → ( 𝐴 𝐷 𝐵 ) ≤ ( ( 𝐶 𝐷 𝐴 ) +𝑒 ( 𝐶 𝐷 𝐵 ) ) )
6 1 2 3 4 5 syl13anc ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → ( 𝐴 𝐷 𝐵 ) ≤ ( ( 𝐶 𝐷 𝐴 ) +𝑒 ( 𝐶 𝐷 𝐵 ) ) )
7 xmetsym ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ 𝐶𝑋𝐴𝑋 ) → ( 𝐶 𝐷 𝐴 ) = ( 𝐴 𝐷 𝐶 ) )
8 1 2 3 7 syl3anc ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → ( 𝐶 𝐷 𝐴 ) = ( 𝐴 𝐷 𝐶 ) )
9 8 oveq1d ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → ( ( 𝐶 𝐷 𝐴 ) +𝑒 ( 𝐶 𝐷 𝐵 ) ) = ( ( 𝐴 𝐷 𝐶 ) +𝑒 ( 𝐶 𝐷 𝐵 ) ) )
10 6 9 breqtrd ( ( 𝐷 ∈ ( ∞Met ‘ 𝑋 ) ∧ ( 𝐴𝑋𝐵𝑋𝐶𝑋 ) ) → ( 𝐴 𝐷 𝐵 ) ≤ ( ( 𝐴 𝐷 𝐶 ) +𝑒 ( 𝐶 𝐷 𝐵 ) ) )