Metamath Proof Explorer


Theorem xrsdsreval

Description: The metric of the extended real number structure coincides with the real number metric on the reals. (Contributed by Mario Carneiro, 3-Sep-2015)

Ref Expression
Hypothesis xrsds.d D = dist 𝑠 *
Assertion xrsdsreval A B A D B = A B

Proof

Step Hyp Ref Expression
1 xrsds.d D = dist 𝑠 *
2 rexr A A *
3 rexr B B *
4 1 xrsdsval A * B * A D B = if A B B + 𝑒 A A + 𝑒 B
5 2 3 4 syl2an A B A D B = if A B B + 𝑒 A A + 𝑒 B
6 rexsub B A B + 𝑒 A = B A
7 6 ancoms A B B + 𝑒 A = B A
8 7 adantr A B A B B + 𝑒 A = B A
9 abssuble0 A B A B A B = B A
10 9 3expa A B A B A B = B A
11 8 10 eqtr4d A B A B B + 𝑒 A = A B
12 rexsub A B A + 𝑒 B = A B
13 12 adantr A B ¬ A B A + 𝑒 B = A B
14 letric A B A B B A
15 14 orcanai A B ¬ A B B A
16 abssubge0 B A B A A B = A B
17 16 3com12 A B B A A B = A B
18 17 3expa A B B A A B = A B
19 15 18 syldan A B ¬ A B A B = A B
20 13 19 eqtr4d A B ¬ A B A + 𝑒 B = A B
21 11 20 ifeqda A B if A B B + 𝑒 A A + 𝑒 B = A B
22 5 21 eqtrd A B A D B = A B