Integrand size = 21, antiderivative size = 73 \[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=6 a^4 x+\frac {a^4 \text {arctanh}(\sin (c+d x))}{d}+\frac {7 a^4 \sin (c+d x)}{d}+\frac {2 a^4 \cos (c+d x) \sin (c+d x)}{d}-\frac {a^4 \sin ^3(c+d x)}{3 d} \] Output:
6*a^4*x+a^4*arctanh(sin(d*x+c))/d+7*a^4*sin(d*x+c)/d+2*a^4*cos(d*x+c)*sin( d*x+c)/d-1/3*a^4*sin(d*x+c)^3/d
Time = 0.38 (sec) , antiderivative size = 91, normalized size of antiderivative = 1.25 \[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=\frac {a^4 \left (72 d x-12 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )+12 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right )+81 \sin (c+d x)+12 \sin (2 (c+d x))+\sin (3 (c+d x))\right )}{12 d} \] Input:
Integrate[Cos[c + d*x]^3*(a + a*Sec[c + d*x])^4,x]
Output:
(a^4*(72*d*x - 12*Log[Cos[(c + d*x)/2] - Sin[(c + d*x)/2]] + 12*Log[Cos[(c + d*x)/2] + Sin[(c + d*x)/2]] + 81*Sin[c + d*x] + 12*Sin[2*(c + d*x)] + S in[3*(c + d*x)]))/(12*d)
Time = 0.30 (sec) , antiderivative size = 73, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3042, 4278, 2009}
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 ^3(c+d x) (a \sec (c+d x)+a)^4 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\left (a \csc \left (c+d x+\frac {\pi }{2}\right )+a\right )^4}{\csc \left (c+d x+\frac {\pi }{2}\right )^3}dx\) |
\(\Big \downarrow \) 4278 |
\(\displaystyle \int \left (a^4 \cos ^3(c+d x)+4 a^4 \cos ^2(c+d x)+6 a^4 \cos (c+d x)+a^4 \sec (c+d x)+4 a^4\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {a^4 \text {arctanh}(\sin (c+d x))}{d}-\frac {a^4 \sin ^3(c+d x)}{3 d}+\frac {7 a^4 \sin (c+d x)}{d}+\frac {2 a^4 \sin (c+d x) \cos (c+d x)}{d}+6 a^4 x\) |
Input:
Int[Cos[c + d*x]^3*(a + a*Sec[c + d*x])^4,x]
Output:
6*a^4*x + (a^4*ArcTanh[Sin[c + d*x]])/d + (7*a^4*Sin[c + d*x])/d + (2*a^4* Cos[c + d*x]*Sin[c + d*x])/d - (a^4*Sin[c + d*x]^3)/(3*d)
Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_), x_Symbol] :> Int[ExpandTrig[(a + b*csc[e + f*x])^m*(d*csc[e + f *x])^n, x], x] /; FreeQ[{a, b, d, e, f, m, n}, x] && EqQ[a^2 - b^2, 0] && I GtQ[m, 0] && RationalQ[n]
Time = 0.79 (sec) , antiderivative size = 70, normalized size of antiderivative = 0.96
method | result | size |
parallelrisch | \(\frac {a^{4} \left (72 d x +12 \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )-12 \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )+81 \sin \left (d x +c \right )+\sin \left (3 d x +3 c \right )+12 \sin \left (2 d x +2 c \right )\right )}{12 d}\) | \(70\) |
derivativedivides | \(\frac {a^{4} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+4 a^{4} \left (d x +c \right )+6 a^{4} \sin \left (d x +c \right )+4 a^{4} \left (\frac {\sin \left (d x +c \right ) \cos \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+\frac {a^{4} \left (2+\cos \left (d x +c \right )^{2}\right ) \sin \left (d x +c \right )}{3}}{d}\) | \(93\) |
default | \(\frac {a^{4} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+4 a^{4} \left (d x +c \right )+6 a^{4} \sin \left (d x +c \right )+4 a^{4} \left (\frac {\sin \left (d x +c \right ) \cos \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+\frac {a^{4} \left (2+\cos \left (d x +c \right )^{2}\right ) \sin \left (d x +c \right )}{3}}{d}\) | \(93\) |
risch | \(6 a^{4} x -\frac {27 i a^{4} {\mathrm e}^{i \left (d x +c \right )}}{8 d}+\frac {27 i a^{4} {\mathrm e}^{-i \left (d x +c \right )}}{8 d}+\frac {a^{4} \ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right )}{d}-\frac {a^{4} \ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right )}{d}+\frac {a^{4} \sin \left (3 d x +3 c \right )}{12 d}+\frac {a^{4} \sin \left (2 d x +2 c \right )}{d}\) | \(118\) |
norman | \(\frac {-6 a^{4} x -\frac {18 a^{4} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{d}+\frac {86 a^{4} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3}}{3 d}+\frac {12 a^{4} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{5}}{d}-\frac {28 a^{4} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{7}}{d}-\frac {14 a^{4} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{9}}{3 d}+\frac {10 a^{4} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{11}}{d}+18 a^{4} x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}-18 a^{4} x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{8}+6 a^{4} x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{12}}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{3} \left (-1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{3}}+\frac {a^{4} \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{d}-\frac {a^{4} \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{d}\) | \(242\) |
Input:
int(cos(d*x+c)^3*(a+a*sec(d*x+c))^4,x,method=_RETURNVERBOSE)
Output:
1/12*a^4*(72*d*x+12*ln(tan(1/2*d*x+1/2*c)+1)-12*ln(tan(1/2*d*x+1/2*c)-1)+8 1*sin(d*x+c)+sin(3*d*x+3*c)+12*sin(2*d*x+2*c))/d
Time = 0.09 (sec) , antiderivative size = 80, normalized size of antiderivative = 1.10 \[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=\frac {36 \, a^{4} d x + 3 \, a^{4} \log \left (\sin \left (d x + c\right ) + 1\right ) - 3 \, a^{4} \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, {\left (a^{4} \cos \left (d x + c\right )^{2} + 6 \, a^{4} \cos \left (d x + c\right ) + 20 \, a^{4}\right )} \sin \left (d x + c\right )}{6 \, d} \] Input:
integrate(cos(d*x+c)^3*(a+a*sec(d*x+c))^4,x, algorithm="fricas")
Output:
1/6*(36*a^4*d*x + 3*a^4*log(sin(d*x + c) + 1) - 3*a^4*log(-sin(d*x + c) + 1) + 2*(a^4*cos(d*x + c)^2 + 6*a^4*cos(d*x + c) + 20*a^4)*sin(d*x + c))/d
\[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=a^{4} \left (\int 4 \cos ^{3}{\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx + \int 6 \cos ^{3}{\left (c + d x \right )} \sec ^{2}{\left (c + d x \right )}\, dx + \int 4 \cos ^{3}{\left (c + d x \right )} \sec ^{3}{\left (c + d x \right )}\, dx + \int \cos ^{3}{\left (c + d x \right )} \sec ^{4}{\left (c + d x \right )}\, dx + \int \cos ^{3}{\left (c + d x \right )}\, dx\right ) \] Input:
integrate(cos(d*x+c)**3*(a+a*sec(d*x+c))**4,x)
Output:
a**4*(Integral(4*cos(c + d*x)**3*sec(c + d*x), x) + Integral(6*cos(c + d*x )**3*sec(c + d*x)**2, x) + Integral(4*cos(c + d*x)**3*sec(c + d*x)**3, x) + Integral(cos(c + d*x)**3*sec(c + d*x)**4, x) + Integral(cos(c + d*x)**3, x))
Time = 0.04 (sec) , antiderivative size = 97, normalized size of antiderivative = 1.33 \[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=-\frac {2 \, {\left (\sin \left (d x + c\right )^{3} - 3 \, \sin \left (d x + c\right )\right )} a^{4} - 6 \, {\left (2 \, d x + 2 \, c + \sin \left (2 \, d x + 2 \, c\right )\right )} a^{4} - 24 \, {\left (d x + c\right )} a^{4} - 3 \, a^{4} {\left (\log \left (\sin \left (d x + c\right ) + 1\right ) - \log \left (\sin \left (d x + c\right ) - 1\right )\right )} - 36 \, a^{4} \sin \left (d x + c\right )}{6 \, d} \] Input:
integrate(cos(d*x+c)^3*(a+a*sec(d*x+c))^4,x, algorithm="maxima")
Output:
-1/6*(2*(sin(d*x + c)^3 - 3*sin(d*x + c))*a^4 - 6*(2*d*x + 2*c + sin(2*d*x + 2*c))*a^4 - 24*(d*x + c)*a^4 - 3*a^4*(log(sin(d*x + c) + 1) - log(sin(d *x + c) - 1)) - 36*a^4*sin(d*x + c))/d
Time = 0.22 (sec) , antiderivative size = 116, normalized size of antiderivative = 1.59 \[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=\frac {18 \, {\left (d x + c\right )} a^{4} + 3 \, a^{4} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1 \right |}\right ) - 3 \, a^{4} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1 \right |}\right ) + \frac {2 \, {\left (15 \, a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 38 \, a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 27 \, a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{3}}}{3 \, d} \] Input:
integrate(cos(d*x+c)^3*(a+a*sec(d*x+c))^4,x, algorithm="giac")
Output:
1/3*(18*(d*x + c)*a^4 + 3*a^4*log(abs(tan(1/2*d*x + 1/2*c) + 1)) - 3*a^4*l og(abs(tan(1/2*d*x + 1/2*c) - 1)) + 2*(15*a^4*tan(1/2*d*x + 1/2*c)^5 + 38* a^4*tan(1/2*d*x + 1/2*c)^3 + 27*a^4*tan(1/2*d*x + 1/2*c))/(tan(1/2*d*x + 1 /2*c)^2 + 1)^3)/d
Time = 9.79 (sec) , antiderivative size = 93, normalized size of antiderivative = 1.27 \[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=6\,a^4\,x+\frac {20\,a^4\,\sin \left (c+d\,x\right )}{3\,d}+\frac {2\,a^4\,\mathrm {atanh}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{d}+\frac {a^4\,{\cos \left (c+d\,x\right )}^2\,\sin \left (c+d\,x\right )}{3\,d}+\frac {2\,a^4\,\cos \left (c+d\,x\right )\,\sin \left (c+d\,x\right )}{d} \] Input:
int(cos(c + d*x)^3*(a + a/cos(c + d*x))^4,x)
Output:
6*a^4*x + (20*a^4*sin(c + d*x))/(3*d) + (2*a^4*atanh(sin(c/2 + (d*x)/2)/co s(c/2 + (d*x)/2)))/d + (a^4*cos(c + d*x)^2*sin(c + d*x))/(3*d) + (2*a^4*co s(c + d*x)*sin(c + d*x))/d
Time = 0.29 (sec) , antiderivative size = 76, normalized size of antiderivative = 1.04 \[ \int \cos ^3(c+d x) (a+a \sec (c+d x))^4 \, dx=\frac {a^{4} \left (6 \cos \left (d x +c \right ) \sin \left (d x +c \right )-3 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )+3 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )-\sin \left (d x +c \right )^{3}+21 \sin \left (d x +c \right )+18 c +18 d x \right )}{3 d} \] Input:
int(cos(d*x+c)^3*(a+a*sec(d*x+c))^4,x)
Output:
(a**4*(6*cos(c + d*x)*sin(c + d*x) - 3*log(tan((c + d*x)/2) - 1) + 3*log(t an((c + d*x)/2) + 1) - sin(c + d*x)**3 + 21*sin(c + d*x) + 18*c + 18*d*x)) /(3*d)