# Antiderivative of a rational trigonometric function

I'm looking for some help in solving the following integral:

$$\int{\frac{\sin^2(\theta)}{\sqrt{\cos^2(\theta)+A}}}d\theta$$

I've seen some similar cases with elliptical integrals, but even in this case, I couldn't solve the antiderivative above. It would be great to solve it analytically, but any help is appreciated.

A bit of softening up first: $$\frac{\sin^2x}{\sqrt{\cos^2x+A}}=\frac1{\sqrt{1+A}}\frac{\sin^2x}{\sqrt{1-\frac1{1+A}\sin^2x}}$$ Then, by Byrd and Friemdan 281.01, $$\int_0^\varphi\frac{\sin^2x}{\sqrt{\cos^2x+A}}\,dx=\frac1{\sqrt{1+A}}\int_0^\varphi\frac{\sin^2x}{\sqrt{1-\frac1{1+A}\sin^2x}}\,dx$$ $$=\frac1{\sqrt{1+A}}\int_0^{F(\varphi,m=1/(1+A))}\operatorname{sn}^2u\,du$$ By B&F 310.02 this in turn evaluates as $$\frac1{\sqrt{1+A}}\cdot\frac1{1/(1+A)}(F(\varphi,m)-E(\varphi,m))=\sqrt{1+A}(F(\varphi,m)-E(\varphi,m))$$
In some references like the DLMF, the difference $$F(\varphi,m)-E(\varphi,m)$$ is denoted in terms of a new function $$D(\varphi,m)$$: $$D(\varphi,m)\equiv\int_0^\varphi\frac{\sin^2x}{\sqrt{1-m\sin^2x}}\,dx=\frac1m(F(\varphi,m)-E(\varphi,m))$$ This is because the difference can be evaluated in one step (avoiding a subtraction) using the Carlson symmetric form as $$D(\varphi,m)=\frac{\sin^3\varphi}3R_D(\cos^2\varphi,1-m\sin^2\varphi,1)$$ The original integral expressed in this symmetric form is $$\int_0^\varphi\frac{\sin^2x}{\sqrt{\cos^2x+A}}\,dx=\frac1{\sqrt{1+A}}D\left(\varphi,\frac1{1+A}\right)$$ $$=\frac{\sin^3\varphi}{3\sqrt{1+A}}R_D\left(\cos^2\varphi,1-\frac1{1+A}\sin^2\varphi,1\right)\qquad|\varphi|\le\frac\pi2$$
• Thank you for you collaboration. Is there an analytical way to evaluate $F(\varphi,m)$ and $E(\varphi,m)$? If so, could you please provide a further reference so I can solve it? Dec 8, 2020 at 14:26
• Thank you Parcly. I have another question: I'm trying to evaluate an indefinite integral, so I'm not sure what this integration boundary $\varphi$ will represent. Sorry if this question is trivial, I've never worked with elliptical integrals before Dec 8, 2020 at 17:16
• @MateusForcelini $\varphi$ is simply the upper limit of the indefinite integral - it is indefinite, and the lower bound of indefinite integrals is usually understood as $0$. (Writing the bounds explicitly helps me avoid having to write the constant of integration.) Dec 8, 2020 at 18:43
$$\frac{\sin^2\theta}{\sqrt{\cos^2\theta+a}}=\frac{a+1}{\sqrt{\cos^2\theta+a}}-{\sqrt{\cos^2\theta+a}}$$ shows the decomposition in elliptic integrals of the first and second kind.