Integrand size = 17, antiderivative size = 68 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=\frac {1}{8} x (2-\cos (2 (a-c)))-\frac {\sin (2 a+2 b x)}{8 b}+\frac {\sin (2 c+2 b x)}{8 b}-\frac {\sin (2 (a+c)+4 b x)}{32 b} \] Output:
1/8*x*(2-cos(2*a-2*c))-1/8*sin(2*b*x+2*a)/b+1/8*sin(2*b*x+2*c)/b-1/32*sin( 4*b*x+2*a+2*c)/b
Time = 0.09 (sec) , antiderivative size = 54, normalized size of antiderivative = 0.79 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=-\frac {-8 b x+4 b x \cos (2 (a-c))+4 \sin (2 (a+b x))-4 \sin (2 (c+b x))+\sin (2 (a+c+2 b x))}{32 b} \] Input:
Integrate[Cos[c + b*x]^2*Sin[a + b*x]^2,x]
Output:
-1/32*(-8*b*x + 4*b*x*Cos[2*(a - c)] + 4*Sin[2*(a + b*x)] - 4*Sin[2*(c + b *x)] + Sin[2*(a + c + 2*b*x)])/b
Time = 0.25 (sec) , antiderivative size = 68, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.118, Rules used = {5085, 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 ^2(a+b x) \cos ^2(b x+c) \, dx\) |
\(\Big \downarrow \) 5085 |
\(\displaystyle \int \left (-\frac {1}{8} \cos (2 (a+c)+4 b x)-\frac {1}{4} \cos (2 a+2 b x)-\frac {1}{8} \cos (2 a-2 c)+\frac {1}{4} \cos (2 b x+2 c)+\frac {1}{4}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {\sin (2 (a+c)+4 b x)}{32 b}-\frac {\sin (2 a+2 b x)}{8 b}+\frac {1}{8} x (2-\cos (2 (a-c)))+\frac {\sin (2 b x+2 c)}{8 b}\) |
Input:
Int[Cos[c + b*x]^2*Sin[a + b*x]^2,x]
Output:
(x*(2 - Cos[2*(a - c)]))/8 - Sin[2*a + 2*b*x]/(8*b) + Sin[2*c + 2*b*x]/(8* b) - Sin[2*(a + c) + 4*b*x]/(32*b)
Int[Cos[w_]^(q_.)*Sin[v_]^(p_.), x_Symbol] :> Int[ExpandTrigReduce[Sin[v]^p *Cos[w]^q, x], x] /; IGtQ[p, 0] && IGtQ[q, 0] && ((PolynomialQ[v, x] && Pol ynomialQ[w, x]) || (BinomialQ[{v, w}, x] && IndependentQ[Cancel[v/w], x]))
Time = 1.36 (sec) , antiderivative size = 61, normalized size of antiderivative = 0.90
method | result | size |
default | \(\frac {x}{4}-\frac {x \cos \left (2 a -2 c \right )}{8}-\frac {\sin \left (2 b x +2 a \right )}{8 b}+\frac {\sin \left (2 b x +2 c \right )}{8 b}-\frac {\sin \left (4 b x +2 a +2 c \right )}{32 b}\) | \(61\) |
risch | \(\frac {x}{4}-\frac {x \cos \left (2 a -2 c \right )}{8}-\frac {\sin \left (2 b x +2 a \right )}{8 b}+\frac {\sin \left (2 b x +2 c \right )}{8 b}-\frac {\sin \left (4 b x +2 a +2 c \right )}{32 b}\) | \(61\) |
parallelrisch | \(\frac {8 b x -4 b x \cos \left (2 a -2 c \right )-\sin \left (4 b x +2 a +2 c \right )+5 \sin \left (2 a -2 c \right )-4 \sin \left (2 b x +2 a \right )+4 \sin \left (2 b x +2 c \right )}{32 b}\) | \(69\) |
orering | \(x \cos \left (b x +c \right )^{2} \sin \left (b x +a \right )^{2}-\frac {5 \left (-2 b \sin \left (b x +a \right )^{2} \cos \left (b x +c \right ) \sin \left (b x +c \right )+2 \cos \left (b x +a \right ) \cos \left (b x +c \right )^{2} b \sin \left (b x +a \right )\right )}{16 b^{2}}+\frac {5 x \left (-8 \sin \left (b x +c \right ) \cos \left (b x +a \right ) b^{2} \cos \left (b x +c \right ) \sin \left (b x +a \right )+2 \sin \left (b x +c \right )^{2} b^{2} \sin \left (b x +a \right )^{2}-4 b^{2} \sin \left (b x +a \right )^{2} \cos \left (b x +c \right )^{2}+2 \cos \left (b x +a \right )^{2} \cos \left (b x +c \right )^{2} b^{2}\right )}{16 b^{2}}-\frac {-20 b^{3} \cos \left (b x +c \right )^{2} \cos \left (b x +a \right ) \sin \left (b x +a \right )+20 \sin \left (b x +c \right ) b^{3} \sin \left (b x +a \right )^{2} \cos \left (b x +c \right )+12 \sin \left (b x +c \right )^{2} \cos \left (b x +a \right ) b^{3} \sin \left (b x +a \right )-12 b^{3} \cos \left (b x +c \right ) \cos \left (b x +a \right )^{2} \sin \left (b x +c \right )}{64 b^{4}}+\frac {x \left (128 b^{4} \cos \left (b x +c \right ) \cos \left (b x +a \right ) \sin \left (b x +a \right ) \sin \left (b x +c \right )+40 b^{4} \cos \left (b x +c \right )^{2} \sin \left (b x +a \right )^{2}-32 b^{4} \cos \left (b x +c \right )^{2} \cos \left (b x +a \right )^{2}-32 \sin \left (b x +c \right )^{2} b^{4} \sin \left (b x +a \right )^{2}+24 \sin \left (b x +c \right )^{2} \cos \left (b x +a \right )^{2} b^{4}\right )}{64 b^{4}}\) | \(397\) |
Input:
int(cos(b*x+c)^2*sin(b*x+a)^2,x,method=_RETURNVERBOSE)
Output:
1/4*x-1/8*x*cos(2*a-2*c)-1/8*sin(2*b*x+2*a)/b+1/8*sin(2*b*x+2*c)/b-1/32*si n(4*b*x+2*a+2*c)/b
Time = 0.08 (sec) , antiderivative size = 94, normalized size of antiderivative = 1.38 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=\frac {4 \, \cos \left (b x + c\right )^{4} \cos \left (-a + c\right ) \sin \left (-a + c\right ) - 2 \, b x \cos \left (-a + c\right )^{2} + 3 \, b x - {\left (2 \, {\left (2 \, \cos \left (-a + c\right )^{2} - 1\right )} \cos \left (b x + c\right )^{3} + {\left (2 \, \cos \left (-a + c\right )^{2} - 3\right )} \cos \left (b x + c\right )\right )} \sin \left (b x + c\right )}{8 \, b} \] Input:
integrate(cos(b*x+c)^2*sin(b*x+a)^2,x, algorithm="fricas")
Output:
1/8*(4*cos(b*x + c)^4*cos(-a + c)*sin(-a + c) - 2*b*x*cos(-a + c)^2 + 3*b* x - (2*(2*cos(-a + c)^2 - 1)*cos(b*x + c)^3 + (2*cos(-a + c)^2 - 3)*cos(b* x + c))*sin(b*x + c))/b
Leaf count of result is larger than twice the leaf count of optimal. 204 vs. \(2 (56) = 112\).
Time = 0.87 (sec) , antiderivative size = 204, normalized size of antiderivative = 3.00 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=\begin {cases} \frac {x \sin ^{2}{\left (a + b x \right )} \sin ^{2}{\left (b x + c \right )}}{8} + \frac {3 x \sin ^{2}{\left (a + b x \right )} \cos ^{2}{\left (b x + c \right )}}{8} - \frac {x \sin {\left (a + b x \right )} \sin {\left (b x + c \right )} \cos {\left (a + b x \right )} \cos {\left (b x + c \right )}}{2} + \frac {3 x \sin ^{2}{\left (b x + c \right )} \cos ^{2}{\left (a + b x \right )}}{8} + \frac {x \cos ^{2}{\left (a + b x \right )} \cos ^{2}{\left (b x + c \right )}}{8} + \frac {5 \sin ^{2}{\left (a + b x \right )} \sin {\left (b x + c \right )} \cos {\left (b x + c \right )}}{8 b} - \frac {\sin {\left (a + b x \right )} \sin ^{2}{\left (b x + c \right )} \cos {\left (a + b x \right )}}{2 b} - \frac {\sin {\left (b x + c \right )} \cos ^{2}{\left (a + b x \right )} \cos {\left (b x + c \right )}}{8 b} & \text {for}\: b \neq 0 \\x \sin ^{2}{\left (a \right )} \cos ^{2}{\left (c \right )} & \text {otherwise} \end {cases} \] Input:
integrate(cos(b*x+c)**2*sin(b*x+a)**2,x)
Output:
Piecewise((x*sin(a + b*x)**2*sin(b*x + c)**2/8 + 3*x*sin(a + b*x)**2*cos(b *x + c)**2/8 - x*sin(a + b*x)*sin(b*x + c)*cos(a + b*x)*cos(b*x + c)/2 + 3 *x*sin(b*x + c)**2*cos(a + b*x)**2/8 + x*cos(a + b*x)**2*cos(b*x + c)**2/8 + 5*sin(a + b*x)**2*sin(b*x + c)*cos(b*x + c)/(8*b) - sin(a + b*x)*sin(b* x + c)**2*cos(a + b*x)/(2*b) - sin(b*x + c)*cos(a + b*x)**2*cos(b*x + c)/( 8*b), Ne(b, 0)), (x*sin(a)**2*cos(c)**2, True))
Time = 0.04 (sec) , antiderivative size = 57, normalized size of antiderivative = 0.84 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=-\frac {4 \, {\left (b \cos \left (-2 \, a + 2 \, c\right ) - 2 \, b\right )} x + \sin \left (4 \, b x + 2 \, a + 2 \, c\right ) + 4 \, \sin \left (2 \, b x + 2 \, a\right ) - 4 \, \sin \left (2 \, b x + 2 \, c\right )}{32 \, b} \] Input:
integrate(cos(b*x+c)^2*sin(b*x+a)^2,x, algorithm="maxima")
Output:
-1/32*(4*(b*cos(-2*a + 2*c) - 2*b)*x + sin(4*b*x + 2*a + 2*c) + 4*sin(2*b* x + 2*a) - 4*sin(2*b*x + 2*c))/b
Time = 0.12 (sec) , antiderivative size = 60, normalized size of antiderivative = 0.88 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=-\frac {1}{8} \, x \cos \left (2 \, a - 2 \, c\right ) + \frac {1}{4} \, x - \frac {\sin \left (4 \, b x + 2 \, a + 2 \, c\right )}{32 \, b} - \frac {\sin \left (2 \, b x + 2 \, a\right )}{8 \, b} + \frac {\sin \left (2 \, b x + 2 \, c\right )}{8 \, b} \] Input:
integrate(cos(b*x+c)^2*sin(b*x+a)^2,x, algorithm="giac")
Output:
-1/8*x*cos(2*a - 2*c) + 1/4*x - 1/32*sin(4*b*x + 2*a + 2*c)/b - 1/8*sin(2* b*x + 2*a)/b + 1/8*sin(2*b*x + 2*c)/b
Time = 19.47 (sec) , antiderivative size = 55, normalized size of antiderivative = 0.81 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=-\frac {\frac {\sin \left (2\,a+2\,c+4\,b\,x\right )}{4}+\sin \left (2\,a+2\,b\,x\right )-\sin \left (2\,c+2\,b\,x\right )-2\,b\,x+b\,x\,\cos \left (2\,a-2\,c\right )}{8\,b} \] Input:
int(cos(c + b*x)^2*sin(a + b*x)^2,x)
Output:
-(sin(2*a + 2*c + 4*b*x)/4 + sin(2*a + 2*b*x) - sin(2*c + 2*b*x) - 2*b*x + b*x*cos(2*a - 2*c))/(8*b)
Time = 0.17 (sec) , antiderivative size = 182, normalized size of antiderivative = 2.68 \[ \int \cos ^2(c+b x) \sin ^2(a+b x) \, dx=\frac {-12 \cos \left (b x +c \right ) \cos \left (b x +a \right ) \sin \left (b x +c \right ) \sin \left (b x +a \right ) b x +2 \cos \left (b x +c \right ) \sin \left (b x +c \right ) \sin \left (b x +a \right )^{2}+5 \cos \left (b x +c \right ) \sin \left (b x +c \right )+8 \cos \left (b x +c \right ) \sin \left (b x +a \right )+4 \cos \left (b x +a \right ) \sin \left (b x +c \right )^{2} \sin \left (b x +a \right )-8 \cos \left (b x +a \right ) \sin \left (b x +c \right )-8 \cos \left (b x +a \right ) \sin \left (b x +a \right )-12 \sin \left (b x +c \right )^{2} \sin \left (b x +a \right )^{2} b x +6 \sin \left (b x +c \right )^{2} b x +6 \sin \left (b x +a \right )^{2} b x +3 b x}{24 b} \] Input:
int(cos(b*x+c)^2*sin(b*x+a)^2,x)
Output:
( - 12*cos(b*x + c)*cos(a + b*x)*sin(b*x + c)*sin(a + b*x)*b*x + 2*cos(b*x + c)*sin(b*x + c)*sin(a + b*x)**2 + 5*cos(b*x + c)*sin(b*x + c) + 8*cos(b *x + c)*sin(a + b*x) + 4*cos(a + b*x)*sin(b*x + c)**2*sin(a + b*x) - 8*cos (a + b*x)*sin(b*x + c) - 8*cos(a + b*x)*sin(a + b*x) - 12*sin(b*x + c)**2* sin(a + b*x)**2*b*x + 6*sin(b*x + c)**2*b*x + 6*sin(a + b*x)**2*b*x + 3*b* x)/(24*b)