Step 1: Understand the behavior of \( f(x) \) near \( x = \frac{\pi}{2} \).
The function \( f(x) = | \cos x | \) can be expressed as:
\[
f(x) =
\begin{cases}
\cos x, & \text{if } \cos x \geq 0,
-\cos x, & \text{if } \cos x<0.
\end{cases}
\]
At \( x = \frac{\pi}{2} \), \( \cos \left( \frac{\pi}{2} \right) = 0 \). To check differentiability, evaluate the left-hand derivative (LHD) and right-hand derivative (RHD).
Step 2: Calculate the left-hand derivative (LHD).
For \( x<\frac{\pi}{2} \), \( \cos x \geq 0 \), so:
\[
f(x) = \cos x, \quad \text{and} \quad f'(x) = -\sin x.
\]
At \( x = \frac{\pi}{2} \), the left-hand derivative is:
\[
\lim_{h \to 0^-} \frac{f\left( \frac{\pi}{2} + h \right) - f\left( \frac{\pi}{2} \right)}{h} = -\sin\left( \frac{\pi}{2} \right) = -1.
\]
Step 3: Calculate the right-hand derivative (RHD).
For \( x>\frac{\pi}{2} \), \( \cos x<0 \), so:
\[
f(x) = -\cos x, \quad \text{and} \quad f'(x) = \sin x.
\]
At \( x = \frac{\pi}{2} \), the right-hand derivative is:
\[
\lim_{h \to 0^+} \frac{f\left( \frac{\pi}{2} + h \right) - f\left( \frac{\pi}{2} \right)}{h} = \sin\left( \frac{\pi}{2} \right) = 1.
\]
Step 4: Conclusion.
Since the left-hand and right-hand derivatives are not equal (\(-1 \neq 1\)), the function \( f(x) = |\cos x| \) is not differentiable at \( x = \frac{\pi}{2} \).
Final Answer:
\[
\boxed{\text{The function } f(x) = |\cos x| \text{ is not differentiable at } x = \frac{\pi}{2}.}
\]