# Triangle inequality help

• June 22nd 2011, 02:06 AM
monster
Triangle inequality help
Hi following a problem on a past exam and have come across a step i can't follow with the triangle inequality,

| 5x - y + (xy.cos(y))/(x^1/2 + y^1/2) |

is

<= 5|x| + |y| + |x|.|y|.|cos(y)|/(x^1/2 + y ^1/2)
and says it's via the trianlge inequality if someone can explain why it would be great cheers.
• June 22nd 2011, 02:53 AM
Sudharaka
Re: Triangle inequality help
Quote:

Originally Posted by monster
Hi following a problem on a past exam and have come across a step i can't follow with the triangle inequality,

| 5x - y + (xy.cos(y))/(x^1/2 + y^1/2) |

is

<= 5|x| + |y| + |x|.|y|.|cos(y)|/(x^1/2 + y ^1/2)
and says it's via the trianlge inequality if someone can explain why it would be great cheers.

Dear monster,

The triangular inequality says for any two real numbers a,b;

$\mid a+b\mid\leq\mid a\mid+\mid b\mid$

Applying the triangular inequality, replacing $a\rightarrow{5x-y}\mbox{ and }b\rightarrow \frac{xy\cos(y)}{\sqrt{x}+\sqrt{y}}$

$\left|5x - y + \frac{xy\cos(y)}{\sqrt{x}+\sqrt{y}}\right|\leq \left|5x-y\right|+\left|\frac{xy\cos(y)}{\sqrt{x}+\sqrt{y}} \right|$

Applying the triangular inequality again for $\mid 5x-y\mid$;

$\left|5x - y + \frac{xy\cos(y)}{\sqrt{x}+\sqrt{y}}\right|\leq \left|5x-y\right|+\left|\frac{xy\cos(y)}{\sqrt{x}+\sqrt{y}} \right|\leq 5\mid x\mid+\mid y\mid+\left|\frac{xy\cos(y)}{\sqrt{x}+\sqrt{y}} \right|$

$\mid\sqrt{x}+\sqrt{y}\mid=\sqrt{x}+\sqrt{y}\mbox{ since }\sqrt x>0\mbox{ and }\sqrt y>0~\forall~x,y\in \Re^+$

Therefore, $\left|5x - y + \frac{xy\cos(y)}{\sqrt{x}+\sqrt{y}}\right|\leq 5\mid x\mid+\mid y\mid+\frac{\mid x\mid\mid y\mid\mid\cos(y)\mid}{\sqrt{x}+\sqrt{y}}$
• June 22nd 2011, 03:09 AM
monster
Re: Triangle inequality help
yes, but when you re-apply for |5x - y| how does it work? it seems what you have written would work for |5x + y| but what about with the negative in there??
• June 22nd 2011, 03:19 AM
Sudharaka
Re: Triangle inequality help
Quote:

Originally Posted by monster
yes, but when you re-apply for |5x - y| how does it work? it seems what you have written would work for |5x + y| but what about with the negative in there??

In this case your a is 5x and your b is -y.

$\mid 5x-y\mid=\mid 5x+(-y)\mid \leq\mid 5x\mid+\mid -y\mid\leq 5\mid x\mid+\mid y\mid~;\mbox{ since }\mid-y\mid=\mid y\mid$