d2jsp
Log InRegister
d2jsp Forums > Off-Topic > General Chat > Homework Help > Metrics
Add Reply New Topic New Poll
Member
Posts: 167
Joined: Oct 2 2014
Gold: 0.00
Feb 22 2016 11:33pm


which of the above are metrics? i think all except the 1st one is a metric since the 1st does not satisfy d(x,y) = 0 <=> x=y
if any can confirm/correct my answer possibly with justification thatd be great. also willing to pay fg to whoever can help


also need help showing that


is a metric(mainly triangle inequality)

This post was edited by 2wo1ne on Feb 22 2016 11:56pm
Member
Posts: 16,662
Joined: Nov 24 2007
Gold: 15,245.00
Trader: Trusted
Feb 23 2016 02:42am
Correct.

Notice that the second and the third are the same :
max(x,y) - min(x,y) = x - y or y - x.
In both cases, after you square it, you get |x-y|².

For the last :
* it obviously gives a non-negative real,
* since t -> 1 / (1+t²) is a positive continuous function, the only way to have its integral being zero is when x1 = x2.
* obviously ρ(x1,x2) = ρ(x2,x1)
* for the triangle inequality, you can consider 2 cases :

if x ≤ y ≤ z (or if x ≥ y ≥ z ), you'd have ρ(x,z) = ρ(x,y) + ρ(y,z)

if y is not inbetween x and z, then :
ρ(x,z) ≤ ρ(x,y) if x < z < y or y < x < z
or, ρ(x,z) ≤ ρ(y,z) if y < x < z or z < x < y.
Member
Posts: 167
Joined: Oct 2 2014
Gold: 0.00
Feb 23 2016 01:03pm
Quote (feanur @ Feb 23 2016 04:42am)
Correct.

Notice that the second and the third are the same :
max(x,y) - min(x,y) = x - y or y - x.
In both cases, after you square it, you get |x-y|².

For the last :
* it obviously gives a non-negative real,
* since t -> 1 / (1+t²) is a positive continuous function, the only way to have its integral being zero is when x1 = x2.
* obviously ρ(x1,x2) = ρ(x2,x1)
* for the triangle inequality, you can consider 2 cases :

if x ≤ y ≤ z (or if x ≥ y ≥ z ), you'd have ρ(x,z) = ρ(x,y) + ρ(y,z)

if y is not inbetween x and z, then :
ρ(x,z) ≤ ρ(x,y) if x < z < y or y < x < z
or, ρ(x,z) ≤ ρ(y,z) if y < x < z or z < x < y.


Thanks! Also could u help with the triangle inequality for the max/min metric. Can pay more for ur help :)
Member
Posts: 16,662
Joined: Nov 24 2007
Gold: 15,245.00
Trader: Trusted
Feb 23 2016 01:53pm
I think I've read wrong.

Number 2
ρ (x,y) = ( max(x,y) - min(x,y) ) ²

and number 3
ρ (x,y) = | x-y | ²

which are the same, are not metrics :

ρ (0,2) = 4
ρ (0,1) = 1
ρ (1,2) = 1

hence, ρ(0,2) ≤ ρ(0,1) + ρ(1,2) doesn't stand.
This is due to the convexity of the function x ---> x²

(actually I've read |x² - y²|, I'm sorry)

Number 4, ρ (x,y) = √ | x-y |
satisfies the triangle inequality :
for every x, y, z in R, √ | x-z | ≤ √ | x-y | + √ | y-z |

Indeed, if | x-z | is lesser than | x-y | or than | y-z |, then it's obvious.
If it is greater than both, it implies that y is inbetween x and z.
We may assume : z < y < x.

Let's square both members.
On the left : x - z.
On the right : x - y + y - z + 2*√ ( x-y ) *√ ( y-z ) = x - z + 2*√ ... *√ ...
so the right member is obviously greater than the left member.
Member
Posts: 129,920
Joined: Oct 3 2006
Gold: 17,050.69
Feb 25 2016 06:49pm
what class is this? looks like some nice math concepts
Member
Posts: 167
Joined: Oct 2 2014
Gold: 0.00
Feb 27 2016 12:00pm
Quote (Duckling @ Feb 25 2016 08:49pm)
what class is this? looks like some nice math concepts


this is my class on general topology
Member
Posts: 129,920
Joined: Oct 3 2006
Gold: 17,050.69
Feb 27 2016 11:29pm
Quote (2wo1ne @ Feb 27 2016 01:00pm)
this is my class on general topology


ah i havent taken that class...

probably wont take one for quite a while if i even do tbh... i have a feeling ill be going more the computational/applied/statistical route.
Member
Posts: 12,427
Joined: Mar 4 2006
Gold: 5,077.00
Feb 28 2016 09:19am
Quote (Duckling @ Feb 28 2016 12:29am)
ah i havent taken that class...

probably wont take one for quite a while if i even do tbh... i have a feeling ill be going more the computational/applied/statistical route.



Unless you plan on going for a Ph.D. in math this is the way to go. General and advanced topology and a lot of other theory courses you take teach you some okay tricks and outside the box thinking techniques but not much is actually applicable in real life nor will it help you get a job.
Member
Posts: 129,920
Joined: Oct 3 2006
Gold: 17,050.69
Feb 28 2016 02:13pm
Quote (Xx Shin3d0wn xX @ Feb 28 2016 10:19am)
Unless you plan on going for a Ph.D. in math this is the way to go. General and advanced topology and a lot of other theory courses you take teach you some okay tricks and outside the box thinking techniques but not much is actually applicable in real life nor will it help you get a job.



Ya really kinda steers me away unfortunately because theoretical math is so cool though.
Go Back To Homework Help Topic List
Add Reply New Topic New Poll