(i) For u to be perpendicular to v, their dot product must be zero:
\(\mathbf{u} \cdot \mathbf{v} = p^2 \cdot 2 + (-2) \cdot (p-1) + 6 \cdot (2p+1) = 0\)
\(2p^2 - 2(p-1) + 6(2p+1) = 0\)
\(2p^2 - 2p + 2 + 12p + 6 = 0\)
\(2p^2 + 10p + 8 = 0\)
Factoring gives:
\((p+1)(p+4) = 0\)
Thus, \(p = -1\) or \(p = -4\).
(ii) For \(p = 1\), calculate the angle between u and v:
\(\mathbf{u} = \begin{pmatrix} 1 \\ -2 \\ 6 \end{pmatrix}, \mathbf{v} = \begin{pmatrix} 2 \\ 0 \\ 3 \end{pmatrix}\)
\(\mathbf{u} \cdot \mathbf{v} = 1 \cdot 2 + (-2) \cdot 0 + 6 \cdot 3 = 20\)
\(|\mathbf{u}| = \sqrt{1^2 + (-2)^2 + 6^2} = \sqrt{41}\)
\(|\mathbf{v}| = \sqrt{2^2 + 0^2 + 3^2} = \sqrt{13}\)
Using the dot product formula:
\(\cos \theta = \frac{\mathbf{u} \cdot \mathbf{v}}{|\mathbf{u}| |\mathbf{v}|} = \frac{20}{\sqrt{41} \times \sqrt{13}}\)
\(\theta = \cos^{-1}\left(\frac{20}{\sqrt{41} \times \sqrt{13}}\right) \approx 30.0^\circ\) or \(0.523 \text{ rads}\).