Integrand size = 30, antiderivative size = 161 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=\frac {5 a b x}{8}-\frac {\left (a^2+b^2\right ) \cos (c+d x)}{d}+\frac {\left (2 a^2+3 b^2\right ) \cos ^3(c+d x)}{3 d}-\frac {\left (a^2+3 b^2\right ) \cos ^5(c+d x)}{5 d}+\frac {b^2 \cos ^7(c+d x)}{7 d}-\frac {5 a b \cos (c+d x) \sin (c+d x)}{8 d}-\frac {5 a b \cos (c+d x) \sin ^3(c+d x)}{12 d}-\frac {a b \cos (c+d x) \sin ^5(c+d x)}{3 d} \] Output:
5/8*a*b*x-(a^2+b^2)*cos(d*x+c)/d+1/3*(2*a^2+3*b^2)*cos(d*x+c)^3/d-1/5*(a^2 +3*b^2)*cos(d*x+c)^5/d+1/7*b^2*cos(d*x+c)^7/d-5/8*a*b*cos(d*x+c)*sin(d*x+c )/d-5/12*a*b*cos(d*x+c)*sin(d*x+c)^3/d-1/3*a*b*cos(d*x+c)*sin(d*x+c)^5/d
Time = 0.28 (sec) , antiderivative size = 134, normalized size of antiderivative = 0.83 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=\frac {4200 a b c+4200 a b d x-525 \left (8 a^2+7 b^2\right ) \cos (c+d x)+35 \left (20 a^2+21 b^2\right ) \cos (3 (c+d x))-84 a^2 \cos (5 (c+d x))-147 b^2 \cos (5 (c+d x))+15 b^2 \cos (7 (c+d x))-3150 a b \sin (2 (c+d x))+630 a b \sin (4 (c+d x))-70 a b \sin (6 (c+d x))}{6720 d} \] Input:
Integrate[Sin[c + d*x]*(a*Sin[c + d*x]^2 + b*Sin[c + d*x]^3)^2,x]
Output:
(4200*a*b*c + 4200*a*b*d*x - 525*(8*a^2 + 7*b^2)*Cos[c + d*x] + 35*(20*a^2 + 21*b^2)*Cos[3*(c + d*x)] - 84*a^2*Cos[5*(c + d*x)] - 147*b^2*Cos[5*(c + d*x)] + 15*b^2*Cos[7*(c + d*x)] - 3150*a*b*Sin[2*(c + d*x)] + 630*a*b*Sin [4*(c + d*x)] - 70*a*b*Sin[6*(c + d*x)])/(6720*d)
Time = 0.79 (sec) , antiderivative size = 161, normalized size of antiderivative = 1.00, number of steps used = 15, number of rules used = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.467, Rules used = {3042, 4893, 3042, 3268, 3042, 3115, 3042, 3115, 3042, 3115, 24, 3492, 290, 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 \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sin (c+d x) \left (a \sin (c+d x)^2+b \sin (c+d x)^3\right )^2dx\) |
\(\Big \downarrow \) 4893 |
\(\displaystyle \int \sin ^5(c+d x) (a+b \sin (c+d x))^2dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sin (c+d x)^5 (a+b \sin (c+d x))^2dx\) |
\(\Big \downarrow \) 3268 |
\(\displaystyle \int \sin ^5(c+d x) \left (a^2+b^2 \sin ^2(c+d x)\right )dx+2 a b \int \sin ^6(c+d x)dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sin (c+d x)^5 \left (a^2+b^2 \sin (c+d x)^2\right )dx+2 a b \int \sin (c+d x)^6dx\) |
\(\Big \downarrow \) 3115 |
\(\displaystyle \int \sin (c+d x)^5 \left (a^2+b^2 \sin (c+d x)^2\right )dx+2 a b \left (\frac {5}{6} \int \sin ^4(c+d x)dx-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sin (c+d x)^5 \left (a^2+b^2 \sin (c+d x)^2\right )dx+2 a b \left (\frac {5}{6} \int \sin (c+d x)^4dx-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )\) |
\(\Big \downarrow \) 3115 |
\(\displaystyle \int \sin (c+d x)^5 \left (a^2+b^2 \sin (c+d x)^2\right )dx+2 a b \left (\frac {5}{6} \left (\frac {3}{4} \int \sin ^2(c+d x)dx-\frac {\sin ^3(c+d x) \cos (c+d x)}{4 d}\right )-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sin (c+d x)^5 \left (a^2+b^2 \sin (c+d x)^2\right )dx+2 a b \left (\frac {5}{6} \left (\frac {3}{4} \int \sin (c+d x)^2dx-\frac {\sin ^3(c+d x) \cos (c+d x)}{4 d}\right )-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )\) |
\(\Big \downarrow \) 3115 |
\(\displaystyle \int \sin (c+d x)^5 \left (a^2+b^2 \sin (c+d x)^2\right )dx+2 a b \left (\frac {5}{6} \left (\frac {3}{4} \left (\frac {\int 1dx}{2}-\frac {\sin (c+d x) \cos (c+d x)}{2 d}\right )-\frac {\sin ^3(c+d x) \cos (c+d x)}{4 d}\right )-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )\) |
\(\Big \downarrow \) 24 |
\(\displaystyle \int \sin (c+d x)^5 \left (a^2+b^2 \sin (c+d x)^2\right )dx+2 a b \left (\frac {5}{6} \left (\frac {3}{4} \left (\frac {x}{2}-\frac {\sin (c+d x) \cos (c+d x)}{2 d}\right )-\frac {\sin ^3(c+d x) \cos (c+d x)}{4 d}\right )-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )\) |
\(\Big \downarrow \) 3492 |
\(\displaystyle 2 a b \left (\frac {5}{6} \left (\frac {3}{4} \left (\frac {x}{2}-\frac {\sin (c+d x) \cos (c+d x)}{2 d}\right )-\frac {\sin ^3(c+d x) \cos (c+d x)}{4 d}\right )-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )-\frac {\int \left (1-\cos ^2(c+d x)\right )^2 \left (a^2+b^2-b^2 \cos ^2(c+d x)\right )d\cos (c+d x)}{d}\) |
\(\Big \downarrow \) 290 |
\(\displaystyle 2 a b \left (\frac {5}{6} \left (\frac {3}{4} \left (\frac {x}{2}-\frac {\sin (c+d x) \cos (c+d x)}{2 d}\right )-\frac {\sin ^3(c+d x) \cos (c+d x)}{4 d}\right )-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )-\frac {\int \left (-b^2 \cos ^6(c+d x)+\left (a^2+3 b^2\right ) \cos ^4(c+d x)-\left (2 a^2+3 b^2\right ) \cos ^2(c+d x)+a^2 \left (\frac {b^2}{a^2}+1\right )\right )d\cos (c+d x)}{d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle 2 a b \left (\frac {5}{6} \left (\frac {3}{4} \left (\frac {x}{2}-\frac {\sin (c+d x) \cos (c+d x)}{2 d}\right )-\frac {\sin ^3(c+d x) \cos (c+d x)}{4 d}\right )-\frac {\sin ^5(c+d x) \cos (c+d x)}{6 d}\right )-\frac {\frac {1}{5} \left (a^2+3 b^2\right ) \cos ^5(c+d x)-\frac {1}{3} \left (2 a^2+3 b^2\right ) \cos ^3(c+d x)+\left (a^2+b^2\right ) \cos (c+d x)-\frac {1}{7} b^2 \cos ^7(c+d x)}{d}\) |
Input:
Int[Sin[c + d*x]*(a*Sin[c + d*x]^2 + b*Sin[c + d*x]^3)^2,x]
Output:
-(((a^2 + b^2)*Cos[c + d*x] - ((2*a^2 + 3*b^2)*Cos[c + d*x]^3)/3 + ((a^2 + 3*b^2)*Cos[c + d*x]^5)/5 - (b^2*Cos[c + d*x]^7)/7)/d) + 2*a*b*(-1/6*(Cos[ c + d*x]*Sin[c + d*x]^5)/d + (5*(-1/4*(Cos[c + d*x]*Sin[c + d*x]^3)/d + (3 *(x/2 - (Cos[c + d*x]*Sin[c + d*x])/(2*d)))/4))/6)
Int[((a_) + (b_.)*(x_)^2)^(p_.)*((c_) + (d_.)*(x_)^2)^(q_.), x_Symbol] :> I nt[ExpandIntegrand[(a + b*x^2)^p*(c + d*x^2)^q, x], x] /; FreeQ[{a, b, c, d }, x] && NeQ[b*c - a*d, 0] && IGtQ[p, 0] && IGtQ[q, 0]
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[((b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*sin[(e_.) + (f_.)*(x _)])^2, x_Symbol] :> Simp[2*c*(d/b) Int[(b*Sin[e + f*x])^(m + 1), x], x] + Int[(b*Sin[e + f*x])^m*(c^2 + d^2*Sin[e + f*x]^2), x] /; FreeQ[{b, c, d, e, f, m}, x]
Int[sin[(e_.) + (f_.)*(x_)]^(m_.)*((A_) + (C_.)*sin[(e_.) + (f_.)*(x_)]^2), x_Symbol] :> Simp[-f^(-1) Subst[Int[(1 - x^2)^((m - 1)/2)*(A + C - C*x^2 ), x], x, Cos[e + f*x]], x] /; FreeQ[{e, f, A, C}, x] && IGtQ[(m + 1)/2, 0]
Int[(u_)*((a_)*(F_)[(c_.) + (d_.)*(x_)]^(p_.) + (b_.)*(F_)[(c_.) + (d_.)*(x _)]^(q_.))^(n_.), x_Symbol] :> Int[ActivateTrig[u*F[c + d*x]^(n*p)*(a + b*F [c + d*x]^(q - p))^n], x] /; FreeQ[{a, b, c, d, p, q}, x] && InertTrigQ[F] && IntegerQ[n] && PosQ[q - p]
Time = 52.23 (sec) , antiderivative size = 125, normalized size of antiderivative = 0.78
method | result | size |
derivativedivides | \(\frac {-\frac {b^{2} \left (\frac {16}{5}+\sin \left (d x +c \right )^{6}+\frac {6 \sin \left (d x +c \right )^{4}}{5}+\frac {8 \sin \left (d x +c \right )^{2}}{5}\right ) \cos \left (d x +c \right )}{7}+2 a b \left (-\frac {\left (\sin \left (d x +c \right )^{5}+\frac {5 \sin \left (d x +c \right )^{3}}{4}+\frac {15 \sin \left (d x +c \right )}{8}\right ) \cos \left (d x +c \right )}{6}+\frac {5 d x}{16}+\frac {5 c}{16}\right )-\frac {a^{2} \left (\frac {8}{3}+\sin \left (d x +c \right )^{4}+\frac {4 \sin \left (d x +c \right )^{2}}{3}\right ) \cos \left (d x +c \right )}{5}}{d}\) | \(125\) |
default | \(\frac {-\frac {b^{2} \left (\frac {16}{5}+\sin \left (d x +c \right )^{6}+\frac {6 \sin \left (d x +c \right )^{4}}{5}+\frac {8 \sin \left (d x +c \right )^{2}}{5}\right ) \cos \left (d x +c \right )}{7}+2 a b \left (-\frac {\left (\sin \left (d x +c \right )^{5}+\frac {5 \sin \left (d x +c \right )^{3}}{4}+\frac {15 \sin \left (d x +c \right )}{8}\right ) \cos \left (d x +c \right )}{6}+\frac {5 d x}{16}+\frac {5 c}{16}\right )-\frac {a^{2} \left (\frac {8}{3}+\sin \left (d x +c \right )^{4}+\frac {4 \sin \left (d x +c \right )^{2}}{3}\right ) \cos \left (d x +c \right )}{5}}{d}\) | \(125\) |
parts | \(-\frac {a^{2} \left (\frac {8}{3}+\sin \left (d x +c \right )^{4}+\frac {4 \sin \left (d x +c \right )^{2}}{3}\right ) \cos \left (d x +c \right )}{5 d}-\frac {b^{2} \left (\frac {16}{5}+\sin \left (d x +c \right )^{6}+\frac {6 \sin \left (d x +c \right )^{4}}{5}+\frac {8 \sin \left (d x +c \right )^{2}}{5}\right ) \cos \left (d x +c \right )}{7 d}+\frac {2 a b \left (-\frac {\left (\sin \left (d x +c \right )^{5}+\frac {5 \sin \left (d x +c \right )^{3}}{4}+\frac {15 \sin \left (d x +c \right )}{8}\right ) \cos \left (d x +c \right )}{6}+\frac {5 d x}{16}+\frac {5 c}{16}\right )}{d}\) | \(130\) |
parallelrisch | \(\frac {\left (700 a^{2}+735 b^{2}\right ) \cos \left (3 d x +3 c \right )+\left (-84 a^{2}-147 b^{2}\right ) \cos \left (5 d x +5 c \right )+15 b^{2} \cos \left (7 d x +7 c \right )-3150 a b \sin \left (2 d x +2 c \right )+630 a b \sin \left (4 d x +4 c \right )-70 a b \sin \left (6 d x +6 c \right )+\left (-4200 a^{2}-3675 b^{2}\right ) \cos \left (d x +c \right )+4200 a b x d -3584 a^{2}-3072 b^{2}}{6720 d}\) | \(136\) |
risch | \(\frac {5 a b x}{8}-\frac {5 a^{2} \cos \left (d x +c \right )}{8 d}-\frac {35 \cos \left (d x +c \right ) b^{2}}{64 d}+\frac {b^{2} \cos \left (7 d x +7 c \right )}{448 d}-\frac {a b \sin \left (6 d x +6 c \right )}{96 d}-\frac {\cos \left (5 d x +5 c \right ) a^{2}}{80 d}-\frac {7 \cos \left (5 d x +5 c \right ) b^{2}}{320 d}+\frac {3 a b \sin \left (4 d x +4 c \right )}{32 d}+\frac {5 \cos \left (3 d x +3 c \right ) a^{2}}{48 d}+\frac {7 \cos \left (3 d x +3 c \right ) b^{2}}{64 d}-\frac {15 a b \sin \left (2 d x +2 c \right )}{32 d}\) | \(168\) |
norman | \(\frac {-\frac {112 a^{2}+96 b^{2}}{105 d}+\frac {5 a b x}{8}-\frac {32 a^{2} \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{8}}{3 d}-\frac {\left (80 a^{2}+96 b^{2}\right ) \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{6}}{3 d}-\frac {\left (112 a^{2}+96 b^{2}\right ) \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{2}}{15 d}-\frac {\left (112 a^{2}+96 b^{2}\right ) \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{4}}{5 d}-\frac {5 a b \tan \left (\frac {c}{2}+\frac {d x}{2}\right )}{4 d}-\frac {25 a b \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{3}}{3 d}-\frac {283 a b \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{5}}{12 d}+\frac {283 a b \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{9}}{12 d}+\frac {25 a b \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{11}}{3 d}+\frac {5 a b \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{13}}{4 d}+\frac {35 a b x \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{2}}{8}+\frac {105 a b x \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{4}}{8}+\frac {175 a b x \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{6}}{8}+\frac {175 a b x \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{8}}{8}+\frac {105 a b x \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{10}}{8}+\frac {35 a b x \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{12}}{8}+\frac {5 a b x \tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{14}}{8}}{\left (1+\tan \left (\frac {c}{2}+\frac {d x}{2}\right )^{2}\right )^{7}}\) | \(357\) |
orering | \(\text {Expression too large to display}\) | \(36832\) |
Input:
int(sin(d*x+c)*(a*sin(d*x+c)^2+b*sin(d*x+c)^3)^2,x,method=_RETURNVERBOSE)
Output:
1/d*(-1/7*b^2*(16/5+sin(d*x+c)^6+6/5*sin(d*x+c)^4+8/5*sin(d*x+c)^2)*cos(d* x+c)+2*a*b*(-1/6*(sin(d*x+c)^5+5/4*sin(d*x+c)^3+15/8*sin(d*x+c))*cos(d*x+c )+5/16*d*x+5/16*c)-1/5*a^2*(8/3+sin(d*x+c)^4+4/3*sin(d*x+c)^2)*cos(d*x+c))
Time = 0.08 (sec) , antiderivative size = 123, normalized size of antiderivative = 0.76 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=\frac {120 \, b^{2} \cos \left (d x + c\right )^{7} - 168 \, {\left (a^{2} + 3 \, b^{2}\right )} \cos \left (d x + c\right )^{5} + 525 \, a b d x + 280 \, {\left (2 \, a^{2} + 3 \, b^{2}\right )} \cos \left (d x + c\right )^{3} - 840 \, {\left (a^{2} + b^{2}\right )} \cos \left (d x + c\right ) - 35 \, {\left (8 \, a b \cos \left (d x + c\right )^{5} - 26 \, a b \cos \left (d x + c\right )^{3} + 33 \, a b \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{840 \, d} \] Input:
integrate(sin(d*x+c)*(a*sin(d*x+c)^2+b*sin(d*x+c)^3)^2,x, algorithm="frica s")
Output:
1/840*(120*b^2*cos(d*x + c)^7 - 168*(a^2 + 3*b^2)*cos(d*x + c)^5 + 525*a*b *d*x + 280*(2*a^2 + 3*b^2)*cos(d*x + c)^3 - 840*(a^2 + b^2)*cos(d*x + c) - 35*(8*a*b*cos(d*x + c)^5 - 26*a*b*cos(d*x + c)^3 + 33*a*b*cos(d*x + c))*s in(d*x + c))/d
Leaf count of result is larger than twice the leaf count of optimal. 326 vs. \(2 (148) = 296\).
Time = 0.53 (sec) , antiderivative size = 326, normalized size of antiderivative = 2.02 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=\begin {cases} - \frac {a^{2} \sin ^{4}{\left (c + d x \right )} \cos {\left (c + d x \right )}}{d} - \frac {4 a^{2} \sin ^{2}{\left (c + d x \right )} \cos ^{3}{\left (c + d x \right )}}{3 d} - \frac {8 a^{2} \cos ^{5}{\left (c + d x \right )}}{15 d} + \frac {5 a b x \sin ^{6}{\left (c + d x \right )}}{8} + \frac {15 a b x \sin ^{4}{\left (c + d x \right )} \cos ^{2}{\left (c + d x \right )}}{8} + \frac {15 a b x \sin ^{2}{\left (c + d x \right )} \cos ^{4}{\left (c + d x \right )}}{8} + \frac {5 a b x \cos ^{6}{\left (c + d x \right )}}{8} - \frac {11 a b \sin ^{5}{\left (c + d x \right )} \cos {\left (c + d x \right )}}{8 d} - \frac {5 a b \sin ^{3}{\left (c + d x \right )} \cos ^{3}{\left (c + d x \right )}}{3 d} - \frac {5 a b \sin {\left (c + d x \right )} \cos ^{5}{\left (c + d x \right )}}{8 d} - \frac {b^{2} \sin ^{6}{\left (c + d x \right )} \cos {\left (c + d x \right )}}{d} - \frac {2 b^{2} \sin ^{4}{\left (c + d x \right )} \cos ^{3}{\left (c + d x \right )}}{d} - \frac {8 b^{2} \sin ^{2}{\left (c + d x \right )} \cos ^{5}{\left (c + d x \right )}}{5 d} - \frac {16 b^{2} \cos ^{7}{\left (c + d x \right )}}{35 d} & \text {for}\: d \neq 0 \\x \left (a \sin ^{2}{\left (c \right )} + b \sin ^{3}{\left (c \right )}\right )^{2} \sin {\left (c \right )} & \text {otherwise} \end {cases} \] Input:
integrate(sin(d*x+c)*(a*sin(d*x+c)**2+b*sin(d*x+c)**3)**2,x)
Output:
Piecewise((-a**2*sin(c + d*x)**4*cos(c + d*x)/d - 4*a**2*sin(c + d*x)**2*c os(c + d*x)**3/(3*d) - 8*a**2*cos(c + d*x)**5/(15*d) + 5*a*b*x*sin(c + d*x )**6/8 + 15*a*b*x*sin(c + d*x)**4*cos(c + d*x)**2/8 + 15*a*b*x*sin(c + d*x )**2*cos(c + d*x)**4/8 + 5*a*b*x*cos(c + d*x)**6/8 - 11*a*b*sin(c + d*x)** 5*cos(c + d*x)/(8*d) - 5*a*b*sin(c + d*x)**3*cos(c + d*x)**3/(3*d) - 5*a*b *sin(c + d*x)*cos(c + d*x)**5/(8*d) - b**2*sin(c + d*x)**6*cos(c + d*x)/d - 2*b**2*sin(c + d*x)**4*cos(c + d*x)**3/d - 8*b**2*sin(c + d*x)**2*cos(c + d*x)**5/(5*d) - 16*b**2*cos(c + d*x)**7/(35*d), Ne(d, 0)), (x*(a*sin(c)* *2 + b*sin(c)**3)**2*sin(c), True))
Time = 0.04 (sec) , antiderivative size = 131, normalized size of antiderivative = 0.81 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=-\frac {224 \, {\left (3 \, \cos \left (d x + c\right )^{5} - 10 \, \cos \left (d x + c\right )^{3} + 15 \, \cos \left (d x + c\right )\right )} a^{2} - 35 \, {\left (4 \, \sin \left (2 \, d x + 2 \, c\right )^{3} + 60 \, d x + 60 \, c + 9 \, \sin \left (4 \, d x + 4 \, c\right ) - 48 \, \sin \left (2 \, d x + 2 \, c\right )\right )} a b - 96 \, {\left (5 \, \cos \left (d x + c\right )^{7} - 21 \, \cos \left (d x + c\right )^{5} + 35 \, \cos \left (d x + c\right )^{3} - 35 \, \cos \left (d x + c\right )\right )} b^{2}}{3360 \, d} \] Input:
integrate(sin(d*x+c)*(a*sin(d*x+c)^2+b*sin(d*x+c)^3)^2,x, algorithm="maxim a")
Output:
-1/3360*(224*(3*cos(d*x + c)^5 - 10*cos(d*x + c)^3 + 15*cos(d*x + c))*a^2 - 35*(4*sin(2*d*x + 2*c)^3 + 60*d*x + 60*c + 9*sin(4*d*x + 4*c) - 48*sin(2 *d*x + 2*c))*a*b - 96*(5*cos(d*x + c)^7 - 21*cos(d*x + c)^5 + 35*cos(d*x + c)^3 - 35*cos(d*x + c))*b^2)/d
Time = 0.16 (sec) , antiderivative size = 143, normalized size of antiderivative = 0.89 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=\frac {5}{8} \, a b x + \frac {b^{2} \cos \left (7 \, d x + 7 \, c\right )}{448 \, d} - \frac {a b \sin \left (6 \, d x + 6 \, c\right )}{96 \, d} + \frac {3 \, a b \sin \left (4 \, d x + 4 \, c\right )}{32 \, d} - \frac {15 \, a b \sin \left (2 \, d x + 2 \, c\right )}{32 \, d} - \frac {{\left (4 \, a^{2} + 7 \, b^{2}\right )} \cos \left (5 \, d x + 5 \, c\right )}{320 \, d} + \frac {{\left (20 \, a^{2} + 21 \, b^{2}\right )} \cos \left (3 \, d x + 3 \, c\right )}{192 \, d} - \frac {5 \, {\left (8 \, a^{2} + 7 \, b^{2}\right )} \cos \left (d x + c\right )}{64 \, d} \] Input:
integrate(sin(d*x+c)*(a*sin(d*x+c)^2+b*sin(d*x+c)^3)^2,x, algorithm="giac" )
Output:
5/8*a*b*x + 1/448*b^2*cos(7*d*x + 7*c)/d - 1/96*a*b*sin(6*d*x + 6*c)/d + 3 /32*a*b*sin(4*d*x + 4*c)/d - 15/32*a*b*sin(2*d*x + 2*c)/d - 1/320*(4*a^2 + 7*b^2)*cos(5*d*x + 5*c)/d + 1/192*(20*a^2 + 21*b^2)*cos(3*d*x + 3*c)/d - 5/64*(8*a^2 + 7*b^2)*cos(d*x + c)/d
Time = 19.79 (sec) , antiderivative size = 210, normalized size of antiderivative = 1.30 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=\frac {5\,a\,b\,x}{8}-\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6\,\left (\frac {80\,a^2}{3}+32\,b^2\right )+{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\,\left (\frac {112\,a^2}{15}+\frac {32\,b^2}{5}\right )+{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4\,\left (\frac {112\,a^2}{5}+\frac {96\,b^2}{5}\right )+\frac {32\,a^2\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8}{3}+\frac {16\,a^2}{15}+\frac {32\,b^2}{35}+\frac {25\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{3}+\frac {283\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5}{12}-\frac {283\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^9}{12}-\frac {25\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{11}}{3}-\frac {5\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{13}}{4}+\frac {5\,a\,b\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{4}}{d\,{\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )}^7} \] Input:
int(sin(c + d*x)*(a*sin(c + d*x)^2 + b*sin(c + d*x)^3)^2,x)
Output:
(5*a*b*x)/8 - (tan(c/2 + (d*x)/2)^6*((80*a^2)/3 + 32*b^2) + tan(c/2 + (d*x )/2)^2*((112*a^2)/15 + (32*b^2)/5) + tan(c/2 + (d*x)/2)^4*((112*a^2)/5 + ( 96*b^2)/5) + (32*a^2*tan(c/2 + (d*x)/2)^8)/3 + (16*a^2)/15 + (32*b^2)/35 + (25*a*b*tan(c/2 + (d*x)/2)^3)/3 + (283*a*b*tan(c/2 + (d*x)/2)^5)/12 - (28 3*a*b*tan(c/2 + (d*x)/2)^9)/12 - (25*a*b*tan(c/2 + (d*x)/2)^11)/3 - (5*a*b *tan(c/2 + (d*x)/2)^13)/4 + (5*a*b*tan(c/2 + (d*x)/2))/4)/(d*(tan(c/2 + (d *x)/2)^2 + 1)^7)
Time = 0.17 (sec) , antiderivative size = 191, normalized size of antiderivative = 1.19 \[ \int \sin (c+d x) \left (a \sin ^2(c+d x)+b \sin ^3(c+d x)\right )^2 \, dx=\frac {-120 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{6} b^{2}-280 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{5} a b -168 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{4} a^{2}-144 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{4} b^{2}-350 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{3} a b -224 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{2} a^{2}-192 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{2} b^{2}-525 \cos \left (d x +c \right ) \sin \left (d x +c \right ) a b -448 \cos \left (d x +c \right ) a^{2}-384 \cos \left (d x +c \right ) b^{2}+448 a^{2}+525 a b d x +384 b^{2}}{840 d} \] Input:
int(sin(d*x+c)*(a*sin(d*x+c)^2+b*sin(d*x+c)^3)^2,x)
Output:
( - 120*cos(c + d*x)*sin(c + d*x)**6*b**2 - 280*cos(c + d*x)*sin(c + d*x)* *5*a*b - 168*cos(c + d*x)*sin(c + d*x)**4*a**2 - 144*cos(c + d*x)*sin(c + d*x)**4*b**2 - 350*cos(c + d*x)*sin(c + d*x)**3*a*b - 224*cos(c + d*x)*sin (c + d*x)**2*a**2 - 192*cos(c + d*x)*sin(c + d*x)**2*b**2 - 525*cos(c + d* x)*sin(c + d*x)*a*b - 448*cos(c + d*x)*a**2 - 384*cos(c + d*x)*b**2 + 448* a**2 + 525*a*b*d*x + 384*b**2)/(840*d)