While I was reading about Bessaga's converse to Banach's fixed-point theorem, I found this lecture on the internet. But I had a doubt over here.
Let $f : X \to X $ given by $f(x)=x^3$ where $X=(-1,1)$, clearly this function has a unique fixed point in the given domain and every iterate $f^n$ of $f$ also has the same unique fixed point. So by Bessaga's theorem we know that there exists a metric $d$ on $X$ such that $f$ is a contraction map on $(X,d)$. The speaker in the above lecture tells us that $ d(x,y)= \left| \frac{1}{\ln x}-\frac{1}{\ln y}\right| $ is an example of a metric on $X$ with respect to which $f$ is a contraction map. But as $\ln x$ is not defined for $x<0$, I couldn't understand how is $d$ specified as above a metric on $X$ ?
Any help would be great! Thank you!
Edit : I am still not quite sure how $ d(x,y)= \left| \frac{1}{\ln x}-\frac{1}{\ln y}\right| $ is a metric on $X$, but I think if we define $ D : X \times X \to [ 0, \infty ) $ by $$ D(x,y) = \left| \frac{ sgn{(x)} }{ \ln{|x|} } - \frac{ sgn{(y)}}{ \ln{|y|} } \right| $$ Then $D$ is a metric on $X$ with respect to which $f$ is a contraction map. Is this correct ?