TITLE: Can $\int \frac{\sec x \ \mathrm{d}x}{\sqrt{\sin(x+2A)+\sin(A)}}$ be evaluated using elementary functions?
QUESTION [6 upvotes]: This question recently popped up on one of my tests and I still have no idea on how to even begin.
I tried assuming $\sin(x+2A)+\sin(A)=t^2$ which did not help at all.
Then I went on to multiply and divide by $\tan x$ to create a derivative on the numerator, still does not help.
I even tried to expand $\sin(x+2A)$ which too does not seem to follow.
I have also tried Approach$0$ and Wolfram Alpha  but they do not seem to help.
and many more...
Now I am stumped I have no idea as to how to even begin. I have tried everything that I could think of.
Note that we are only familiar with basics of integration(no contour integrals ; no special functions etc..)

$\bullet~\textbf{Question:}~$
"Can the above integral be evaluated in elementary functions?" If yes then how? If not , can we prove that it cannot be solved using elementary funcions?

REPLY [2 votes]: Not elementary at all
$$I=\int \frac{\sec (x)}{\sqrt{\sin(x+2a)+\sin(a)}}\,dx$$
$$\sin(x+2a)+\sin(a)=\sin (a)+\sin (2 a) \cos (x)+\cos (2 a) \sin (x)$$
Using the tangent half-angle substitution $x=2 \tan^{-1}(t)$
$$\sin(x+2a)+\sin(a)=\frac{(\sin (a)+\sin (2 a))+2 t \cos (2 a)+t^2 (\sin (a)-\sin (2 a))}{1+t^2}$$
$$(\sin (a)+\sin (2 a))+2 t \cos (2 a)+t^2 (\sin (a)-\sin (2 a))=$$
$$(\sin (a)-\sin (2 a))\left(t+\tan \left(\frac{3 a}{2}\right)\right) \left(t-\cot
   \left(\frac{a}{2}\right)\right)$$
Let
$$\alpha=\sin (a)+\sin (2 a)\qquad \beta=\tan \left(\frac{3 a}{2}\right) \qquad \gamma=\cot   \left(\frac{a}{2}\right)$$
$$I=\frac 2 \alpha \int \frac {\sqrt{1+t^2}} {(1-t^2)\sqrt{(t+\beta) (t-\gamma) }}\,dt$$
The result is given in terms of elliptic integrals (have a look here).
Edit
$$a=\frac \pi 4 \qquad \qquad \implies \qquad I=2 \sqrt{2-\sqrt{2}} \,\,\Pi \left(2;\frac{x}{2}|4-2 \sqrt{2}\right)$$