How is $\frac{\sin^2x}{\cos^2x+1}=\frac{\tan^2x}{1+\sec^2x}$?
Solution 1:
For $\cos x \ne 0$, $$\frac{\sin^2x}{\cos^2x+1}=\frac{\dfrac{\sin^2x}{\cos^2x}}{\dfrac{\cos^2x}{\cos^2x}+\dfrac1{\cos^2x}}=\dfrac{\tan^2x}{1+\sec^2x}$$
For $\cos x \ne 0$, $$\frac{\sin^2x}{\cos^2x+1}=\frac{\dfrac{\sin^2x}{\cos^2x}}{\dfrac{\cos^2x}{\cos^2x}+\dfrac1{\cos^2x}}=\dfrac{\tan^2x}{1+\sec^2x}$$