Integrand size = 30, antiderivative size = 61 \[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\frac {2 C E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{d}+\frac {2 B \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )}{3 d}+\frac {2 B \sqrt {\cos (c+d x)} \sin (c+d x)}{3 d} \] Output:
2*C*EllipticE(sin(1/2*d*x+1/2*c),2^(1/2))/d+2/3*B*InverseJacobiAM(1/2*d*x+ 1/2*c,2^(1/2))/d+2/3*B*cos(d*x+c)^(1/2)*sin(d*x+c)/d
Time = 0.11 (sec) , antiderivative size = 53, normalized size of antiderivative = 0.87 \[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\frac {2 \left (3 C E\left (\left .\frac {1}{2} (c+d x)\right |2\right )+B \left (\operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )+\sqrt {\cos (c+d x)} \sin (c+d x)\right )\right )}{3 d} \] Input:
Integrate[Cos[c + d*x]^(5/2)*(B*Sec[c + d*x] + C*Sec[c + d*x]^2),x]
Output:
(2*(3*C*EllipticE[(c + d*x)/2, 2] + B*(EllipticF[(c + d*x)/2, 2] + Sqrt[Co s[c + d*x]]*Sin[c + d*x])))/(3*d)
Time = 0.42 (sec) , antiderivative size = 62, normalized size of antiderivative = 1.02, number of steps used = 9, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.300, Rules used = {3042, 4552, 3042, 3227, 3042, 3115, 3042, 3119, 3120}
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 \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \cos (c+d x)^{5/2} \left (B \sec (c+d x)+C \sec (c+d x)^2\right )dx\) |
\(\Big \downarrow \) 4552 |
\(\displaystyle \int \sqrt {\cos (c+d x)} (B \cos (c+d x)+C)dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sqrt {\sin \left (c+d x+\frac {\pi }{2}\right )} \left (B \sin \left (c+d x+\frac {\pi }{2}\right )+C\right )dx\) |
\(\Big \downarrow \) 3227 |
\(\displaystyle B \int \cos ^{\frac {3}{2}}(c+d x)dx+C \int \sqrt {\cos (c+d x)}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle B \int \sin \left (c+d x+\frac {\pi }{2}\right )^{3/2}dx+C \int \sqrt {\sin \left (c+d x+\frac {\pi }{2}\right )}dx\) |
\(\Big \downarrow \) 3115 |
\(\displaystyle B \left (\frac {1}{3} \int \frac {1}{\sqrt {\cos (c+d x)}}dx+\frac {2 \sin (c+d x) \sqrt {\cos (c+d x)}}{3 d}\right )+C \int \sqrt {\sin \left (c+d x+\frac {\pi }{2}\right )}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle B \left (\frac {1}{3} \int \frac {1}{\sqrt {\sin \left (c+d x+\frac {\pi }{2}\right )}}dx+\frac {2 \sin (c+d x) \sqrt {\cos (c+d x)}}{3 d}\right )+C \int \sqrt {\sin \left (c+d x+\frac {\pi }{2}\right )}dx\) |
\(\Big \downarrow \) 3119 |
\(\displaystyle B \left (\frac {1}{3} \int \frac {1}{\sqrt {\sin \left (c+d x+\frac {\pi }{2}\right )}}dx+\frac {2 \sin (c+d x) \sqrt {\cos (c+d x)}}{3 d}\right )+\frac {2 C E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{d}\) |
\(\Big \downarrow \) 3120 |
\(\displaystyle B \left (\frac {2 \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )}{3 d}+\frac {2 \sin (c+d x) \sqrt {\cos (c+d x)}}{3 d}\right )+\frac {2 C E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{d}\) |
Input:
Int[Cos[c + d*x]^(5/2)*(B*Sec[c + d*x] + C*Sec[c + d*x]^2),x]
Output:
(2*C*EllipticE[(c + d*x)/2, 2])/d + B*((2*EllipticF[(c + d*x)/2, 2])/(3*d) + (2*Sqrt[Cos[c + d*x]]*Sin[c + d*x])/(3*d))
Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(-b)*Cos[c + d* x]*((b*Sin[c + d*x])^(n - 1)/(d*n)), x] + Simp[b^2*((n - 1)/n) Int[(b*Sin [c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] && IntegerQ[ 2*n]
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]
Int[1/Sqrt[sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[(2/d)*EllipticF[(1/2 )*(c - Pi/2 + d*x), 2], x] /; FreeQ[{c, d}, x]
Int[((b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*sin[(e_.) + (f_.)*(x _)]), x_Symbol] :> Simp[c Int[(b*Sin[e + f*x])^m, x], x] + Simp[d/b Int [(b*Sin[e + f*x])^(m + 1), x], x] /; FreeQ[{b, c, d, e, f, m}, x]
Int[(cos[(e_.) + (f_.)*(x_)]*(b_.))^(m_)*((A_.) + (B_.)*sec[(e_.) + (f_.)*( x_)] + (C_.)*sec[(e_.) + (f_.)*(x_)]^2), x_Symbol] :> Simp[b^2 Int[(b*Cos [e + f*x])^(m - 2)*(C + B*Cos[e + f*x] + A*Cos[e + f*x]^2), x], x] /; FreeQ [{b, e, f, A, B, C, m}, x] && !IntegerQ[m]
Leaf count of result is larger than twice the leaf count of optimal. \(227\) vs. \(2(58)=116\).
Time = 14.22 (sec) , antiderivative size = 228, normalized size of antiderivative = 3.74
method | result | size |
default | \(-\frac {2 \sqrt {\left (2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1\right ) \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}\, \left (4 B \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}-2 B \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+B \sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1}\, \operatorname {EllipticF}\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right )-3 C \sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1}\, \operatorname {EllipticE}\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right )\right )}{3 \sqrt {-2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}\, \sin \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1}\, d}\) | \(228\) |
Input:
int(cos(d*x+c)^(5/2)*(B*sec(d*x+c)+C*sec(d*x+c)^2),x,method=_RETURNVERBOSE )
Output:
-2/3*((2*cos(1/2*d*x+1/2*c)^2-1)*sin(1/2*d*x+1/2*c)^2)^(1/2)*(4*B*cos(1/2* d*x+1/2*c)*sin(1/2*d*x+1/2*c)^4-2*B*cos(1/2*d*x+1/2*c)*sin(1/2*d*x+1/2*c)^ 2+B*(sin(1/2*d*x+1/2*c)^2)^(1/2)*(2*sin(1/2*d*x+1/2*c)^2-1)^(1/2)*Elliptic F(cos(1/2*d*x+1/2*c),2^(1/2))-3*C*(sin(1/2*d*x+1/2*c)^2)^(1/2)*(2*sin(1/2* d*x+1/2*c)^2-1)^(1/2)*EllipticE(cos(1/2*d*x+1/2*c),2^(1/2)))/(-2*sin(1/2*d *x+1/2*c)^4+sin(1/2*d*x+1/2*c)^2)^(1/2)/sin(1/2*d*x+1/2*c)/(2*cos(1/2*d*x+ 1/2*c)^2-1)^(1/2)/d
Result contains complex when optimal does not.
Time = 0.08 (sec) , antiderivative size = 125, normalized size of antiderivative = 2.05 \[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\frac {2 \, B \sqrt {\cos \left (d x + c\right )} \sin \left (d x + c\right ) - i \, \sqrt {2} B {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right ) + i \, \sqrt {2} B {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right ) + 3 i \, \sqrt {2} C {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right )\right ) - 3 i \, \sqrt {2} C {\rm weierstrassZeta}\left (-4, 0, {\rm weierstrassPInverse}\left (-4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right )\right )}{3 \, d} \] Input:
integrate(cos(d*x+c)^(5/2)*(B*sec(d*x+c)+C*sec(d*x+c)^2),x, algorithm="fri cas")
Output:
1/3*(2*B*sqrt(cos(d*x + c))*sin(d*x + c) - I*sqrt(2)*B*weierstrassPInverse (-4, 0, cos(d*x + c) + I*sin(d*x + c)) + I*sqrt(2)*B*weierstrassPInverse(- 4, 0, cos(d*x + c) - I*sin(d*x + c)) + 3*I*sqrt(2)*C*weierstrassZeta(-4, 0 , weierstrassPInverse(-4, 0, cos(d*x + c) + I*sin(d*x + c))) - 3*I*sqrt(2) *C*weierstrassZeta(-4, 0, weierstrassPInverse(-4, 0, cos(d*x + c) - I*sin( d*x + c))))/d
Timed out. \[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\text {Timed out} \] Input:
integrate(cos(d*x+c)**(5/2)*(B*sec(d*x+c)+C*sec(d*x+c)**2),x)
Output:
Timed out
\[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\int { {\left (C \sec \left (d x + c\right )^{2} + B \sec \left (d x + c\right )\right )} \cos \left (d x + c\right )^{\frac {5}{2}} \,d x } \] Input:
integrate(cos(d*x+c)^(5/2)*(B*sec(d*x+c)+C*sec(d*x+c)^2),x, algorithm="max ima")
Output:
integrate((C*sec(d*x + c)^2 + B*sec(d*x + c))*cos(d*x + c)^(5/2), x)
\[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\int { {\left (C \sec \left (d x + c\right )^{2} + B \sec \left (d x + c\right )\right )} \cos \left (d x + c\right )^{\frac {5}{2}} \,d x } \] Input:
integrate(cos(d*x+c)^(5/2)*(B*sec(d*x+c)+C*sec(d*x+c)^2),x, algorithm="gia c")
Output:
integrate((C*sec(d*x + c)^2 + B*sec(d*x + c))*cos(d*x + c)^(5/2), x)
Time = 0.17 (sec) , antiderivative size = 53, normalized size of antiderivative = 0.87 \[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\frac {2\,B\,\mathrm {F}\left (\frac {c}{2}+\frac {d\,x}{2}\middle |2\right )}{3\,d}+\frac {2\,C\,\mathrm {E}\left (\frac {c}{2}+\frac {d\,x}{2}\middle |2\right )}{d}+\frac {2\,B\,\sqrt {\cos \left (c+d\,x\right )}\,\sin \left (c+d\,x\right )}{3\,d} \] Input:
int(cos(c + d*x)^(5/2)*(B/cos(c + d*x) + C/cos(c + d*x)^2),x)
Output:
(2*B*ellipticF(c/2 + (d*x)/2, 2))/(3*d) + (2*C*ellipticE(c/2 + (d*x)/2, 2) )/d + (2*B*cos(c + d*x)^(1/2)*sin(c + d*x))/(3*d)
\[ \int \cos ^{\frac {5}{2}}(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\left (\int \sqrt {\cos \left (d x +c \right )}\, \cos \left (d x +c \right )^{2} \sec \left (d x +c \right )^{2}d x \right ) c +\left (\int \sqrt {\cos \left (d x +c \right )}\, \cos \left (d x +c \right )^{2} \sec \left (d x +c \right )d x \right ) b \] Input:
int(cos(d*x+c)^(5/2)*(B*sec(d*x+c)+C*sec(d*x+c)^2),x)
Output:
int(sqrt(cos(c + d*x))*cos(c + d*x)**2*sec(c + d*x)**2,x)*c + int(sqrt(cos (c + d*x))*cos(c + d*x)**2*sec(c + d*x),x)*b