Integrand size = 29, antiderivative size = 62 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx=\frac {x}{2 a}+\frac {\cos (c+d x)}{a d}-\frac {\cos ^3(c+d x)}{3 a d}-\frac {\cos (c+d x) \sin (c+d x)}{2 a d} \] Output:
1/2*x/a+cos(d*x+c)/a/d-1/3*cos(d*x+c)^3/a/d-1/2*cos(d*x+c)*sin(d*x+c)/a/d
Time = 0.19 (sec) , antiderivative size = 46, normalized size of antiderivative = 0.74 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx=\frac {6 c+6 d x+9 \cos (c+d x)-\cos (3 (c+d x))-3 \sin (2 (c+d x))}{12 a d} \] Input:
Integrate[(Cos[c + d*x]^2*Sin[c + d*x]^2)/(a + a*Sin[c + d*x]),x]
Output:
(6*c + 6*d*x + 9*Cos[c + d*x] - Cos[3*(c + d*x)] - 3*Sin[2*(c + d*x)])/(12 *a*d)
Time = 0.39 (sec) , antiderivative size = 56, normalized size of antiderivative = 0.90, number of steps used = 8, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.241, Rules used = {3042, 3318, 3042, 3113, 2009, 3115, 24}
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 \frac {\sin ^2(c+d x) \cos ^2(c+d x)}{a \sin (c+d x)+a} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\sin (c+d x)^2 \cos (c+d x)^2}{a \sin (c+d x)+a}dx\) |
\(\Big \downarrow \) 3318 |
\(\displaystyle \frac {\int \sin ^2(c+d x)dx}{a}-\frac {\int \sin ^3(c+d x)dx}{a}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \sin (c+d x)^2dx}{a}-\frac {\int \sin (c+d x)^3dx}{a}\) |
\(\Big \downarrow \) 3113 |
\(\displaystyle \frac {\int \sin (c+d x)^2dx}{a}+\frac {\int \left (1-\cos ^2(c+d x)\right )d\cos (c+d x)}{a d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {\int \sin (c+d x)^2dx}{a}+\frac {\cos (c+d x)-\frac {1}{3} \cos ^3(c+d x)}{a d}\) |
\(\Big \downarrow \) 3115 |
\(\displaystyle \frac {\frac {\int 1dx}{2}-\frac {\sin (c+d x) \cos (c+d x)}{2 d}}{a}+\frac {\cos (c+d x)-\frac {1}{3} \cos ^3(c+d x)}{a d}\) |
\(\Big \downarrow \) 24 |
\(\displaystyle \frac {\cos (c+d x)-\frac {1}{3} \cos ^3(c+d x)}{a d}+\frac {\frac {x}{2}-\frac {\sin (c+d x) \cos (c+d x)}{2 d}}{a}\) |
Input:
Int[(Cos[c + d*x]^2*Sin[c + d*x]^2)/(a + a*Sin[c + d*x]),x]
Output:
(Cos[c + d*x] - Cos[c + d*x]^3/3)/(a*d) + (x/2 - (Cos[c + d*x]*Sin[c + d*x ])/(2*d))/a
Int[sin[(c_.) + (d_.)*(x_)]^(n_), x_Symbol] :> Simp[-d^(-1) Subst[Int[Exp and[(1 - x^2)^((n - 1)/2), x], x], x, Cos[c + d*x]], x] /; FreeQ[{c, d}, x] && IGtQ[(n - 1)/2, 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[((cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^( n_.))/((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[g^2/a Int [(g*Cos[e + f*x])^(p - 2)*(d*Sin[e + f*x])^n, x], x] - Simp[g^2/(b*d) Int [(g*Cos[e + f*x])^(p - 2)*(d*Sin[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, g, n, p}, x] && EqQ[a^2 - b^2, 0]
Time = 0.35 (sec) , antiderivative size = 45, normalized size of antiderivative = 0.73
method | result | size |
parallelrisch | \(\frac {6 d x -\cos \left (3 d x +3 c \right )-3 \sin \left (2 d x +2 c \right )+9 \cos \left (d x +c \right )+8}{12 d a}\) | \(45\) |
risch | \(\frac {x}{2 a}+\frac {3 \cos \left (d x +c \right )}{4 a d}-\frac {\cos \left (3 d x +3 c \right )}{12 a d}-\frac {\sin \left (2 d x +2 c \right )}{4 d a}\) | \(56\) |
derivativedivides | \(\frac {\frac {8 \left (\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{5}}{8}+\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}{2}-\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{8}+\frac {1}{6}\right )}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{3}}+\arctan \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d a}\) | \(77\) |
default | \(\frac {\frac {8 \left (\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{5}}{8}+\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}{2}-\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{8}+\frac {1}{6}\right )}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{3}}+\arctan \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d a}\) | \(77\) |
norman | \(\frac {\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{8}}{d a}+\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{6}}{d a}+\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{7}}{d a}+\frac {5 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{5}}{d a}+\frac {x}{2 a}+\frac {x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{2 a}+\frac {2 x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}{a}+\frac {2 x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3}}{a}+\frac {3 x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}}{a}+\frac {3 x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{5}}{a}+\frac {2 x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{6}}{a}+\frac {2 x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{7}}{a}+\frac {x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{8}}{2 a}+\frac {x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{9}}{2 a}+\frac {4}{3 a d}+\frac {3 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}}{d a}+\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{3 d a}+\frac {13 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}{3 d a}+\frac {13 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3}}{3 d a}}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{4} \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}\) | \(343\) |
Input:
int(cos(d*x+c)^2*sin(d*x+c)^2/(a+a*sin(d*x+c)),x,method=_RETURNVERBOSE)
Output:
1/12*(6*d*x-cos(3*d*x+3*c)-3*sin(2*d*x+2*c)+9*cos(d*x+c)+8)/d/a
Time = 0.08 (sec) , antiderivative size = 45, normalized size of antiderivative = 0.73 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx=-\frac {2 \, \cos \left (d x + c\right )^{3} - 3 \, d x + 3 \, \cos \left (d x + c\right ) \sin \left (d x + c\right ) - 6 \, \cos \left (d x + c\right )}{6 \, a d} \] Input:
integrate(cos(d*x+c)^2*sin(d*x+c)^2/(a+a*sin(d*x+c)),x, algorithm="fricas" )
Output:
-1/6*(2*cos(d*x + c)^3 - 3*d*x + 3*cos(d*x + c)*sin(d*x + c) - 6*cos(d*x + c))/(a*d)
Leaf count of result is larger than twice the leaf count of optimal. 563 vs. \(2 (46) = 92\).
Time = 3.92 (sec) , antiderivative size = 563, normalized size of antiderivative = 9.08 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx =\text {Too large to display} \] Input:
integrate(cos(d*x+c)**2*sin(d*x+c)**2/(a+a*sin(d*x+c)),x)
Output:
Piecewise((3*d*x*tan(c/2 + d*x/2)**6/(6*a*d*tan(c/2 + d*x/2)**6 + 18*a*d*t an(c/2 + d*x/2)**4 + 18*a*d*tan(c/2 + d*x/2)**2 + 6*a*d) + 9*d*x*tan(c/2 + d*x/2)**4/(6*a*d*tan(c/2 + d*x/2)**6 + 18*a*d*tan(c/2 + d*x/2)**4 + 18*a* d*tan(c/2 + d*x/2)**2 + 6*a*d) + 9*d*x*tan(c/2 + d*x/2)**2/(6*a*d*tan(c/2 + d*x/2)**6 + 18*a*d*tan(c/2 + d*x/2)**4 + 18*a*d*tan(c/2 + d*x/2)**2 + 6* a*d) + 3*d*x/(6*a*d*tan(c/2 + d*x/2)**6 + 18*a*d*tan(c/2 + d*x/2)**4 + 18* a*d*tan(c/2 + d*x/2)**2 + 6*a*d) + 6*tan(c/2 + d*x/2)**5/(6*a*d*tan(c/2 + d*x/2)**6 + 18*a*d*tan(c/2 + d*x/2)**4 + 18*a*d*tan(c/2 + d*x/2)**2 + 6*a* d) + 24*tan(c/2 + d*x/2)**2/(6*a*d*tan(c/2 + d*x/2)**6 + 18*a*d*tan(c/2 + d*x/2)**4 + 18*a*d*tan(c/2 + d*x/2)**2 + 6*a*d) - 6*tan(c/2 + d*x/2)/(6*a* d*tan(c/2 + d*x/2)**6 + 18*a*d*tan(c/2 + d*x/2)**4 + 18*a*d*tan(c/2 + d*x/ 2)**2 + 6*a*d) + 8/(6*a*d*tan(c/2 + d*x/2)**6 + 18*a*d*tan(c/2 + d*x/2)**4 + 18*a*d*tan(c/2 + d*x/2)**2 + 6*a*d), Ne(d, 0)), (x*sin(c)**2*cos(c)**2/ (a*sin(c) + a), True))
Leaf count of result is larger than twice the leaf count of optimal. 156 vs. \(2 (56) = 112\).
Time = 0.11 (sec) , antiderivative size = 156, normalized size of antiderivative = 2.52 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx=-\frac {\frac {\frac {3 \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - \frac {12 \, \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} - \frac {3 \, \sin \left (d x + c\right )^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}} - 4}{a + \frac {3 \, a \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {3 \, a \sin \left (d x + c\right )^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}} + \frac {a \sin \left (d x + c\right )^{6}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{6}}} - \frac {3 \, \arctan \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a}}{3 \, d} \] Input:
integrate(cos(d*x+c)^2*sin(d*x+c)^2/(a+a*sin(d*x+c)),x, algorithm="maxima" )
Output:
-1/3*((3*sin(d*x + c)/(cos(d*x + c) + 1) - 12*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 - 3*sin(d*x + c)^5/(cos(d*x + c) + 1)^5 - 4)/(a + 3*a*sin(d*x + c) ^2/(cos(d*x + c) + 1)^2 + 3*a*sin(d*x + c)^4/(cos(d*x + c) + 1)^4 + a*sin( d*x + c)^6/(cos(d*x + c) + 1)^6) - 3*arctan(sin(d*x + c)/(cos(d*x + c) + 1 ))/a)/d
Time = 0.16 (sec) , antiderivative size = 75, normalized size of antiderivative = 1.21 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx=\frac {\frac {3 \, {\left (d x + c\right )}}{a} + \frac {2 \, {\left (3 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 12 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 3 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 4\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{3} a}}{6 \, d} \] Input:
integrate(cos(d*x+c)^2*sin(d*x+c)^2/(a+a*sin(d*x+c)),x, algorithm="giac")
Output:
1/6*(3*(d*x + c)/a + 2*(3*tan(1/2*d*x + 1/2*c)^5 + 12*tan(1/2*d*x + 1/2*c) ^2 - 3*tan(1/2*d*x + 1/2*c) + 4)/((tan(1/2*d*x + 1/2*c)^2 + 1)^3*a))/d
Time = 18.79 (sec) , antiderivative size = 66, normalized size of antiderivative = 1.06 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx=\frac {x}{2\,a}+\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5+4\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2-\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+\frac {4}{3}}{a\,d\,{\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )}^3} \] Input:
int((cos(c + d*x)^2*sin(c + d*x)^2)/(a + a*sin(c + d*x)),x)
Output:
x/(2*a) + (4*tan(c/2 + (d*x)/2)^2 - tan(c/2 + (d*x)/2) + tan(c/2 + (d*x)/2 )^5 + 4/3)/(a*d*(tan(c/2 + (d*x)/2)^2 + 1)^3)
Time = 0.17 (sec) , antiderivative size = 52, normalized size of antiderivative = 0.84 \[ \int \frac {\cos ^2(c+d x) \sin ^2(c+d x)}{a+a \sin (c+d x)} \, dx=\frac {2 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{2}-3 \cos \left (d x +c \right ) \sin \left (d x +c \right )+4 \cos \left (d x +c \right )+3 d x -4}{6 a d} \] Input:
int(cos(d*x+c)^2*sin(d*x+c)^2/(a+a*sin(d*x+c)),x)
Output:
(2*cos(c + d*x)*sin(c + d*x)**2 - 3*cos(c + d*x)*sin(c + d*x) + 4*cos(c + d*x) + 3*d*x - 4)/(6*a*d)