Trigonometric Functions

Prove that $\sqrt{\sec^2 \theta + \text{cosec}^2 \theta} = \tan \theta + \cot \theta$


$ \begin{aligned} \text{LHS} = \sqrt{\sec^2 \theta + \text{cosec}^2 \theta} & = \sqrt{\left(1+\tan^2 \theta\right) + \left(1 + \cot^2 \theta\right)} \\ & \left[\text{Note: }1+\tan^2 \theta = \sec^2 \theta; 1+\cot^2 \theta = \text{cosec}^2 \theta\right] \\ & = \sqrt{\tan^2 \theta + 2 + \cot^2 \theta} \\ & = \sqrt{\tan^2 \theta + 2 \tan \theta \cot \theta + \cot^2 \theta} \\ & \left[\text{Note: } \tan \theta \times \cot \theta = 1 \right] \\ & = \sqrt{\left(\tan \theta + \cot \theta\right)^2} \\ & = \tan \theta + \cot \theta = \text{RHS} \end{aligned} $