3.15 \(\int \frac {\sin (2 x)}{a^2-b^2 \sin ^2(x)} \, dx\)

Optimal. Leaf size=19 \[ -\frac {\log \left (a^2-b^2 \sin ^2(x)\right )}{b^2} \]

________________________________________________________________________________________

Rubi [A]  time = 0.04, antiderivative size = 19, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {12, 260} \[ -\frac {\log \left (a^2-b^2 \sin ^2(x)\right )}{b^2} \]

Antiderivative was successfully verified.

[In]

Int[Sin[2*x]/(a^2 - b^2*Sin[x]^2),x]

[Out]

-(Log[a^2 - b^2*Sin[x]^2]/b^2)

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 260

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rubi steps

\begin {align*} \int \frac {\sin (2 x)}{a^2-b^2 \sin ^2(x)} \, dx &=\operatorname {Subst}\left (\int \frac {2 x}{a^2-b^2 x^2} \, dx,x,\sin (x)\right )\\ &=2 \operatorname {Subst}\left (\int \frac {x}{a^2-b^2 x^2} \, dx,x,\sin (x)\right )\\ &=-\frac {\log \left (a^2-b^2 \sin ^2(x)\right )}{b^2}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 19, normalized size = 1.00 \[ -\frac {\log \left (a^2-b^2 \sin ^2(x)\right )}{b^2} \]

Antiderivative was successfully verified.

[In]

Integrate[Sin[2*x]/(a^2 - b^2*Sin[x]^2),x]

[Out]

-(Log[a^2 - b^2*Sin[x]^2]/b^2)

________________________________________________________________________________________

IntegrateAlgebraic [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\sin (2 x)}{a^2-b^2 \sin ^2(x)} \, dx \]

Verification is Not applicable to the result.

[In]

IntegrateAlgebraic[Sin[2*x]/(a^2 - b^2*Sin[x]^2),x]

[Out]

Could not integrate

________________________________________________________________________________________

fricas [A]  time = 1.10, size = 23, normalized size = 1.21 \[ -\frac {\log \left (b^{2} \cos \relax (x)^{2} + a^{2} - b^{2}\right )}{b^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(2*x)/(a^2-b^2*sin(x)^2),x, algorithm="fricas")

[Out]

-log(b^2*cos(x)^2 + a^2 - b^2)/b^2

________________________________________________________________________________________

giac [A]  time = 0.93, size = 21, normalized size = 1.11 \[ -\frac {\log \left ({\left | b^{2} \sin \relax (x)^{2} - a^{2} \right |}\right )}{b^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(2*x)/(a^2-b^2*sin(x)^2),x, algorithm="giac")

[Out]

-log(abs(b^2*sin(x)^2 - a^2))/b^2

________________________________________________________________________________________

maple [A]  time = 0.27, size = 20, normalized size = 1.05




method result size



derivativedivides \(-\frac {\ln \left (a^{2}-b^{2} \left (\sin ^{2}\relax (x )\right )\right )}{b^{2}}\) \(20\)
default \(-\frac {\ln \left (a^{2}-b^{2} \left (\sin ^{2}\relax (x )\right )\right )}{b^{2}}\) \(20\)
risch \(\frac {2 i x}{b^{2}}-\frac {\ln \left ({\mathrm e}^{4 i x}+\frac {2 \left (2 a^{2}-b^{2}\right ) {\mathrm e}^{2 i x}}{b^{2}}+1\right )}{b^{2}}\) \(43\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(2*x)/(a^2-b^2*sin(x)^2),x,method=_RETURNVERBOSE)

[Out]

-ln(a^2-b^2*sin(x)^2)/b^2

________________________________________________________________________________________

maxima [A]  time = 0.43, size = 20, normalized size = 1.05 \[ -\frac {\log \left (b^{2} \sin \relax (x)^{2} - a^{2}\right )}{b^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(2*x)/(a^2-b^2*sin(x)^2),x, algorithm="maxima")

[Out]

-log(b^2*sin(x)^2 - a^2)/b^2

________________________________________________________________________________________

mupad [B]  time = 0.49, size = 48, normalized size = 2.53 \[ \frac {\mathrm {atan}\left (\frac {b^2\,{\sin \relax (x)}^2}{a^2\,{\cos \relax (x)}^2\,2{}\mathrm {i}+a^2\,{\sin \relax (x)}^2\,2{}\mathrm {i}-b^2\,{\sin \relax (x)}^2\,1{}\mathrm {i}}\right )\,2{}\mathrm {i}}{b^2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-sin(2*x)/(b^2*sin(x)^2 - a^2),x)

[Out]

(atan((b^2*sin(x)^2)/(a^2*cos(x)^2*2i + a^2*sin(x)^2*2i - b^2*sin(x)^2*1i))*2i)/b^2

________________________________________________________________________________________

sympy [A]  time = 3.32, size = 34, normalized size = 1.79 \[ 2 \left (\begin {cases} - \frac {\cos ^{2}{\relax (x )}}{2 a^{2}} & \text {for}\: b^{2} = 0 \\- \frac {\log {\left (a^{2} - b^{2} \sin ^{2}{\relax (x )} \right )}}{2 b^{2}} & \text {otherwise} \end {cases}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(2*x)/(a**2-b**2*sin(x)**2),x)

[Out]

2*Piecewise((-cos(x)**2/(2*a**2), Eq(b**2, 0)), (-log(a**2 - b**2*sin(x)**2)/(2*b**2), True))

________________________________________________________________________________________