Find the absolute maximum and absolute minimum values of $f(t) = 4 \cos t + 2 \sin 2 t$ on the interval $\left[0,\frac{\pi}{2}\right].$

1. Find the absolute maximum of $f$ on the interval.
2. Find the absolute minimum of $f$ on the interval.