Differentiate $f(x)=\dfrac{\sin^2(3x)}{2x}$ Consider following function

$$ f(x) =
\begin{cases}
\dfrac{\sin^2(3x)}{2x},  & x\neq0 \\
0, & x=0
\end{cases}$$

Evaluate $f'(0)$.

Is this function differentiable  at $x=0$ ?

Take the derivative first, using the quotient rule:
$$\frac{d}{dx}\left(\frac{\sin^2(3x)}{2x}\right)=\frac{2x\cdot2\sin(3x)\cdot\cos(3x)\cdot3-\sin^2(3x)\cdot2}{4x^2}$$
Then we need to take the limit as x approaches 0 of this expression:
$$\lim_{x\rightarrow 0} \frac{2x\cdot2\sin(3x)\cdot\cos(3x)\cdot3-\sin^2(3x)\cdot2}{4x^2}$$
If we directly plug in the numbers, we find a fraction of the form $\frac{0}{0}$, which is a case in which we can use L'Hospital's Rule:$\frac{f}{g}\rightarrow\frac{f'}{g'}$.
So now we differentiate the top and bottom independently:
$$\lim_{x\rightarrow 0} \frac{2x\cdot2\sin(3x)\cdot\cos(3x)\cdot3-\sin^2(3x)\cdot2}{4x^2}=
\lim_{x\rightarrow 0} \frac{12\sin(3x)\cos(3x)+36x\cos^2(3x)-36\sin^2(3x)-12\sin(3x)\cos(3x)}{8x}$$
This form is again $\frac{0}{0}$, so we need to apply L'Hospital's Rule again:
$$\lim_{x\rightarrow 0} \frac{36x\cos^2(3x)-36\sin^2(3x)}{8x}=
\lim_{x\rightarrow 0} \frac{36\cos^2(3x)-72\cos(3x)\sin(3x)3-72\sin(3x)\cos(3x)3}{8}
$$
This final form removes the $0$ in the denominator, so we can now evaluate the left and right-hand sides of the limit.
$$\lim_{x\rightarrow 0} \frac{36\cos^2(3x)-432\cos(3x)\sin(3x)}{8}=
\lim_{x\rightarrow 0} \frac{9\cos^2(3x)-108\cos(3x)\sin(3x)}{2}$$
$$\rightarrow_{x\rightarrow0^+}\frac{9\cos^2(3\cdot0^+)-108\cos(3\cdot0^+)\sin(3\cdot0^+)}{2}=
\frac{9\cos^2(0^+)-108\cos(0^+)\sin(0^+)}{2}=\frac{9\cdot1-108\cdot1\cdot0^+}{2}=\frac{9}{2}
$$
$$\rightarrow_{x\rightarrow0^-}\frac{9\cos^2(3*0^-)-108\cos(3\cdot0^-)\sin(3\cdot0^-)}{2}=
\frac{9\cos^2(0^-)-108\cos(0^-)\sin(0^-)}{2}=\frac{9\cdot1-108\cdot1\cdot0^-}{2}=\frac{9}{2}
$$
Therefore, the limit does exist. It approaches $\frac{9}{2}$ from below on the right, and from above on the left.
Since the derivative at $0$ is $0$, the derivative does not exist.
