#### Show that $f(x)=2 x+\cot ^{-1} x+\log \left(\sqrt{1+x^{2}}-x\right)$ is increasing in R.

Given: $f(x)=2 x+\cot ^{-1} x+\log \left(\sqrt{1+x^{2}}-x\right)$

To show: the mentioned function increases in R

Explanation: Given $f(x)=2 x+\cot ^{-1} x+\log \left(\sqrt{1+x^{2}}-x\right)$

Substituting the first derivative in respect to x

$\\\mathrm{f}^{\prime}(\mathrm{x})=\frac{\mathrm{d}\left(2 \mathrm{x}+\cot ^{-1} \mathrm{x}+\log \left(\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}\right)\right)}{\mathrm{dx}}\\ \mathrm{f}^{\prime}(\mathrm{x})=\frac{\mathrm{d}(2 \mathrm{x})}{\mathrm{dx}}+\frac{\mathrm{d}\left(\cot ^{-1} \mathrm{x}\right)}{\mathrm{dx}}+\frac{\mathrm{d}\left(\log \left(\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}\right)\right)}{\mathrm{dx}}$
But the derivative of 2x is 2,so
$\mathrm{f}^{\prime}(\mathrm{x})=2+\frac{\mathrm{d}\left(\cot ^{-1} \mathrm{x}\right)}{\mathrm{dx}}+\frac{\mathrm{d}\left(\log \left(\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}\right)\right)}{\mathrm{dx}}$

But the derivative of $\cot ^{-1} \mathrm{x}=-\frac{1}{\mathrm{x}^{2}+1}$,so

$\\ \mathrm{f}^{\prime}(\mathrm{x})=2+\left(-\frac{1}{\mathrm{x}^{2}+1}\right)+\frac{\mathrm{d}\left(\log \left(\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}\right)\right)}{\mathrm{dx}}\\ f^{\prime}(x)=2+\left(-\frac{1}{x^{2}+1}\right)+\frac{1}{\sqrt{1+x^{2}}-x} \cdot \frac{d\left(\sqrt{1+x^{2}}-x\right)}{d x}$

When the sum rule is applied to the last part we get,

$\\ \mathrm{f}^{\prime}(\mathrm{x})=2+\left(-\frac{1}{\mathrm{x}^{2}+1}\right)+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{\mathrm{d}\left(\sqrt{1+\mathrm{x}^{2}}\right)}{\mathrm{dx}}-\frac{\mathrm{d}(\mathrm{x})}{\mathrm{dx}}\right) \\ \mathrm{f}^{\prime}(\mathrm{x})=2+\left(-\frac{1}{\mathrm{x}^{2}+1}\right)+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{\mathrm{d}\left(\left(1+\mathrm{x}^{2}\right)^{\frac{1}{2}}\right)}{\mathrm{dx}}-1\right) \\ \mathrm{f}^{\prime}(\mathrm{x})=2+\left(-\frac{1}{\mathrm{x}^{2}+1}\right)+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{1}{2} \cdot\left(1+\mathrm{x}^{2}\right)^{\frac{1}{2}-1} \cdot \frac{\mathrm{d}\left(1+\mathrm{x}^{2}\right)}{\mathrm{d} \mathrm{x}}-1\right) \\$

$\\\mathrm{f}^{\prime}(\mathrm{x})=2+\left(-\frac{1}{\mathrm{x}^{2}+1}\right)+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{1}{2} \cdot\left(1+\mathrm{x}^{2}\right)^{-\frac{1}{2}} \cdot\left[\frac{\mathrm{d}(1)}{\mathrm{d} \mathrm{x}}+\frac{\mathrm{d}\left(\mathrm{x}^{2}\right)}{\mathrm{d} \mathrm{x}}\right]-1\right) \\ \mathrm{f}^{\prime}(\mathrm{x})=2+\left(-\frac{1}{\mathrm{x}^{2}+1}\right)+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{1}{2 \sqrt{1+\mathrm{x}^{2}}} \cdot[0+2 \mathrm{x}]-1\right) \\ \mathrm{f}^{\prime}(\mathrm{x})=2+\left(-\frac{1}{\mathrm{x}^{2}+1}\right)+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{2 \mathrm{x}}{2 \sqrt{1+\mathrm{x}^{2}}}-1\right)$

$\\ \mathrm{f}^{\prime}(\mathrm{x})=2-\frac{1}{\mathrm{x}^{2}+1}+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{\mathrm{x}}{\sqrt{1+\mathrm{x}^{2}}}-1\right) \\\\\mathrm{f}^{\prime}(\mathrm{x})=2-\frac{1}{\mathrm{x}^{2}+1}+\frac{1}{\sqrt{1+\mathrm{x}^{2}}-\mathrm{x}}\left(\frac{\mathrm{x}-\sqrt{1+\mathrm{x}^{2}}}{\sqrt{1+\mathrm{x}^{2}}}\right) \\Cutting out all the like terms, \mathrm{f}^{\prime}(\mathrm{x})=2-\frac{1}{\mathrm{x}^{2}+1}+\frac{-1}{\sqrt{1+\mathrm{x}^{2}}} \\Then, adding by taking the LCM, we get \\\mathrm{f}^{\prime}(\mathrm{x})=\frac{2+2 \mathrm{x}^{2}-1-\sqrt{1+\mathrm{x}^{2}}}{\mathrm{x}^{2}+1}\\ \mathrm{f}^{\prime}(\mathrm{x})=\frac{2 \mathrm{x}^{2}+1-\sqrt{1+\mathrm{x}^{2}}}{\mathrm{x}^{2}+1}$

Then to calculate any real value x, the above value of f(x) is larger than or equal to zero

Hence $\frac{2 x^{2}+1-\sqrt{1+x^{2}}}{x^{2}+1} \forall x \in R$

And we know, if $f'(x)\geq 0$, then f(x) is increasing function.

Hence, the given function is an increasing function in R.