Integrand size = 24, antiderivative size = 157 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=4 a \left (5 a^2+3 b^2\right ) x-\frac {4 a \left (15 a^2+4 b^2\right ) \cos (d+e x)}{3 e}+\frac {4 b \left (15 a^2+4 b^2\right ) \sin (d+e x)}{3 e}-\frac {8 (a+b \cos (d+e x)+a \sin (d+e x))^2 (a \cos (d+e x)-b \sin (d+e x))}{3 e}-\frac {20 (a+b \cos (d+e x)+a \sin (d+e x)) \left (a^2 \cos (d+e x)-a b \sin (d+e x)\right )}{3 e} \] Output:
4*a*(5*a^2+3*b^2)*x-4/3*a*(15*a^2+4*b^2)*cos(e*x+d)/e+4/3*b*(15*a^2+4*b^2) *sin(e*x+d)/e-8/3*(a+b*cos(e*x+d)+a*sin(e*x+d))^2*(a*cos(e*x+d)-b*sin(e*x+ d))/e-20/3*(a+b*cos(e*x+d)+a*sin(e*x+d))*(a^2*cos(e*x+d)-a*b*sin(e*x+d))/e
Time = 1.38 (sec) , antiderivative size = 135, normalized size of antiderivative = 0.86 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=\frac {2 \left (6 a \left (5 a^2+3 b^2\right ) (d+e x)-9 a \left (5 a^2+b^2\right ) \cos (d+e x)-18 a^2 b \cos (2 (d+e x))+a \left (a^2-3 b^2\right ) \cos (3 (d+e x))+9 b \left (5 a^2+b^2\right ) \sin (d+e x)-9 a \left (a^2-b^2\right ) \sin (2 (d+e x))+b \left (-3 a^2+b^2\right ) \sin (3 (d+e x))\right )}{3 e} \] Input:
Integrate[(2*a + 2*b*Cos[d + e*x] + 2*a*Sin[d + e*x])^3,x]
Output:
(2*(6*a*(5*a^2 + 3*b^2)*(d + e*x) - 9*a*(5*a^2 + b^2)*Cos[d + e*x] - 18*a^ 2*b*Cos[2*(d + e*x)] + a*(a^2 - 3*b^2)*Cos[3*(d + e*x)] + 9*b*(5*a^2 + b^2 )*Sin[d + e*x] - 9*a*(a^2 - b^2)*Sin[2*(d + e*x)] + b*(-3*a^2 + b^2)*Sin[3 *(d + e*x)]))/(3*e)
Time = 0.48 (sec) , antiderivative size = 170, normalized size of antiderivative = 1.08, number of steps used = 6, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {3042, 3599, 27, 3042, 3625, 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 (2 a \sin (d+e x)+2 a+2 b \cos (d+e x))^3 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int (2 a \sin (d+e x)+2 a+2 b \cos (d+e x))^3dx\) |
\(\Big \downarrow \) 3599 |
\(\displaystyle \frac {1}{3} \int 8 (\sin (d+e x) a+a+b \cos (d+e x)) \left (5 \sin (d+e x) a^2+5 a^2+5 b \cos (d+e x) a+2 b^2\right )dx-\frac {8 (a \sin (d+e x)+a+b \cos (d+e x))^2 (a \cos (d+e x)-b \sin (d+e x))}{3 e}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {8}{3} \int (\sin (d+e x) a+a+b \cos (d+e x)) \left (5 \sin (d+e x) a^2+5 a^2+5 b \cos (d+e x) a+2 b^2\right )dx-\frac {8 (a \sin (d+e x)+a+b \cos (d+e x))^2 (a \cos (d+e x)-b \sin (d+e x))}{3 e}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {8}{3} \int (\sin (d+e x) a+a+b \cos (d+e x)) \left (5 \sin (d+e x) a^2+5 a^2+5 b \cos (d+e x) a+2 b^2\right )dx-\frac {8 (a \sin (d+e x)+a+b \cos (d+e x))^2 (a \cos (d+e x)-b \sin (d+e x))}{3 e}\) |
\(\Big \downarrow \) 3625 |
\(\displaystyle \frac {8}{3} \left (\frac {\int \left (3 \left (5 a^2+3 b^2\right ) a^2+\left (15 a^2+4 b^2\right ) \sin (d+e x) a^2+b \left (15 a^2+4 b^2\right ) \cos (d+e x) a\right )dx}{2 a}-\frac {5 (a \sin (d+e x)+a+b \cos (d+e x)) \left (a^2 \cos (d+e x)-a b \sin (d+e x)\right )}{2 e}\right )-\frac {8 (a \sin (d+e x)+a+b \cos (d+e x))^2 (a \cos (d+e x)-b \sin (d+e x))}{3 e}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {8}{3} \left (\frac {\frac {a b \left (15 a^2+4 b^2\right ) \sin (d+e x)}{e}-\frac {a^2 \left (15 a^2+4 b^2\right ) \cos (d+e x)}{e}+3 a^2 x \left (5 a^2+3 b^2\right )}{2 a}-\frac {5 (a \sin (d+e x)+a+b \cos (d+e x)) \left (a^2 \cos (d+e x)-a b \sin (d+e x)\right )}{2 e}\right )-\frac {8 (a \sin (d+e x)+a+b \cos (d+e x))^2 (a \cos (d+e x)-b \sin (d+e x))}{3 e}\) |
Input:
Int[(2*a + 2*b*Cos[d + e*x] + 2*a*Sin[d + e*x])^3,x]
Output:
(-8*(a + b*Cos[d + e*x] + a*Sin[d + e*x])^2*(a*Cos[d + e*x] - b*Sin[d + e* x]))/(3*e) + (8*((-5*(a + b*Cos[d + e*x] + a*Sin[d + e*x])*(a^2*Cos[d + e* x] - a*b*Sin[d + e*x]))/(2*e) + (3*a^2*(5*a^2 + 3*b^2)*x - (a^2*(15*a^2 + 4*b^2)*Cos[d + e*x])/e + (a*b*(15*a^2 + 4*b^2)*Sin[d + e*x])/e)/(2*a)))/3
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[(cos[(d_.) + (e_.)*(x_)]*(b_.) + (a_) + (c_.)*sin[(d_.) + (e_.)*(x_)])^ (n_), x_Symbol] :> Simp[(-(c*Cos[d + e*x] - b*Sin[d + e*x]))*((a + b*Cos[d + e*x] + c*Sin[d + e*x])^(n - 1)/(e*n)), x] + Simp[1/n Int[Simp[n*a^2 + ( n - 1)*(b^2 + c^2) + a*b*(2*n - 1)*Cos[d + e*x] + a*c*(2*n - 1)*Sin[d + e*x ], x]*(a + b*Cos[d + e*x] + c*Sin[d + e*x])^(n - 2), x], x] /; FreeQ[{a, b, c, d, e}, x] && NeQ[a^2 - b^2 - c^2, 0] && GtQ[n, 1]
Int[(cos[(d_.) + (e_.)*(x_)]*(b_.) + (a_) + (c_.)*sin[(d_.) + (e_.)*(x_)])^ (n_.)*((A_.) + cos[(d_.) + (e_.)*(x_)]*(B_.) + (C_.)*sin[(d_.) + (e_.)*(x_) ]), x_Symbol] :> Simp[(B*c - b*C - a*C*Cos[d + e*x] + a*B*Sin[d + e*x])*((a + b*Cos[d + e*x] + c*Sin[d + e*x])^n/(a*e*(n + 1))), x] + Simp[1/(a*(n + 1 )) Int[(a + b*Cos[d + e*x] + c*Sin[d + e*x])^(n - 1)*Simp[a*(b*B + c*C)*n + a^2*A*(n + 1) + (n*(a^2*B - B*c^2 + b*c*C) + a*b*A*(n + 1))*Cos[d + e*x] + (n*(b*B*c + a^2*C - b^2*C) + a*c*A*(n + 1))*Sin[d + e*x], x], x], x] /; FreeQ[{a, b, c, d, e, A, B, C}, x] && GtQ[n, 0] && NeQ[a^2 - b^2 - c^2, 0]
Time = 0.44 (sec) , antiderivative size = 177, normalized size of antiderivative = 1.13
\[\frac {\frac {8 b^{3} \left (2+\cos \left (e x +d \right )^{2}\right ) \sin \left (e x +d \right )}{3}-8 a \,b^{2} \cos \left (e x +d \right )^{3}+8 a^{2} b \sin \left (e x +d \right )^{3}-\frac {8 a^{3} \left (2+\sin \left (e x +d \right )^{2}\right ) \cos \left (e x +d \right )}{3}+24 a \,b^{2} \left (\frac {\sin \left (e x +d \right ) \cos \left (e x +d \right )}{2}+\frac {e x}{2}+\frac {d}{2}\right )-24 a^{2} b \cos \left (e x +d \right )^{2}+24 a^{3} \left (-\frac {\sin \left (e x +d \right ) \cos \left (e x +d \right )}{2}+\frac {e x}{2}+\frac {d}{2}\right )+24 \sin \left (e x +d \right ) a^{2} b -24 a^{3} \cos \left (e x +d \right )+8 a^{3} \left (e x +d \right )}{e}\]
Input:
int((2*a+2*b*cos(e*x+d)+2*a*sin(e*x+d))^3,x)
Output:
8/e*(1/3*b^3*(2+cos(e*x+d)^2)*sin(e*x+d)-a*b^2*cos(e*x+d)^3+a^2*b*sin(e*x+ d)^3-1/3*a^3*(2+sin(e*x+d)^2)*cos(e*x+d)+3*a*b^2*(1/2*sin(e*x+d)*cos(e*x+d )+1/2*e*x+1/2*d)-3*a^2*b*cos(e*x+d)^2+3*a^3*(-1/2*sin(e*x+d)*cos(e*x+d)+1/ 2*e*x+1/2*d)+3*sin(e*x+d)*a^2*b-3*a^3*cos(e*x+d)+a^3*(e*x+d))
Time = 0.08 (sec) , antiderivative size = 127, normalized size of antiderivative = 0.81 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=-\frac {4 \, {\left (18 \, a^{2} b \cos \left (e x + d\right )^{2} + 24 \, a^{3} \cos \left (e x + d\right ) - 2 \, {\left (a^{3} - 3 \, a b^{2}\right )} \cos \left (e x + d\right )^{3} - 3 \, {\left (5 \, a^{3} + 3 \, a b^{2}\right )} e x - {\left (24 \, a^{2} b + 4 \, b^{3} - 2 \, {\left (3 \, a^{2} b - b^{3}\right )} \cos \left (e x + d\right )^{2} - 9 \, {\left (a^{3} - a b^{2}\right )} \cos \left (e x + d\right )\right )} \sin \left (e x + d\right )\right )}}{3 \, e} \] Input:
integrate((2*a+2*b*cos(e*x+d)+2*a*sin(e*x+d))^3,x, algorithm="fricas")
Output:
-4/3*(18*a^2*b*cos(e*x + d)^2 + 24*a^3*cos(e*x + d) - 2*(a^3 - 3*a*b^2)*co s(e*x + d)^3 - 3*(5*a^3 + 3*a*b^2)*e*x - (24*a^2*b + 4*b^3 - 2*(3*a^2*b - b^3)*cos(e*x + d)^2 - 9*(a^3 - a*b^2)*cos(e*x + d))*sin(e*x + d))/e
Time = 0.18 (sec) , antiderivative size = 291, normalized size of antiderivative = 1.85 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=\begin {cases} 12 a^{3} x \sin ^{2}{\left (d + e x \right )} + 12 a^{3} x \cos ^{2}{\left (d + e x \right )} + 8 a^{3} x - \frac {8 a^{3} \sin ^{2}{\left (d + e x \right )} \cos {\left (d + e x \right )}}{e} - \frac {12 a^{3} \sin {\left (d + e x \right )} \cos {\left (d + e x \right )}}{e} - \frac {16 a^{3} \cos ^{3}{\left (d + e x \right )}}{3 e} - \frac {24 a^{3} \cos {\left (d + e x \right )}}{e} + \frac {8 a^{2} b \sin ^{3}{\left (d + e x \right )}}{e} + \frac {24 a^{2} b \sin {\left (d + e x \right )}}{e} - \frac {24 a^{2} b \cos ^{2}{\left (d + e x \right )}}{e} + 12 a b^{2} x \sin ^{2}{\left (d + e x \right )} + 12 a b^{2} x \cos ^{2}{\left (d + e x \right )} + \frac {12 a b^{2} \sin {\left (d + e x \right )} \cos {\left (d + e x \right )}}{e} - \frac {8 a b^{2} \cos ^{3}{\left (d + e x \right )}}{e} + \frac {16 b^{3} \sin ^{3}{\left (d + e x \right )}}{3 e} + \frac {8 b^{3} \sin {\left (d + e x \right )} \cos ^{2}{\left (d + e x \right )}}{e} & \text {for}\: e \neq 0 \\x \left (2 a \sin {\left (d \right )} + 2 a + 2 b \cos {\left (d \right )}\right )^{3} & \text {otherwise} \end {cases} \] Input:
integrate((2*a+2*b*cos(e*x+d)+2*a*sin(e*x+d))**3,x)
Output:
Piecewise((12*a**3*x*sin(d + e*x)**2 + 12*a**3*x*cos(d + e*x)**2 + 8*a**3* x - 8*a**3*sin(d + e*x)**2*cos(d + e*x)/e - 12*a**3*sin(d + e*x)*cos(d + e *x)/e - 16*a**3*cos(d + e*x)**3/(3*e) - 24*a**3*cos(d + e*x)/e + 8*a**2*b* sin(d + e*x)**3/e + 24*a**2*b*sin(d + e*x)/e - 24*a**2*b*cos(d + e*x)**2/e + 12*a*b**2*x*sin(d + e*x)**2 + 12*a*b**2*x*cos(d + e*x)**2 + 12*a*b**2*s in(d + e*x)*cos(d + e*x)/e - 8*a*b**2*cos(d + e*x)**3/e + 16*b**3*sin(d + e*x)**3/(3*e) + 8*b**3*sin(d + e*x)*cos(d + e*x)**2/e, Ne(e, 0)), (x*(2*a* sin(d) + 2*a + 2*b*cos(d))**3, True))
Time = 0.07 (sec) , antiderivative size = 191, normalized size of antiderivative = 1.22 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=-\frac {8 \, a b^{2} \cos \left (e x + d\right )^{3}}{e} + \frac {8 \, a^{2} b \sin \left (e x + d\right )^{3}}{e} + 8 \, a^{3} x + \frac {8 \, {\left (\cos \left (e x + d\right )^{3} - 3 \, \cos \left (e x + d\right )\right )} a^{3}}{3 \, e} - \frac {8 \, {\left (\sin \left (e x + d\right )^{3} - 3 \, \sin \left (e x + d\right )\right )} b^{3}}{3 \, e} - 24 \, a^{2} {\left (\frac {a \cos \left (e x + d\right )}{e} - \frac {b \sin \left (e x + d\right )}{e}\right )} - 6 \, {\left (\frac {4 \, a b \cos \left (e x + d\right )^{2}}{e} - \frac {{\left (2 \, e x + 2 \, d - \sin \left (2 \, e x + 2 \, d\right )\right )} a^{2}}{e} - \frac {{\left (2 \, e x + 2 \, d + \sin \left (2 \, e x + 2 \, d\right )\right )} b^{2}}{e}\right )} a \] Input:
integrate((2*a+2*b*cos(e*x+d)+2*a*sin(e*x+d))^3,x, algorithm="maxima")
Output:
-8*a*b^2*cos(e*x + d)^3/e + 8*a^2*b*sin(e*x + d)^3/e + 8*a^3*x + 8/3*(cos( e*x + d)^3 - 3*cos(e*x + d))*a^3/e - 8/3*(sin(e*x + d)^3 - 3*sin(e*x + d)) *b^3/e - 24*a^2*(a*cos(e*x + d)/e - b*sin(e*x + d)/e) - 6*(4*a*b*cos(e*x + d)^2/e - (2*e*x + 2*d - sin(2*e*x + 2*d))*a^2/e - (2*e*x + 2*d + sin(2*e* x + 2*d))*b^2/e)*a
Time = 0.13 (sec) , antiderivative size = 151, normalized size of antiderivative = 0.96 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=-\frac {12 \, a^{2} b \cos \left (2 \, e x + 2 \, d\right )}{e} + 4 \, {\left (5 \, a^{3} + 3 \, a b^{2}\right )} x + \frac {2 \, {\left (a^{3} - 3 \, a b^{2}\right )} \cos \left (3 \, e x + 3 \, d\right )}{3 \, e} - \frac {6 \, {\left (5 \, a^{3} + a b^{2}\right )} \cos \left (e x + d\right )}{e} - \frac {2 \, {\left (3 \, a^{2} b - b^{3}\right )} \sin \left (3 \, e x + 3 \, d\right )}{3 \, e} - \frac {6 \, {\left (a^{3} - a b^{2}\right )} \sin \left (2 \, e x + 2 \, d\right )}{e} + \frac {6 \, {\left (5 \, a^{2} b + b^{3}\right )} \sin \left (e x + d\right )}{e} \] Input:
integrate((2*a+2*b*cos(e*x+d)+2*a*sin(e*x+d))^3,x, algorithm="giac")
Output:
-12*a^2*b*cos(2*e*x + 2*d)/e + 4*(5*a^3 + 3*a*b^2)*x + 2/3*(a^3 - 3*a*b^2) *cos(3*e*x + 3*d)/e - 6*(5*a^3 + a*b^2)*cos(e*x + d)/e - 2/3*(3*a^2*b - b^ 3)*sin(3*e*x + 3*d)/e - 6*(a^3 - a*b^2)*sin(2*e*x + 2*d)/e + 6*(5*a^2*b + b^3)*sin(e*x + d)/e
Time = 17.25 (sec) , antiderivative size = 292, normalized size of antiderivative = 1.86 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=\frac {{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^5\,\left (24\,a^3+48\,a^2\,b-24\,a\,b^2+16\,b^3\right )-{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^4\,\left (48\,a^3-96\,a^2\,b+48\,a\,b^2\right )-16\,a\,b^2+{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^2\,\left (96\,a^2\,b-128\,a^3\right )+{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^3\,\left (160\,a^2\,b+\frac {32\,b^3}{3}\right )-\frac {176\,a^3}{3}+\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )\,\left (-24\,a^3+48\,a^2\,b+24\,a\,b^2+16\,b^3\right )}{e\,\left ({\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^6+3\,{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^4+3\,{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^2+1\right )}+\frac {8\,a\,\mathrm {atan}\left (\frac {8\,a\,\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )\,\left (5\,a^2+3\,b^2\right )}{40\,a^3+24\,a\,b^2}\right )\,\left (5\,a^2+3\,b^2\right )}{e}-\frac {8\,a\,\left (5\,a^2+3\,b^2\right )\,\left (\mathrm {atan}\left (\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )\right )-\frac {e\,x}{2}\right )}{e} \] Input:
int((2*a + 2*b*cos(d + e*x) + 2*a*sin(d + e*x))^3,x)
Output:
(tan(d/2 + (e*x)/2)^5*(48*a^2*b - 24*a*b^2 + 24*a^3 + 16*b^3) - tan(d/2 + (e*x)/2)^4*(48*a*b^2 - 96*a^2*b + 48*a^3) - 16*a*b^2 + tan(d/2 + (e*x)/2)^ 2*(96*a^2*b - 128*a^3) + tan(d/2 + (e*x)/2)^3*(160*a^2*b + (32*b^3)/3) - ( 176*a^3)/3 + tan(d/2 + (e*x)/2)*(24*a*b^2 + 48*a^2*b - 24*a^3 + 16*b^3))/( e*(3*tan(d/2 + (e*x)/2)^2 + 3*tan(d/2 + (e*x)/2)^4 + tan(d/2 + (e*x)/2)^6 + 1)) + (8*a*atan((8*a*tan(d/2 + (e*x)/2)*(5*a^2 + 3*b^2))/(24*a*b^2 + 40* a^3))*(5*a^2 + 3*b^2))/e - (8*a*(5*a^2 + 3*b^2)*(atan(tan(d/2 + (e*x)/2)) - (e*x)/2))/e
Time = 0.17 (sec) , antiderivative size = 239, normalized size of antiderivative = 1.52 \[ \int (2 a+2 b \cos (d+e x)+2 a \sin (d+e x))^3 \, dx=\frac {-\frac {16 \cos \left (e x +d \right )^{3} a^{3}}{3}-8 \cos \left (e x +d \right )^{3} a \,b^{2}+8 \cos \left (e x +d \right )^{2} \sin \left (e x +d \right ) b^{3}+12 \cos \left (e x +d \right )^{2} a^{3} e x -24 \cos \left (e x +d \right )^{2} a^{2} b +12 \cos \left (e x +d \right )^{2} a \,b^{2} e x -8 \cos \left (e x +d \right ) \sin \left (e x +d \right )^{2} a^{3}-12 \cos \left (e x +d \right ) \sin \left (e x +d \right ) a^{3}+12 \cos \left (e x +d \right ) \sin \left (e x +d \right ) a \,b^{2}-24 \cos \left (e x +d \right ) a^{3}+8 \sin \left (e x +d \right )^{3} a^{2} b +\frac {16 \sin \left (e x +d \right )^{3} b^{3}}{3}+12 \sin \left (e x +d \right )^{2} a^{3} e x +12 \sin \left (e x +d \right )^{2} a \,b^{2} e x +24 \sin \left (e x +d \right ) a^{2} b +8 a^{3} e x}{e} \] Input:
int((2*a+2*b*cos(e*x+d)+2*a*sin(e*x+d))^3,x)
Output:
(4*( - 4*cos(d + e*x)**3*a**3 - 6*cos(d + e*x)**3*a*b**2 + 6*cos(d + e*x)* *2*sin(d + e*x)*b**3 + 9*cos(d + e*x)**2*a**3*e*x - 18*cos(d + e*x)**2*a** 2*b + 9*cos(d + e*x)**2*a*b**2*e*x - 6*cos(d + e*x)*sin(d + e*x)**2*a**3 - 9*cos(d + e*x)*sin(d + e*x)*a**3 + 9*cos(d + e*x)*sin(d + e*x)*a*b**2 - 1 8*cos(d + e*x)*a**3 + 6*sin(d + e*x)**3*a**2*b + 4*sin(d + e*x)**3*b**3 + 9*sin(d + e*x)**2*a**3*e*x + 9*sin(d + e*x)**2*a*b**2*e*x + 18*sin(d + e*x )*a**2*b + 6*a**3*e*x))/(3*e)