\(\int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx\) [110]

Optimal result
Mathematica [A] (verified)
Rubi [A] (warning: unable to verify)
Maple [A] (verified)
Fricas [C] (verification not implemented)
Sympy [F]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 23, antiderivative size = 104 \[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx=-\frac {a \sqrt {e} \arctan \left (\frac {\sqrt {e \sin (c+d x)}}{\sqrt {e}}\right )}{d}+\frac {a \sqrt {e} \text {arctanh}\left (\frac {\sqrt {e \sin (c+d x)}}{\sqrt {e}}\right )}{d}+\frac {2 a E\left (\left .\frac {1}{2} \left (c-\frac {\pi }{2}+d x\right )\right |2\right ) \sqrt {e \sin (c+d x)}}{d \sqrt {\sin (c+d x)}} \] Output:

-a*e^(1/2)*arctan((e*sin(d*x+c))^(1/2)/e^(1/2))/d+a*e^(1/2)*arctanh((e*sin 
(d*x+c))^(1/2)/e^(1/2))/d-2*a*EllipticE(cos(1/2*c+1/4*Pi+1/2*d*x),2^(1/2)) 
*(e*sin(d*x+c))^(1/2)/d/sin(d*x+c)^(1/2)
 

Mathematica [A] (verified)

Time = 0.26 (sec) , antiderivative size = 69, normalized size of antiderivative = 0.66 \[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx=\frac {a \left (-\arctan \left (\sqrt {\sin (c+d x)}\right )+\text {arctanh}\left (\sqrt {\sin (c+d x)}\right )-2 E\left (\left .\frac {1}{4} (-2 c+\pi -2 d x)\right |2\right )\right ) \sqrt {e \sin (c+d x)}}{d \sqrt {\sin (c+d x)}} \] Input:

Integrate[(a + a*Sec[c + d*x])*Sqrt[e*Sin[c + d*x]],x]
 

Output:

(a*(-ArcTan[Sqrt[Sin[c + d*x]]] + ArcTanh[Sqrt[Sin[c + d*x]]] - 2*Elliptic 
E[(-2*c + Pi - 2*d*x)/4, 2])*Sqrt[e*Sin[c + d*x]])/(d*Sqrt[Sin[c + d*x]])
 

Rubi [A] (warning: unable to verify)

Time = 0.57 (sec) , antiderivative size = 97, normalized size of antiderivative = 0.93, number of steps used = 17, number of rules used = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.696, Rules used = {3042, 4360, 25, 25, 3042, 3317, 3042, 3044, 27, 266, 827, 216, 219, 3121, 3042, 3119}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int (a \sec (c+d x)+a) \sqrt {e \sin (c+d x)} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \left (a-a \csc \left (c+d x-\frac {\pi }{2}\right )\right ) \sqrt {e \cos \left (c+d x-\frac {\pi }{2}\right )}dx\)

\(\Big \downarrow \) 4360

\(\displaystyle \int -\left (\sec (c+d x) (a (-\cos (c+d x))-a) \sqrt {e \sin (c+d x)}\right )dx\)

\(\Big \downarrow \) 25

\(\displaystyle -\int -\left ((\cos (c+d x) a+a) \sec (c+d x) \sqrt {e \sin (c+d x)}\right )dx\)

\(\Big \downarrow \) 25

\(\displaystyle \int \sec (c+d x) (a \cos (c+d x)+a) \sqrt {e \sin (c+d x)}dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\left (a \sin \left (c+d x+\frac {\pi }{2}\right )+a\right ) \sqrt {-e \cos \left (c+d x+\frac {\pi }{2}\right )}}{\sin \left (c+d x+\frac {\pi }{2}\right )}dx\)

\(\Big \downarrow \) 3317

\(\displaystyle a \int \sqrt {e \sin (c+d x)}dx+a \int \sec (c+d x) \sqrt {e \sin (c+d x)}dx\)

\(\Big \downarrow \) 3042

\(\displaystyle a \int \sqrt {e \sin (c+d x)}dx+a \int \frac {\sqrt {e \sin (c+d x)}}{\cos (c+d x)}dx\)

\(\Big \downarrow \) 3044

\(\displaystyle \frac {a \int \frac {e^2 \sqrt {e \sin (c+d x)}}{e^2-e^2 \sin ^2(c+d x)}d(e \sin (c+d x))}{d e}+a \int \sqrt {e \sin (c+d x)}dx\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {a e \int \frac {\sqrt {e \sin (c+d x)}}{e^2-e^2 \sin ^2(c+d x)}d(e \sin (c+d x))}{d}+a \int \sqrt {e \sin (c+d x)}dx\)

