\(A=\dfrac{4sin^4x-cos^2x\left(1-cos^2x\right)+sin^2x.cos^2x-2cos^2x}{sin^2x}+\dfrac{2}{tan^2x}\)
\(=\dfrac{4sin^4x-sin^2x.cos^2x+sin^2x.cos^2x-2cos^2x}{sin^2x}+2cot^2x\)
\(=4sin^2x-2cot^2x+2cot^2x=4sin^2x\)
\(\Rightarrow\left\{{}\begin{matrix}a=4\\b=2\end{matrix}\right.\)