Difference between revisions of "Triangle inequality"
m |
m (→Definition) |
||
Line 8: | Line 8: | ||
===Proof=== | ===Proof=== | ||
− | + | We have 4 cases: | |
− | + | # Suppose that {{M|a>0}} and {{M|b>0}} | |
− | {{Todo| | + | #: We see immediately that {{M|1=a>0\implies a+b>0+b=b>0}} so {{M|a+b>0}} |
+ | #:* thus {{M|1=\vert a+b\vert=a+b}} | ||
+ | #: We also see that {{M|1=\vert a\vert=a}} as {{M|a>0}} | ||
+ | #: and that {{M|1=\vert b\vert=b}} for the same reason. | ||
+ | #:* thus {{M|1=\vert a\vert+\vert b\vert=a+b}} | ||
+ | #* We see that {{M|1=\vert a+b\vert=\vert a\vert+\vert b\vert}} | ||
+ | #** Notice {{M|1=\vert a+b\vert=\vert a\vert+\vert b\vert\implies\vert a+b\vert\le\vert a\vert+\vert b\vert}} in the literal sense of "if left then right" | ||
+ | #**: ({{M|\implies}} denotes [[Implies|logical implication]]) | ||
+ | # Suppose that {{M|a>0}} and {{M|b\le 0}} | ||
+ | # Suppose that {{M|a\le 0}} and {{M|b> 0}} | ||
+ | #* [[Mathematicians are lazy]], as {{M|\mathbb{R} }} is a [[field]] (an instance of a [[ring]]) we know that {{M|1=a+b=b+a}} (addition is [[commutative]]) | ||
+ | #* As {{M|\vert\cdot\vert:\mathbb{R}\rightarrow\mathbb{R} }} is a [[function]] we know that if {{M|1=x=y}} then {{M|1=\vert x\vert=\vert y\vert}} | ||
+ | #* As, again, {{M|\mathbb{R} }} is a ring, we know that {{M|1=\vert a\vert+\vert b\vert=\vert b\vert+\vert a\vert}} | ||
+ | #* So: | ||
+ | #** {{M|1=\vert a+b\vert}} | ||
+ | #**: {{M|1= =\vert b+a\vert}} by the [[Commutative|commutativity]] of addition on {{M|\mathbb{R} }} | ||
+ | #**: {{M|1=\le \vert b\vert+\vert a\vert}} by the {{M|2^\text{nd} }} case (above) | ||
+ | #**: {{M|1= =\vert a\vert+\vert b\vert}} again by commutativity of the real numbers | ||
+ | #* Thus {{M|\vert a+b\vert\le \vert a\vert+\vert b\vert}} | ||
+ | # Both {{M|a\le 0}} and {{M|b\le 0}} | ||
+ | {{Todo|Finish proof}} | ||
==Reverse Triangle Inequality== | ==Reverse Triangle Inequality== |
Revision as of 16:57, 28 August 2015
The triangle inequality takes a few common forms, for example: d(x,z)≤d(x,y)+d(y,z)
Another common way of writing it is |a+b|≤|a|+|b|
Contents
[hide]Definition
The triangle inequality is as follows:
- |a+b|≤|a|+|b|
Proof
We have 4 cases:
- Suppose that a>0 and b>0
- We see immediately that a>0⟹a+b>0+b=b>0 so a+b>0
- thus |a+b|=a+b
- We also see that |a|=a as a>0
- and that |b|=b for the same reason.
- thus |a|+|b|=a+b
- We see that |a+b|=|a|+|b|
- Notice |a+b|=|a|+|b|⟹|a+b|≤|a|+|b| in the literal sense of "if left then right"
- (⟹ denotes logical implication)
- Notice |a+b|=|a|+|b|⟹|a+b|≤|a|+|b| in the literal sense of "if left then right"
- We see immediately that a>0⟹a+b>0+b=b>0 so a+b>0
- Suppose that a>0 and b≤0
- Suppose that a≤0 and b>0
- Mathematicians are lazy, as R is a field (an instance of a ring) we know that a+b=b+a (addition is commutative)
- As |⋅|:R→R is a function we know that if x=y then |x|=|y|
- As, again, R is a ring, we know that |a|+|b|=|b|+|a|
- So:
- |a+b|
- =|b+a| by the commutativity of addition on R
- ≤|b|+|a| by the 2nd case (above)
- =|a|+|b| again by commutativity of the real numbers
- |a+b|
- Thus |a+b|≤|a|+|b|
- Both a≤0 and b≤0
TODO: Finish proof
Reverse Triangle Inequality
This is |a|−|b|≤|a−b|
Proof
Take |a|=|(a−b)+b|
|(a−b)+b|≤|a−b|+|b|
Note
However we see |b|−|a|≤|b−a|
That is both:
- |a|−|b|≤|a−b|
- |b|−|a|≤|a−b|
Full form
There is a "full form" of the reverse triangle inequality, it combines the above and looks like: |a−b|≥| |a|−|b| |
It follows from the properties of absolute value, I don't like this form, I prefer just "swapping" the order of things in the abs value and applying the same result