Integrand size = 20, antiderivative size = 170 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=\frac {1}{2} a \left (2 a^2+3 \left (b^2+c^2\right )\right ) x-\frac {c \left (11 a^2+4 \left (b^2+c^2\right )\right ) \cos (d+e x)}{6 e}+\frac {b \left (11 a^2+4 \left (b^2+c^2\right )\right ) \sin (d+e x)}{6 e}-\frac {5 (a c \cos (d+e x)-a b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))}{6 e}-\frac {(c \cos (d+e x)-b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))^2}{3 e} \] Output:
1/2*a*(2*a^2+3*b^2+3*c^2)*x-1/6*c*(11*a^2+4*b^2+4*c^2)*cos(e*x+d)/e+1/6*b* (11*a^2+4*b^2+4*c^2)*sin(e*x+d)/e-5/6*(a*c*cos(e*x+d)-a*b*sin(e*x+d))*(a+b *cos(e*x+d)+c*sin(e*x+d))/e-1/3*(c*cos(e*x+d)-b*sin(e*x+d))*(a+b*cos(e*x+d )+c*sin(e*x+d))^2/e
Time = 1.36 (sec) , antiderivative size = 144, normalized size of antiderivative = 0.85 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=\frac {6 a \left (2 a^2+3 \left (b^2+c^2\right )\right ) (d+e x)-9 c \left (4 a^2+b^2+c^2\right ) \cos (d+e x)-18 a b c \cos (2 (d+e x))+c \left (-3 b^2+c^2\right ) \cos (3 (d+e x))+9 b \left (4 a^2+b^2+c^2\right ) \sin (d+e x)+9 a \left (b^2-c^2\right ) \sin (2 (d+e x))+b \left (b^2-3 c^2\right ) \sin (3 (d+e x))}{12 e} \] Input:
Integrate[(a + b*Cos[d + e*x] + c*Sin[d + e*x])^3,x]
Output:
(6*a*(2*a^2 + 3*(b^2 + c^2))*(d + e*x) - 9*c*(4*a^2 + b^2 + c^2)*Cos[d + e *x] - 18*a*b*c*Cos[2*(d + e*x)] + c*(-3*b^2 + c^2)*Cos[3*(d + e*x)] + 9*b* (4*a^2 + b^2 + c^2)*Sin[d + e*x] + 9*a*(b^2 - c^2)*Sin[2*(d + e*x)] + b*(b ^2 - 3*c^2)*Sin[3*(d + e*x)])/(12*e)
Time = 0.49 (sec) , antiderivative size = 180, normalized size of antiderivative = 1.06, number of steps used = 5, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {3042, 3599, 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 (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int (a+b \cos (d+e x)+c \sin (d+e x))^3dx\) |
\(\Big \downarrow \) 3599 |
\(\displaystyle \frac {1}{3} \int (a+b \cos (d+e x)+c \sin (d+e x)) \left (3 a^2+5 b \cos (d+e x) a+5 c \sin (d+e x) a+2 \left (b^2+c^2\right )\right )dx-\frac {(c \cos (d+e x)-b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))^2}{3 e}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{3} \int (a+b \cos (d+e x)+c \sin (d+e x)) \left (3 a^2+5 b \cos (d+e x) a+5 c \sin (d+e x) a+2 \left (b^2+c^2\right )\right )dx-\frac {(c \cos (d+e x)-b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))^2}{3 e}\) |
\(\Big \downarrow \) 3625 |
\(\displaystyle \frac {1}{3} \left (\frac {\int \left (3 \left (2 a^2+3 \left (b^2+c^2\right )\right ) a^2+b \left (11 a^2+4 \left (b^2+c^2\right )\right ) \cos (d+e x) a+c \left (11 a^2+4 \left (b^2+c^2\right )\right ) \sin (d+e x) a\right )dx}{2 a}-\frac {5 (a c \cos (d+e x)-a b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))}{2 e}\right )-\frac {(c \cos (d+e x)-b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))^2}{3 e}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {1}{3} \left (\frac {\frac {a b \left (11 a^2+4 \left (b^2+c^2\right )\right ) \sin (d+e x)}{e}-\frac {a c \left (11 a^2+4 \left (b^2+c^2\right )\right ) \cos (d+e x)}{e}+3 a^2 x \left (2 a^2+3 \left (b^2+c^2\right )\right )}{2 a}-\frac {5 (a c \cos (d+e x)-a b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))}{2 e}\right )-\frac {(c \cos (d+e x)-b \sin (d+e x)) (a+b \cos (d+e x)+c \sin (d+e x))^2}{3 e}\) |
Input:
Int[(a + b*Cos[d + e*x] + c*Sin[d + e*x])^3,x]
Output:
-1/3*((c*Cos[d + e*x] - b*Sin[d + e*x])*(a + b*Cos[d + e*x] + c*Sin[d + e* x])^2)/e + ((-5*(a*c*Cos[d + e*x] - a*b*Sin[d + e*x])*(a + b*Cos[d + e*x] + c*Sin[d + e*x]))/(2*e) + (3*a^2*(2*a^2 + 3*(b^2 + c^2))*x - (a*c*(11*a^2 + 4*(b^2 + c^2))*Cos[d + e*x])/e + (a*b*(11*a^2 + 4*(b^2 + c^2))*Sin[d + e*x])/e)/(2*a))/3
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.43 (sec) , antiderivative size = 177, normalized size of antiderivative = 1.04
\[\frac {\frac {b^{3} \left (2+\cos \left (e x +d \right )^{2}\right ) \sin \left (e x +d \right )}{3}-b^{2} c \cos \left (e x +d \right )^{3}+b \,c^{2} \sin \left (e x +d \right )^{3}-\frac {c^{3} \left (2+\sin \left (e x +d \right )^{2}\right ) \cos \left (e x +d \right )}{3}+3 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 )-3 a b c \cos \left (e x +d \right )^{2}+3 a \,c^{2} \left (-\frac {\sin \left (e x +d \right ) \cos \left (e x +d \right )}{2}+\frac {e x}{2}+\frac {d}{2}\right )+3 \sin \left (e x +d \right ) a^{2} b -3 a^{2} c \cos \left (e x +d \right )+a^{3} \left (e x +d \right )}{e}\]
Input:
int((a+b*cos(e*x+d)+c*sin(e*x+d))^3,x)
Output:
1/e*(1/3*b^3*(2+cos(e*x+d)^2)*sin(e*x+d)-b^2*c*cos(e*x+d)^3+b*c^2*sin(e*x+ d)^3-1/3*c^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*b*c*cos(e*x+d)^2+3*a*c^2*(-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^2*c*cos(e*x+d)+a^3*(e*x+d))
Time = 0.08 (sec) , antiderivative size = 147, normalized size of antiderivative = 0.86 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=-\frac {18 \, a b c \cos \left (e x + d\right )^{2} + 2 \, {\left (3 \, b^{2} c - c^{3}\right )} \cos \left (e x + d\right )^{3} - 3 \, {\left (2 \, a^{3} + 3 \, a b^{2} + 3 \, a c^{2}\right )} e x + 6 \, {\left (3 \, a^{2} c + c^{3}\right )} \cos \left (e x + d\right ) - {\left (18 \, a^{2} b + 4 \, b^{3} + 6 \, b c^{2} + 2 \, {\left (b^{3} - 3 \, b c^{2}\right )} \cos \left (e x + d\right )^{2} + 9 \, {\left (a b^{2} - a c^{2}\right )} \cos \left (e x + d\right )\right )} \sin \left (e x + d\right )}{6 \, e} \] Input:
integrate((a+b*cos(e*x+d)+c*sin(e*x+d))^3,x, algorithm="fricas")
Output:
-1/6*(18*a*b*c*cos(e*x + d)^2 + 2*(3*b^2*c - c^3)*cos(e*x + d)^3 - 3*(2*a^ 3 + 3*a*b^2 + 3*a*c^2)*e*x + 6*(3*a^2*c + c^3)*cos(e*x + d) - (18*a^2*b + 4*b^3 + 6*b*c^2 + 2*(b^3 - 3*b*c^2)*cos(e*x + d)^2 + 9*(a*b^2 - a*c^2)*cos (e*x + d))*sin(e*x + d))/e
Time = 0.16 (sec) , antiderivative size = 294, normalized size of antiderivative = 1.73 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=\begin {cases} a^{3} x + \frac {3 a^{2} b \sin {\left (d + e x \right )}}{e} - \frac {3 a^{2} c \cos {\left (d + e x \right )}}{e} + \frac {3 a b^{2} x \sin ^{2}{\left (d + e x \right )}}{2} + \frac {3 a b^{2} x \cos ^{2}{\left (d + e x \right )}}{2} + \frac {3 a b^{2} \sin {\left (d + e x \right )} \cos {\left (d + e x \right )}}{2 e} - \frac {3 a b c \cos ^{2}{\left (d + e x \right )}}{e} + \frac {3 a c^{2} x \sin ^{2}{\left (d + e x \right )}}{2} + \frac {3 a c^{2} x \cos ^{2}{\left (d + e x \right )}}{2} - \frac {3 a c^{2} \sin {\left (d + e x \right )} \cos {\left (d + e x \right )}}{2 e} + \frac {2 b^{3} \sin ^{3}{\left (d + e x \right )}}{3 e} + \frac {b^{3} \sin {\left (d + e x \right )} \cos ^{2}{\left (d + e x \right )}}{e} - \frac {b^{2} c \cos ^{3}{\left (d + e x \right )}}{e} + \frac {b c^{2} \sin ^{3}{\left (d + e x \right )}}{e} - \frac {c^{3} \sin ^{2}{\left (d + e x \right )} \cos {\left (d + e x \right )}}{e} - \frac {2 c^{3} \cos ^{3}{\left (d + e x \right )}}{3 e} & \text {for}\: e \neq 0 \\x \left (a + b \cos {\left (d \right )} + c \sin {\left (d \right )}\right )^{3} & \text {otherwise} \end {cases} \] Input:
integrate((a+b*cos(e*x+d)+c*sin(e*x+d))**3,x)
Output:
Piecewise((a**3*x + 3*a**2*b*sin(d + e*x)/e - 3*a**2*c*cos(d + e*x)/e + 3* a*b**2*x*sin(d + e*x)**2/2 + 3*a*b**2*x*cos(d + e*x)**2/2 + 3*a*b**2*sin(d + e*x)*cos(d + e*x)/(2*e) - 3*a*b*c*cos(d + e*x)**2/e + 3*a*c**2*x*sin(d + e*x)**2/2 + 3*a*c**2*x*cos(d + e*x)**2/2 - 3*a*c**2*sin(d + e*x)*cos(d + e*x)/(2*e) + 2*b**3*sin(d + e*x)**3/(3*e) + b**3*sin(d + e*x)*cos(d + e*x )**2/e - b**2*c*cos(d + e*x)**3/e + b*c**2*sin(d + e*x)**3/e - c**3*sin(d + e*x)**2*cos(d + e*x)/e - 2*c**3*cos(d + e*x)**3/(3*e), Ne(e, 0)), (x*(a + b*cos(d) + c*sin(d))**3, True))
Time = 0.04 (sec) , antiderivative size = 189, normalized size of antiderivative = 1.11 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=-\frac {b^{2} c \cos \left (e x + d\right )^{3}}{e} + \frac {b c^{2} \sin \left (e x + d\right )^{3}}{e} + a^{3} x - \frac {{\left (\sin \left (e x + d\right )^{3} - 3 \, \sin \left (e x + d\right )\right )} b^{3}}{3 \, e} + \frac {{\left (\cos \left (e x + d\right )^{3} - 3 \, \cos \left (e x + d\right )\right )} c^{3}}{3 \, e} - 3 \, a^{2} {\left (\frac {c \cos \left (e x + d\right )}{e} - \frac {b \sin \left (e x + d\right )}{e}\right )} - \frac {3}{4} \, {\left (\frac {4 \, b c \cos \left (e x + d\right )^{2}}{e} - \frac {{\left (2 \, e x + 2 \, d + \sin \left (2 \, e x + 2 \, d\right )\right )} b^{2}}{e} - \frac {{\left (2 \, e x + 2 \, d - \sin \left (2 \, e x + 2 \, d\right )\right )} c^{2}}{e}\right )} a \] Input:
integrate((a+b*cos(e*x+d)+c*sin(e*x+d))^3,x, algorithm="maxima")
Output:
-b^2*c*cos(e*x + d)^3/e + b*c^2*sin(e*x + d)^3/e + a^3*x - 1/3*(sin(e*x + d)^3 - 3*sin(e*x + d))*b^3/e + 1/3*(cos(e*x + d)^3 - 3*cos(e*x + d))*c^3/e - 3*a^2*(c*cos(e*x + d)/e - b*sin(e*x + d)/e) - 3/4*(4*b*c*cos(e*x + d)^2 /e - (2*e*x + 2*d + sin(2*e*x + 2*d))*b^2/e - (2*e*x + 2*d - sin(2*e*x + 2 *d))*c^2/e)*a
Time = 0.13 (sec) , antiderivative size = 167, normalized size of antiderivative = 0.98 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=-\frac {3 \, a b c \cos \left (2 \, e x + 2 \, d\right )}{2 \, e} + \frac {1}{2} \, {\left (2 \, a^{3} + 3 \, a b^{2} + 3 \, a c^{2}\right )} x - \frac {{\left (3 \, b^{2} c - c^{3}\right )} \cos \left (3 \, e x + 3 \, d\right )}{12 \, e} - \frac {3 \, {\left (4 \, a^{2} c + b^{2} c + c^{3}\right )} \cos \left (e x + d\right )}{4 \, e} + \frac {{\left (b^{3} - 3 \, b c^{2}\right )} \sin \left (3 \, e x + 3 \, d\right )}{12 \, e} + \frac {3 \, {\left (a b^{2} - a c^{2}\right )} \sin \left (2 \, e x + 2 \, d\right )}{4 \, e} + \frac {3 \, {\left (4 \, a^{2} b + b^{3} + b c^{2}\right )} \sin \left (e x + d\right )}{4 \, e} \] Input:
integrate((a+b*cos(e*x+d)+c*sin(e*x+d))^3,x, algorithm="giac")
Output:
-3/2*a*b*c*cos(2*e*x + 2*d)/e + 1/2*(2*a^3 + 3*a*b^2 + 3*a*c^2)*x - 1/12*( 3*b^2*c - c^3)*cos(3*e*x + 3*d)/e - 3/4*(4*a^2*c + b^2*c + c^3)*cos(e*x + d)/e + 1/12*(b^3 - 3*b*c^2)*sin(3*e*x + 3*d)/e + 3/4*(a*b^2 - a*c^2)*sin(2 *e*x + 2*d)/e + 3/4*(4*a^2*b + b^3 + b*c^2)*sin(e*x + d)/e
Time = 16.68 (sec) , antiderivative size = 333, normalized size of antiderivative = 1.96 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=\frac {a\,\mathrm {atan}\left (\frac {a\,\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )\,\left (2\,a^2+3\,b^2+3\,c^2\right )}{2\,a^3+3\,a\,b^2+3\,a\,c^2}\right )\,\left (2\,a^2+3\,b^2+3\,c^2\right )}{e}-\frac {a\,\left (\mathrm {atan}\left (\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )\right )-\frac {e\,x}{2}\right )\,\left (2\,a^2+3\,b^2+3\,c^2\right )}{e}-\frac {{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^2\,\left (12\,a^2\,c-12\,b\,a\,c+4\,c^3\right )-{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^3\,\left (12\,a^2\,b+\frac {4\,b^3}{3}+8\,b\,c^2\right )-\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )\,\left (6\,a^2\,b+3\,a\,b^2-3\,a\,c^2+2\,b^3\right )+{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^4\,\left (6\,c\,a^2-12\,c\,a\,b+6\,c\,b^2\right )+6\,a^2\,c+2\,b^2\,c-{\mathrm {tan}\left (\frac {d}{2}+\frac {e\,x}{2}\right )}^5\,\left (6\,a^2\,b-3\,a\,b^2+3\,a\,c^2+2\,b^3\right )+\frac {4\,c^3}{3}}{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 )} \] Input:
int((a + b*cos(d + e*x) + c*sin(d + e*x))^3,x)
Output:
(a*atan((a*tan(d/2 + (e*x)/2)*(2*a^2 + 3*b^2 + 3*c^2))/(3*a*b^2 + 3*a*c^2 + 2*a^3))*(2*a^2 + 3*b^2 + 3*c^2))/e - (a*(atan(tan(d/2 + (e*x)/2)) - (e*x )/2)*(2*a^2 + 3*b^2 + 3*c^2))/e - (tan(d/2 + (e*x)/2)^2*(12*a^2*c + 4*c^3 - 12*a*b*c) - tan(d/2 + (e*x)/2)^3*(12*a^2*b + 8*b*c^2 + (4*b^3)/3) - tan( d/2 + (e*x)/2)*(3*a*b^2 + 6*a^2*b - 3*a*c^2 + 2*b^3) + tan(d/2 + (e*x)/2)^ 4*(6*a^2*c + 6*b^2*c - 12*a*b*c) + 6*a^2*c + 2*b^2*c - tan(d/2 + (e*x)/2)^ 5*(6*a^2*b - 3*a*b^2 + 3*a*c^2 + 2*b^3) + (4*c^3)/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))
Time = 0.17 (sec) , antiderivative size = 242, normalized size of antiderivative = 1.42 \[ \int (a+b \cos (d+e x)+c \sin (d+e x))^3 \, dx=\frac {-6 \cos \left (e x +d \right )^{3} b^{2} c -4 \cos \left (e x +d \right )^{3} c^{3}+6 \cos \left (e x +d \right )^{2} \sin \left (e x +d \right ) b^{3}+9 \cos \left (e x +d \right )^{2} a \,b^{2} e x -18 \cos \left (e x +d \right )^{2} a b c +9 \cos \left (e x +d \right )^{2} a \,c^{2} e x -6 \cos \left (e x +d \right ) \sin \left (e x +d \right )^{2} c^{3}+9 \cos \left (e x +d \right ) \sin \left (e x +d \right ) a \,b^{2}-9 \cos \left (e x +d \right ) \sin \left (e x +d \right ) a \,c^{2}-18 \cos \left (e x +d \right ) a^{2} c +4 \sin \left (e x +d \right )^{3} b^{3}+6 \sin \left (e x +d \right )^{3} b \,c^{2}+9 \sin \left (e x +d \right )^{2} a \,b^{2} e x +9 \sin \left (e x +d \right )^{2} a \,c^{2} e x +18 \sin \left (e x +d \right ) a^{2} b +6 a^{3} e x}{6 e} \] Input:
int((a+b*cos(e*x+d)+c*sin(e*x+d))^3,x)
Output:
( - 6*cos(d + e*x)**3*b**2*c - 4*cos(d + e*x)**3*c**3 + 6*cos(d + e*x)**2* sin(d + e*x)*b**3 + 9*cos(d + e*x)**2*a*b**2*e*x - 18*cos(d + e*x)**2*a*b* c + 9*cos(d + e*x)**2*a*c**2*e*x - 6*cos(d + e*x)*sin(d + e*x)**2*c**3 + 9 *cos(d + e*x)*sin(d + e*x)*a*b**2 - 9*cos(d + e*x)*sin(d + e*x)*a*c**2 - 1 8*cos(d + e*x)*a**2*c + 4*sin(d + e*x)**3*b**3 + 6*sin(d + e*x)**3*b*c**2 + 9*sin(d + e*x)**2*a*b**2*e*x + 9*sin(d + e*x)**2*a*c**2*e*x + 18*sin(d + e*x)*a**2*b + 6*a**3*e*x)/(6*e)