Set \(g(x)=\ln(x)\) and \(h(x)=x-1\text{.}\) Both functions are continuous on \([1,\infty)\) and differentiable on \((1,\infty)\text{.}\)
We take the derivative of each function:
\begin{equation*}
g'(x)=\frac{1}{x},
\end{equation*}
\begin{equation*}
h'(x)=1.
\end{equation*}
Since “\(x\ge1\)” and “\(\frac1x\le1\)” are equivalent statements, we thus have \(g'(x)\leq h'(x)\) for all \(x\geq 1\text{.}\)
Comparing function values when \(x=1\text{,}\) we see that \(g(1)=\ln(1)=0\) and \(h(1)=1-1=0\text{.}\) Therefore the racetrack principle says \(g(x)\leq h(x)\) (i.e. \(\ln(x)\leq x-1 \)) for all \(x\geq 1\text{.}\)
Similarly, if we consider values \(0\lt x \leq 1\text{,}\) we have that \(g'(x)\geq
h'(x)\text{.}\) Since \(g(1)=h(1)\text{,}\) we have that \(h(x)\geq g(x)\) or \(x-1\geq
\ln(x)\) for all \(0\lt x\leq 1\text{.}\) Note that we have to be careful in applying the racetrack principle here, since \(\ln(x)\) is not continuous (because it’s undefined) at \(x=0\text{.}\) But we can choose the lower bound of the interval to be any positive number less than \(1\text{,}\) and then take the limit as that number approaches \(0\) to obtain the result.