It is known that
$$\dfrac{d}{dx}\log f(x) = \dfrac{1}{f(x)} f'(x)$$
but how does it is not applicable for $\log |x|$ as $|x|$ is not differentiable?
It is known that
$$\dfrac{d}{dx}\log f(x) = \dfrac{1}{f(x)} f'(x)$$
but how does it is not applicable for $\log |x|$ as $|x|$ is not differentiable?
On
Since $\log(|x|)$ is not defined at $x=0$, we may investigate the differentiability for $x\not=0$. We distinguish two cases depending on the sign of $x$.
For $x>0$, we know that $|x|=x$ and $$\frac{d}{dx}\left(\log(|x|)\right)=\frac{d}{dx}\left(\log(x)\right)=\frac{1}{x}.$$ On the other hand, for $x<0$, we have that $|x|=-x$ and therefore $$\frac{d}{dx}\left(\log(|x|)\right)=\frac{d}{dx}\left(\log(-x)\right)=\frac{1}{(-x)}\cdot (-1)=\frac{1}{x}.$$ So we may conclude that $\log(|x|)$ is differentiable for $x\not=0$, and its derivative is $$\frac{d}{dx}\left(\log(|x|)\right)=\frac{1}{x}.$$
On
For non-zero x, we could still use the formula $\frac{d}{dx}\log f(x)=\frac{f'(x)}{f(x)}$ Since $f'(x)=\begin{cases}1&x>0\\-1&x<0\end{cases}$ for $f(x)=|x|$ so $\frac{d}{dx}\log |x|=\begin{cases}\frac{1}{|x|}&x>0\\\frac{-1}{|x|}&x<0\end{cases}=\frac{1}{x}$ given $x\neq 0$
On
First things first, no expression will work at $x=0$, since $\log|x|$ is not defined there. Also, $|x|$ is differentiable everywhere except at $x=0$, so things should work fin elsewhere.
It's often easier to work with $|x|$ as a piecewise-defined function, so:
Long story short, $$f'(x) = \frac{1}{x}, x \neq 0$$
$\frac d {dx} \log|x|=\frac 1 x$ if $x \neq0$ but the derivative at $0$ does not even makes sense since the function is not defined at $0$.