Evaluate the following integrals:
$\int \frac{x+1}{\sqrt{x+5 x-x^{2}}} d x$
Given $I=\int \frac{x+1}{\sqrt{4+5 x-x^{2}}} d x$
Integral is of form $\int \frac{p x+q}{\sqrt{a x^{2}+b x+c}} d x$
Writing numerator as $p x+q=\lambda\left\{\frac{d}{d x}\left(a x^{2}+b x+c\right)\right\}+\mu$
$\Rightarrow p x+q=\lambda(2 a x+b)+\mu$
$\Rightarrow x+1=\lambda(-2 x+5)+\mu$
$\therefore \lambda=-1 / 2$ and $\mu=7 / 2$
Let $x+1=-1 / 2(-2 x+5)+7 / 2$
$\Rightarrow \int \frac{x+1}{\sqrt{-x^{2}+5 x+4}} d x=\int\left(\frac{-2 x+5}{2 \sqrt{-x^{2}+5 x+4}}+\frac{7}{2 \sqrt{-x^{2}+5 x+4}}\right) d x$
$=\frac{1}{2} \int \frac{-2 x+5}{\sqrt{-x^{2}+5 x+4}} d x+\frac{7}{2} \int \frac{1}{\sqrt{-x^{2}+5 x+4}} d x$
Consider $\int \frac{-2 x+5}{\sqrt{-x^{2}+5 x+4}} d x$
Let $u=-x^{2}+5 x+4 \rightarrow d x=\frac{1}{-2 x+5} d u$
$\Rightarrow \int \frac{-2 x+5}{\sqrt{-x^{2}+5 x+4}} d x=-\int \frac{1}{\sqrt{u}} d u$
We know that $\int \mathrm{x}^{\mathrm{n}} \mathrm{dx}=\frac{\mathrm{x}^{\mathrm{n}+1}}{\mathrm{n}+1}+\mathrm{c}$
$\Rightarrow-\int \frac{1}{\sqrt{u}} d u=-(2 \sqrt{u})$
$=-2 \sqrt{x^{2}+6 x+10}$
Consider $\int \frac{1}{\sqrt{-\mathrm{x}^{2}+5 \mathrm{x}+4}} \mathrm{dx}$
$\Rightarrow \int \frac{1}{\sqrt{-x^{2}+5 x+4}} d x=\int \frac{1}{\sqrt{-\left(x-\frac{5}{2}\right)^{2}+\frac{41}{4}}} d x$
Let $\mathrm{u}=\frac{2 \mathrm{x}-5}{\sqrt{41}} \rightarrow \mathrm{dx}=\frac{\sqrt{41}}{2} \mathrm{du}$
$\Rightarrow \int \frac{1}{\sqrt{-\left(x-\frac{5}{2}\right)^{2}+\frac{41}{4}}} d x=\int \frac{\sqrt{41}}{\sqrt{41-41 u^{2}}} d u$
$=\int \frac{1}{\sqrt{1-u^{2}}} d u$
We know that $\int \frac{1}{\sqrt{1-x^{2}}} d x=\sin ^{-1}(x)+c$
$\Rightarrow \int \frac{1}{\sqrt{1-\mathrm{u}^{2}}} \mathrm{du}=\sin ^{-1}\left(\frac{2 \mathrm{x}-5}{\sqrt{41}}\right)$
Then,
$\Rightarrow \int \frac{x+1}{\sqrt{-x^{2}+5 x+4}} d x=\frac{1}{2} \int \frac{-2 x+5}{\sqrt{-x^{2}+5 x+4}} d x+\frac{7}{2} \int \frac{1}{\sqrt{-x^{2}+5 x+4}} d x$
$=-\sqrt{-x^{2}+5 x+4}+\frac{7}{2}\left(\sin ^{-1}\left(\frac{2 x-5}{\sqrt{41}}\right)\right)+c$
$\therefore \mathrm{I}=\int \frac{\mathrm{x}+1}{\sqrt{-\mathrm{x}^{2}+5 \mathrm{x}+4}} \mathrm{dx}=-\sqrt{-\mathrm{x}^{2}+5 \mathrm{x}+4}+\frac{7}{2}\left(\sin ^{-1}\left(\frac{2 \mathrm{x}-5}{\sqrt{41}}\right)\right)+\mathrm{c}$