\(\Big \downarrow \) 266

\(\displaystyle \frac {2 a e \int \frac {e^2 \sin ^2(c+d x)}{e^2-e^4 \sin ^4(c+d x)}d\sqrt {e \sin (c+d x)}}{d}+a \int \sqrt {e \sin (c+d x)}dx\)

\(\Big \downarrow \) 827

\(\displaystyle \frac {2 a e \left (\frac {1}{2} \int \frac {1}{e-e^2 \sin ^2(c+d x)}d\sqrt {e \sin (c+d x)}-\frac {1}{2} \int \frac {1}{e^2 \sin ^2(c+d x)+e}d\sqrt {e \sin (c+d x)}\right )}{d}+a \int \sqrt {e \sin (c+d x)}dx\)

\(\Big \downarrow \) 216

\(\displaystyle \frac {2 a e \left (\frac {1}{2} \int \frac {1}{e-e^2 \sin ^2(c+d x)}d\sqrt {e \sin (c+d x)}-\frac {\arctan \left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}\right )}{d}+a \int \sqrt {e \sin (c+d x)}dx\)

\(\Big \downarrow \) 219

\(\displaystyle a \int \sqrt {e \sin (c+d x)}dx+\frac {2 a e \left (\frac {\text {arctanh}\left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}-\frac {\arctan \left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}\right )}{d}\)

\(\Big \downarrow \) 3121

\(\displaystyle \frac {a \sqrt {e \sin (c+d x)} \int \sqrt {\sin (c+d x)}dx}{\sqrt {\sin (c+d x)}}+\frac {2 a e \left (\frac {\text {arctanh}\left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}-\frac {\arctan \left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}\right )}{d}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {a \sqrt {e \sin (c+d x)} \int \sqrt {\sin (c+d x)}dx}{\sqrt {\sin (c+d x)}}+\frac {2 a e \left (\frac {\text {arctanh}\left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}-\frac {\arctan \left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}\right )}{d}\)

\(\Big \downarrow \) 3119

\(\displaystyle \frac {2 a e \left (\frac {\text {arctanh}\left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}-\frac {\arctan \left (\sqrt {e} \sin (c+d x)\right )}{2 \sqrt {e}}\right )}{d}+\frac {2 a E\left (\left .\frac {1}{2} \left (c+d x-\frac {\pi }{2}\right )\right |2\right ) \sqrt {e \sin (c+d x)}}{d \sqrt {\sin (c+d x)}}\)

Input:

Int[(a + a*Sec[c + d*x])*Sqrt[e*Sin[c + d*x]],x]
 

Output:

(2*a*e*(-1/2*ArcTan[Sqrt[e]*Sin[c + d*x]]/Sqrt[e] + ArcTanh[Sqrt[e]*Sin[c 
+ d*x]]/(2*Sqrt[e])))/d + (2*a*EllipticE[(c - Pi/2 + d*x)/2, 2]*Sqrt[e*Sin 
[c + d*x]])/(d*Sqrt[Sin[c + d*x]])
 

Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 216
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*A 
rcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a 
, 0] || GtQ[b, 0])
 

rule 219
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))* 
ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt 
Q[a, 0] || LtQ[b, 0])
 

rule 266
Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> With[{k = De 
nominator[m]}, Simp[k/c   Subst[Int[x^(k*(m + 1) - 1)*(a + b*(x^(2*k)/c^2)) 
^p, x], x, (c*x)^(1/k)], x]] /; FreeQ[{a, b, c, p}, x] && FractionQ[m] && I 
ntBinomialQ[a, b, c, 2, m, p, x]
 

