Find $\int\sqrt{\sin x+\cos x}\,dx $ I am trying to solve the question
$$
\int\sqrt{\sin x+\cos x}\,dx
$$
Is their any substitution by which I can get the answer.  I tried different substitution like i multiplied both numerator and denominator by $\sqrt{\sin x+\cos x} $ and uses sinx -cos x=t but getting complicated
 A: Elliptic Integral of the Second Kind:
$$E(\varphi,k) = \int_0^\varphi \sqrt {1 - k^2(\sin\vartheta)^2}\, \mathrm d\vartheta$$

$$ I = \int \sqrt{\sin(x) + \cos(x)}\,dx$$
$$\sqrt[4]{2}\int \sqrt{\frac{1}{\sqrt{2}}\sin(x) + \frac{1}{\sqrt{2}}\cos(x)}\,dx$$
$$\sqrt[4]{2}\int \sqrt{\sin(x)\cos\left(\frac{\pi}{4}\right) + \cos(x)\sin\left(\frac{\pi}{4}\right)}\,dx$$
Set $u = \left(x + \frac{\pi}{4}\right) \to du = dx$
$$\sqrt[4]{2}\int \sqrt{\sin(u)}\,du$$
So the elliptic integral can also be written as
$$\int \sqrt{\sin(u)}\,du = \int \sqrt{1 - 2\sin^2\left(\frac{\pi}{4}-\frac{\pi}{2}\right)}\,du$$
$$-2\int\sqrt{1-2\sin^2(u)}$$
$$-2\,E(u\,|\,2) + C$$
$$-2\,E\left(\frac{\pi}{4} - \frac{u}{2}\,|\,2\right) + C$$
Back substitution $u = \left(x + \frac{\pi}{4}\right)$
$$-2\,E\left(\frac{\pi}{4} - \frac{\left(x + \frac{\pi}{4}\right)}{2}\,|\,2\right) + C$$
$$-2\,E\left(\frac{\pi}{8} - \frac{x}{2}\,|\,2\right) + C$$
$$-2\,E\left(\frac{1}{8}\left(\pi - 4x\right)\,|\,2\right) + C$$
Therefore

$$I = -2\sqrt[4]{2}\,E\left(\frac{1}{8}(\pi - 4x)\,|\,2\right) + C$$

A: $$I=\int\sqrt{\sin(x)+\cos(x)}dx$$
let: $$\sin(x)+\cos(x)=R\sin(x+a)$$
$$\sin(x)+\cos(x)=R\sin(x)\cos(a)+R\cos(x)\sin(a)$$
so:
$R\cos(a)=1$ and $R\sin(a)=1 \, \therefore \tan(a)=1$ and $R^2=2$
we then get: $R=\sqrt{2}$ and $a=\frac{\pi}{4}$
the integral can now be rewritten as:
$$I=\int\sqrt{\sqrt{2}\sin\left(x+\frac{\pi}{4}\right)}dx=2^\frac{1}{4}\int\sqrt{\sin\left(x+\frac{\pi}{4}\right)}dx$$
let $u=x+\frac{\pi}{4} \,\therefore\,du=dx$
$$I=2^\frac{1}{4}\int\sqrt{\sin(u)}du$$
then this has no elementary solution but can be defined using the incomplete elliptic integral of the second kind.
