Find $\int \frac{x^2}{(x \cos x - \sin x)(x \sin x + \cos x)}dx $ Find $$\int \frac{x^2}{(x \cos x - \sin x)(x \sin x + \cos x)}dx $$
Any hints please?
Could'nt think of any approach till now...

Let $$I = \int\frac{x^2}{(x\sin x+\cos x)\cdot (x\cos x-\sin x)}dx$$
$\displaystyle \bullet\;\;  x\sin x+1\cdot \cos x = \sqrt{x^2+1}\left[\sin x\cdot \frac{x}{\sqrt{1+x^2}}+\cos x\cdot \frac{1}{\sqrt{1+x^2}}\right]$
$$=\sqrt{x^2+1}\sin \left(x+\alpha\right)$$
Where $\displaystyle \cot \alpha = x\Rightarrow \alpha = \cot^{-1}(x) = \frac{\pi}{2}-\tan^{-1}(x)$
$\displaystyle \bullet\;\;  x\cos x-1\cdot \sin x = -\sqrt{x^2+1}\left[\sin x\cdot \frac{1}{\sqrt{1+x^2}}-\cos x\cdot \frac{x}{\sqrt{1+x^2}}\right]$
$$=-\sqrt{x^2+1}\sin \left(x-\beta\right)$$
Where $\tan \beta = x\Rightarrow \beta = \tan^{-1}(x)$
So $$I = -\int\frac{1}{1\cos(x- \tan^{-1}{x})\cdot \sin (x-\tan^{-1}(x))}\cdot \frac{1}{1+x^2}dx$$
Now Put $x-\tan^{-}(x)=t\;,$ Then $\displaystyle \frac{1}{1+x^2}dx = dt$
So $$I = -\int\frac{\sin^2 t+\cos^2 t}{\sin t \cdot \cos t }dt = -\int \tan t dt-\int \cot t dt$$
So $$I = \ln |\cos t|-\ln |\sin t|+\mathcal{C} = -\ln |\tan t|+\mathcal{C}$$
So $$I =-\ln \left|\tan \left(x-\tan^{-x}(x)\right)\right|+\mathcal{C} = -\ln \left|\frac{\tan x-x}{1+x\tan x}\right|+\mathcal{C}$$
So $$I = \ln \left|\frac{\cos x+x\sin x}{\sin x-x\cos x}\right|+\mathcal{C}$$
