1

I always get stuck at proving triangle's inequality when showing whether the function is metric distance .

Is there a better way to prove triangle's inequality. For example -

D(x,y)=|x-y|/(1+|x-y|) when x,y are in R

I am unable to prove triangle inequality for the above distance.

  • What do you mean by "trial and error" ? What did you try ? – Furrane Aug 20 '17 at 23:57
  • See https://math.stackexchange.com/questions/1145484/is-this-proof-sufficient-to-show-that-a-concave-function-of-a-metric-is-also-a-m – edm Aug 21 '17 at 00:48

1 Answers1

1

If $f$ is increasing and subadditive on $\mathbb R^+$, so $f(a+b)\le f(a)+f(b)$, then $f$ composed with a metric preserves the triangle inequality. Checking subadditivity of $f(x)=x/(1+x)$ is not very hard.

What I do first with such problems, however, is ask my computer to make 100 random points, and check all possible $100\cdot99\cdot98$ triangle inequality instances, numerically. This is a million checks, and if the proposed metric is in fact not a metric, I'll learn that fact quickly.

kimchi lover
  • 24,981