rule 827
Int[(x_)^2/((a_) + (b_.)*(x_)^4), x_Symbol] :> With[{r = Numerator[Rt[-a/b, 
 2]], s = Denominator[Rt[-a/b, 2]]}, Simp[s/(2*b)   Int[1/(r + s*x^2), x], 
x] - Simp[s/(2*b)   Int[1/(r - s*x^2), x], x]] /; FreeQ[{a, b}, x] &&  !GtQ 
[a/b, 0]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 3044
Int[cos[(e_.) + (f_.)*(x_)]^(n_.)*((a_.)*sin[(e_.) + (f_.)*(x_)])^(m_.), x_ 
Symbol] :> Simp[1/(a*f)   Subst[Int[x^m*(1 - x^2/a^2)^((n - 1)/2), x], x, a 
*Sin[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n - 1)/2] &&  !(I 
ntegerQ[(m - 1)/2] && LtQ[0, m, n])
 

rule 3119
Int[Sqrt[sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[(2/d)*EllipticE[(1/2)* 
(c - Pi/2 + d*x), 2], x] /; FreeQ[{c, d}, x]
 

rule 3121
Int[((b_)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*Sin[c + d*x]) 
^n/Sin[c + d*x]^n   Int[Sin[c + d*x]^n, x], x] /; FreeQ[{b, c, d}, x] && Lt 
Q[-1, n, 1] && IntegerQ[2*n]
 

rule 3317
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n 
_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[a   Int[(g*Co 
s[e + f*x])^p*(d*Sin[e + f*x])^n, x], x] + Simp[b/d   Int[(g*Cos[e + f*x])^ 
p*(d*Sin[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, g, n, p}, x]
 

rule 4360
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + 
(a_))^(m_.), x_Symbol] :> Int[(g*Cos[e + f*x])^p*((b + a*Sin[e + f*x])^m/Si 
n[e + f*x]^m), x] /; FreeQ[{a, b, e, f, g, p}, x] && IntegerQ[m]
 
Maple [A] (verified)

Time = 0.25 (sec) , antiderivative size = 142, normalized size of antiderivative = 1.37

method result size
default \(\frac {-a \sqrt {e}\, \arctan \left (\frac {\sqrt {e \sin \left (d x +c \right )}}{\sqrt {e}}\right )+a \sqrt {e}\, \operatorname {arctanh}\left (\frac {\sqrt {e \sin \left (d x +c \right )}}{\sqrt {e}}\right )-\frac {a e \sqrt {-\sin \left (d x +c \right )+1}\, \sqrt {2 \sin \left (d x +c \right )+2}\, \sqrt {\sin \left (d x +c \right )}\, \left (2 \operatorname {EllipticE}\left (\sqrt {-\sin \left (d x +c \right )+1}, \frac {\sqrt {2}}{2}\right )-\operatorname {EllipticF}\left (\sqrt {-\sin \left (d x +c \right )+1}, \frac {\sqrt {2}}{2}\right )\right )}{\cos \left (d x +c \right ) \sqrt {e \sin \left (d x +c \right )}}}{d}\) \(142\)
parts \(-\frac {a e \sqrt {-\sin \left (d x +c \right )+1}\, \sqrt {2 \sin \left (d x +c \right )+2}\, \sqrt {\sin \left (d x +c \right )}\, \left (2 \operatorname {EllipticE}\left (\sqrt {-\sin \left (d x +c \right )+1}, \frac {\sqrt {2}}{2}\right )-\operatorname {EllipticF}\left (\sqrt {-\sin \left (d x +c \right )+1}, \frac {\sqrt {2}}{2}\right )\right )}{\cos \left (d x +c \right ) \sqrt {e \sin \left (d x +c \right )}\, d}-\frac {a \sqrt {e}\, \left (\arctan \left (\frac {\sqrt {e \sin \left (d x +c \right )}}{\sqrt {e}}\right )-\operatorname {arctanh}\left (\frac {\sqrt {e \sin \left (d x +c \right )}}{\sqrt {e}}\right )\right )}{d}\) \(142\)

Input:

int((a+a*sec(d*x+c))*(e*sin(d*x+c))^(1/2),x,method=_RETURNVERBOSE)
 

Output:

(-a*e^(1/2)*arctan((e*sin(d*x+c))^(1/2)/e^(1/2))+a*e^(1/2)*arctanh((e*sin( 
d*x+c))^(1/2)/e^(1/2))-a*e*(-sin(d*x+c)+1)^(1/2)*(2*sin(d*x+c)+2)^(1/2)*si 
n(d*x+c)^(1/2)*(2*EllipticE((-sin(d*x+c)+1)^(1/2),1/2*2^(1/2))-EllipticF(( 
-sin(d*x+c)+1)^(1/2),1/2*2^(1/2)))/cos(d*x+c)/(e*sin(d*x+c))^(1/2))/d
 

Fricas [C] (verification not implemented)

Result contains complex when optimal does not.

Time = 0.34 (sec) , antiderivative size = 545, normalized size of antiderivative = 5.24 \[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx =\text {Too large to display} \] Input:

integrate((a+a*sec(d*x+c))*(e*sin(d*x+c))^(1/2),x, algorithm="fricas")
 

Output:

[-1/8*(2*a*sqrt(-e)*arctan(1/4*(cos(d*x + c)^2 - 6*sin(d*x + c) - 2)*sqrt( 
e*sin(d*x + c))*sqrt(-e)/(e*cos(d*x + c)^2 - e*sin(d*x + c) - e)) - a*sqrt 
(-e)*log((e*cos(d*x + c)^4 - 72*e*cos(d*x + c)^2 - 8*(7*cos(d*x + c)^2 - ( 
cos(d*x + c)^2 - 8)*sin(d*x + c) - 8)*sqrt(e*sin(d*x + c))*sqrt(-e) + 28*( 
e*cos(d*x + c)^2 - 2*e)*sin(d*x + c) + 72*e)/(cos(d*x + c)^4 - 8*cos(d*x + 
 c)^2 - 4*(cos(d*x + c)^2 - 2)*sin(d*x + c) + 8)) - 16*I*a*sqrt(-1/2*I*e)* 
weierstrassZeta(4, 0, weierstrassPInverse(4, 0, cos(d*x + c) + I*sin(d*x + 
 c))) + 16*I*a*sqrt(1/2*I*e)*weierstrassZeta(4, 0, weierstrassPInverse(4, 
0, cos(d*x + c) - I*sin(d*x + c))))/d, -1/8*(2*a*sqrt(e)*arctan(1/4*(cos(d 
*x + c)^2 + 6*sin(d*x + c) - 2)*sqrt(e*sin(d*x + c))*sqrt(e)/(e*cos(d*x + 
c)^2 + e*sin(d*x + c) - e)) - a*sqrt(e)*log((e*cos(d*x + c)^4 - 72*e*cos(d 
*x + c)^2 - 8*(7*cos(d*x + c)^2 + (cos(d*x + c)^2 - 8)*sin(d*x + c) - 8)*s 
qrt(e*sin(d*x + c))*sqrt(e) - 28*(e*cos(d*x + c)^2 - 2*e)*sin(d*x + c) + 7 
2*e)/(cos(d*x + c)^4 - 8*cos(d*x + c)^2 + 4*(cos(d*x + c)^2 - 2)*sin(d*x + 
 c) + 8)) - 16*I*a*sqrt(-1/2*I*e)*weierstrassZeta(4, 0, weierstrassPInvers 
e(4, 0, cos(d*x + c) + I*sin(d*x + c))) + 16*I*a*sqrt(1/2*I*e)*weierstrass 
Zeta(4, 0, weierstrassPInverse(4, 0, cos(d*x + c) - I*sin(d*x + c))))/d]
 

Sympy [F]

\[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx=a \left (\int \sqrt {e \sin {\left (c + d x \right )}}\, dx + \int \sqrt {e \sin {\left (c + d x \right )}} \sec {\left (c + d x \right )}\, dx\right ) \] Input:

integrate((a+a*sec(d*x+c))*(e*sin(d*x+c))**(1/2),x)
 

Output:

a*(Integral(sqrt(e*sin(c + d*x)), x) + Integral(sqrt(e*sin(c + d*x))*sec(c 
 + d*x), x))
 

Maxima [F]

\[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx=\int { {\left (a \sec \left (d x + c\right ) + a\right )} \sqrt {e \sin \left (d x + c\right )} \,d x } \] Input:

integrate((a+a*sec(d*x+c))*(e*sin(d*x+c))^(1/2),x, algorithm="maxima")
 

Output:

integrate((a*sec(d*x + c) + a)*sqrt(e*sin(d*x + c)), x)
 

Giac [F]

\[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx=\int { {\left (a \sec \left (d x + c\right ) + a\right )} \sqrt {e \sin \left (d x + c\right )} \,d x } \] Input:

integrate((a+a*sec(d*x+c))*(e*sin(d*x+c))^(1/2),x, algorithm="giac")
 

Output:

integrate((a*sec(d*x + c) + a)*sqrt(e*sin(d*x + c)), x)
 

Mupad [F(-1)]

Timed out. \[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx=\int \sqrt {e\,\sin \left (c+d\,x\right )}\,\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right ) \,d x \] Input:

int((e*sin(c + d*x))^(1/2)*(a + a/cos(c + d*x)),x)
 

Output:

int((e*sin(c + d*x))^(1/2)*(a + a/cos(c + d*x)), x)
 

Reduce [F]

\[ \int (a+a \sec (c+d x)) \sqrt {e \sin (c+d x)} \, dx=\sqrt {e}\, a \left (\int \sqrt {\sin \left (d x +c \right )}d x +\int \sqrt {\sin \left (d x +c \right )}\, \sec \left (d x +c \right )d x \right ) \] Input:

int((a+a*sec(d*x+c))*(e*sin(d*x+c))^(1/2),x)
                                                                                    
                                                                                    
 

Output:

sqrt(e)*a*(int(sqrt(sin(c + d*x)),x) + int(sqrt(sin(c + d*x))*sec(c + d*x) 
,x))