Integrand size = 27, antiderivative size = 189 \[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=-3 a b x+\frac {\left (3 a^2-2 b^2\right ) \text {arctanh}(\cos (c+d x))}{2 d}-\frac {\left (4 a^2-23 b^2\right ) \cos (c+d x)}{6 d}-\frac {b \left (a^2-3 b^2\right ) \cos (c+d x) \sin (c+d x)}{3 a d}-\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{6 a^2 d}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d} \] Output:
-3*a*b*x+1/2*(3*a^2-2*b^2)*arctanh(cos(d*x+c))/d-1/6*(4*a^2-23*b^2)*cos(d* x+c)/d-1/3*b*(a^2-3*b^2)*cos(d*x+c)*sin(d*x+c)/a/d-1/6*(2*a^2-3*b^2)*cos(d *x+c)*(a+b*sin(d*x+c))^2/a^2/d-1/2*b*cot(d*x+c)*(a+b*sin(d*x+c))^3/a^2/d-1 /2*cot(d*x+c)*csc(d*x+c)*(a+b*sin(d*x+c))^3/a/d
Time = 3.50 (sec) , antiderivative size = 191, normalized size of antiderivative = 1.01 \[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=\frac {-6 \left (4 a^2-5 b^2\right ) \cos (c+d x)+2 b^2 \cos (3 (c+d x))+3 \left (-24 a b c-24 a b d x-8 a b \cot \left (\frac {1}{2} (c+d x)\right )-a^2 \csc ^2\left (\frac {1}{2} (c+d x)\right )+12 a^2 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )-8 b^2 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )-12 a^2 \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )+8 b^2 \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )+a^2 \sec ^2\left (\frac {1}{2} (c+d x)\right )-4 a b \sin (2 (c+d x))+8 a b \tan \left (\frac {1}{2} (c+d x)\right )\right )}{24 d} \] Input:
Integrate[Cos[c + d*x]*Cot[c + d*x]^3*(a + b*Sin[c + d*x])^2,x]
Output:
(-6*(4*a^2 - 5*b^2)*Cos[c + d*x] + 2*b^2*Cos[3*(c + d*x)] + 3*(-24*a*b*c - 24*a*b*d*x - 8*a*b*Cot[(c + d*x)/2] - a^2*Csc[(c + d*x)/2]^2 + 12*a^2*Log [Cos[(c + d*x)/2]] - 8*b^2*Log[Cos[(c + d*x)/2]] - 12*a^2*Log[Sin[(c + d*x )/2]] + 8*b^2*Log[Sin[(c + d*x)/2]] + a^2*Sec[(c + d*x)/2]^2 - 4*a*b*Sin[2 *(c + d*x)] + 8*a*b*Tan[(c + d*x)/2]))/(24*d)
Time = 1.34 (sec) , antiderivative size = 201, normalized size of antiderivative = 1.06, number of steps used = 14, number of rules used = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.519, Rules used = {3042, 3372, 3042, 3528, 3042, 3512, 27, 3042, 3502, 27, 3042, 3214, 3042, 4257}
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 \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\cos (c+d x)^4 (a+b \sin (c+d x))^2}{\sin (c+d x)^3}dx\) |
\(\Big \downarrow \) 3372 |
\(\displaystyle -\frac {\int \csc (c+d x) (a+b \sin (c+d x))^2 \left (3 a^2+2 b \sin (c+d x) a-2 b^2-\left (2 a^2-3 b^2\right ) \sin ^2(c+d x)\right )dx}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\int \frac {(a+b \sin (c+d x))^2 \left (3 a^2+2 b \sin (c+d x) a-2 b^2-\left (2 a^2-3 b^2\right ) \sin (c+d x)^2\right )}{\sin (c+d x)}dx}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3528 |
\(\displaystyle -\frac {\frac {1}{3} \int \csc (c+d x) (a+b \sin (c+d x)) \left (11 b \sin (c+d x) a^2-4 \left (a^2-3 b^2\right ) \sin ^2(c+d x) a+3 \left (3 a^2-2 b^2\right ) a\right )dx+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {1}{3} \int \frac {(a+b \sin (c+d x)) \left (11 b \sin (c+d x) a^2-4 \left (a^2-3 b^2\right ) \sin (c+d x)^2 a+3 \left (3 a^2-2 b^2\right ) a\right )}{\sin (c+d x)}dx+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3512 |
\(\displaystyle -\frac {\frac {1}{3} \left (\frac {1}{2} \int 2 \csc (c+d x) \left (18 b \sin (c+d x) a^3-\left (4 a^2-23 b^2\right ) \sin ^2(c+d x) a^2+3 \left (3 a^2-2 b^2\right ) a^2\right )dx+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\frac {\frac {1}{3} \left (\int \csc (c+d x) \left (18 b \sin (c+d x) a^3-\left (4 a^2-23 b^2\right ) \sin ^2(c+d x) a^2+3 \left (3 a^2-2 b^2\right ) a^2\right )dx+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {1}{3} \left (\int \frac {18 b \sin (c+d x) a^3-\left (4 a^2-23 b^2\right ) \sin (c+d x)^2 a^2+3 \left (3 a^2-2 b^2\right ) a^2}{\sin (c+d x)}dx+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3502 |
\(\displaystyle -\frac {\frac {1}{3} \left (\int 3 \csc (c+d x) \left (6 b \sin (c+d x) a^3+\left (3 a^2-2 b^2\right ) a^2\right )dx+\frac {a^2 \left (4 a^2-23 b^2\right ) \cos (c+d x)}{d}+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\frac {\frac {1}{3} \left (3 \int \csc (c+d x) \left (6 b \sin (c+d x) a^3+\left (3 a^2-2 b^2\right ) a^2\right )dx+\frac {a^2 \left (4 a^2-23 b^2\right ) \cos (c+d x)}{d}+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {1}{3} \left (3 \int \frac {6 b \sin (c+d x) a^3+\left (3 a^2-2 b^2\right ) a^2}{\sin (c+d x)}dx+\frac {a^2 \left (4 a^2-23 b^2\right ) \cos (c+d x)}{d}+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3214 |
\(\displaystyle -\frac {\frac {1}{3} \left (3 \left (a^2 \left (3 a^2-2 b^2\right ) \int \csc (c+d x)dx+6 a^3 b x\right )+\frac {a^2 \left (4 a^2-23 b^2\right ) \cos (c+d x)}{d}+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {1}{3} \left (3 \left (a^2 \left (3 a^2-2 b^2\right ) \int \csc (c+d x)dx+6 a^3 b x\right )+\frac {a^2 \left (4 a^2-23 b^2\right ) \cos (c+d x)}{d}+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}\right )+\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}}{2 a^2}-\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
\(\Big \downarrow \) 4257 |
\(\displaystyle -\frac {b \cot (c+d x) (a+b \sin (c+d x))^3}{2 a^2 d}-\frac {\frac {\left (2 a^2-3 b^2\right ) \cos (c+d x) (a+b \sin (c+d x))^2}{3 d}+\frac {1}{3} \left (\frac {a^2 \left (4 a^2-23 b^2\right ) \cos (c+d x)}{d}+\frac {2 a b \left (a^2-3 b^2\right ) \sin (c+d x) \cos (c+d x)}{d}+3 \left (6 a^3 b x-\frac {a^2 \left (3 a^2-2 b^2\right ) \text {arctanh}(\cos (c+d x))}{d}\right )\right )}{2 a^2}-\frac {\cot (c+d x) \csc (c+d x) (a+b \sin (c+d x))^3}{2 a d}\) |
Input:
Int[Cos[c + d*x]*Cot[c + d*x]^3*(a + b*Sin[c + d*x])^2,x]
Output:
-1/2*(b*Cot[c + d*x]*(a + b*Sin[c + d*x])^3)/(a^2*d) - (Cot[c + d*x]*Csc[c + d*x]*(a + b*Sin[c + d*x])^3)/(2*a*d) - (((2*a^2 - 3*b^2)*Cos[c + d*x]*( a + b*Sin[c + d*x])^2)/(3*d) + (3*(6*a^3*b*x - (a^2*(3*a^2 - 2*b^2)*ArcTan h[Cos[c + d*x]])/d) + (a^2*(4*a^2 - 23*b^2)*Cos[c + d*x])/d + (2*a*b*(a^2 - 3*b^2)*Cos[c + d*x]*Sin[c + d*x])/d)/3)/(2*a^2)
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])/((c_.) + (d_.)*sin[(e_.) + (f_. )*(x_)]), x_Symbol] :> Simp[b*(x/d), x] - Simp[(b*c - a*d)/d Int[1/(c + d *Sin[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0]
Int[cos[(e_.) + (f_.)*(x_)]^4*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> Simp[Cos[e + f*x]*(a + b* Sin[e + f*x])^(m + 1)*((d*Sin[e + f*x])^(n + 1)/(a*d*f*(n + 1))), x] + (-Si mp[b*(m + n + 2)*Cos[e + f*x]*(a + b*Sin[e + f*x])^(m + 1)*((d*Sin[e + f*x] )^(n + 2)/(a^2*d^2*f*(n + 1)*(n + 2))), x] - Simp[1/(a^2*d^2*(n + 1)*(n + 2 )) Int[(a + b*Sin[e + f*x])^m*(d*Sin[e + f*x])^(n + 2)*Simp[a^2*n*(n + 2) - b^2*(m + n + 2)*(m + n + 3) + a*b*m*Sin[e + f*x] - (a^2*(n + 1)*(n + 2) - b^2*(m + n + 2)*(m + n + 4))*Sin[e + f*x]^2, x], x], x]) /; FreeQ[{a, b, d, e, f, m}, x] && NeQ[a^2 - b^2, 0] && (IGtQ[m, 0] || IntegersQ[2*m, 2*n]) && !m < -1 && LtQ[n, -1] && (LtQ[n, -2] || EqQ[m + n + 4, 0])
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)] + (C_.)*sin[(e_.) + (f_.)*(x_)]^2), x_Symbol] :> Simp[(-C)*Co s[e + f*x]*((a + b*Sin[e + f*x])^(m + 1)/(b*f*(m + 2))), x] + Simp[1/(b*(m + 2)) Int[(a + b*Sin[e + f*x])^m*Simp[A*b*(m + 2) + b*C*(m + 1) + (b*B*(m + 2) - a*C)*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, e, f, A, B, C, m}, x] && !LtQ[m, -1]
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((c_) + (d_.)*sin[(e_.) + (f_.)*(x_)])*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)] + (C_.)*sin[(e_.) + (f _.)*(x_)]^2), x_Symbol] :> Simp[(-C)*d*Cos[e + f*x]*Sin[e + f*x]*((a + b*Si n[e + f*x])^(m + 1)/(b*f*(m + 3))), x] + Simp[1/(b*(m + 3)) Int[(a + b*Si n[e + f*x])^m*Simp[a*C*d + A*b*c*(m + 3) + b*(B*c*(m + 3) + d*(C*(m + 2) + A*(m + 3)))*Sin[e + f*x] - (2*a*C*d - b*(c*C + B*d)*(m + 3))*Sin[e + f*x]^2 , x], x], x] /; FreeQ[{a, b, c, d, e, f, A, B, C, m}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && !LtQ[m, -1]
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)] + (C_.)*sin[(e_ .) + (f_.)*(x_)]^2), x_Symbol] :> Simp[(-C)*Cos[e + f*x]*(a + b*Sin[e + f*x ])^m*((c + d*Sin[e + f*x])^(n + 1)/(d*f*(m + n + 2))), x] + Simp[1/(d*(m + n + 2)) Int[(a + b*Sin[e + f*x])^(m - 1)*(c + d*Sin[e + f*x])^n*Simp[a*A* d*(m + n + 2) + C*(b*c*m + a*d*(n + 1)) + (d*(A*b + a*B)*(m + n + 2) - C*(a *c - b*d*(m + n + 1)))*Sin[e + f*x] + (C*(a*d*m - b*c*(m + 1)) + b*B*d*(m + n + 2))*Sin[e + f*x]^2, x], x], x] /; FreeQ[{a, b, c, d, e, f, A, B, C, n} , x] && NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && GtQ[ m, 0] && !(IGtQ[n, 0] && ( !IntegerQ[m] || (EqQ[a, 0] && NeQ[c, 0])))
Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]
Time = 1.98 (sec) , antiderivative size = 157, normalized size of antiderivative = 0.83
method | result | size |
derivativedivides | \(\frac {a^{2} \left (-\frac {\cos \left (d x +c \right )^{5}}{2 \sin \left (d x +c \right )^{2}}-\frac {\cos \left (d x +c \right )^{3}}{2}-\frac {3 \cos \left (d x +c \right )}{2}-\frac {3 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{2}\right )+2 a b \left (-\frac {\cos \left (d x +c \right )^{5}}{\sin \left (d x +c \right )}-\left (\cos \left (d x +c \right )^{3}+\frac {3 \cos \left (d x +c \right )}{2}\right ) \sin \left (d x +c \right )-\frac {3 d x}{2}-\frac {3 c}{2}\right )+b^{2} \left (\frac {\cos \left (d x +c \right )^{3}}{3}+\cos \left (d x +c \right )+\ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )\right )}{d}\) | \(157\) |
default | \(\frac {a^{2} \left (-\frac {\cos \left (d x +c \right )^{5}}{2 \sin \left (d x +c \right )^{2}}-\frac {\cos \left (d x +c \right )^{3}}{2}-\frac {3 \cos \left (d x +c \right )}{2}-\frac {3 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{2}\right )+2 a b \left (-\frac {\cos \left (d x +c \right )^{5}}{\sin \left (d x +c \right )}-\left (\cos \left (d x +c \right )^{3}+\frac {3 \cos \left (d x +c \right )}{2}\right ) \sin \left (d x +c \right )-\frac {3 d x}{2}-\frac {3 c}{2}\right )+b^{2} \left (\frac {\cos \left (d x +c \right )^{3}}{3}+\cos \left (d x +c \right )+\ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )\right )}{d}\) | \(157\) |
risch | \(-3 a b x +\frac {b^{2} {\mathrm e}^{3 i \left (d x +c \right )}}{24 d}+\frac {i a b \,{\mathrm e}^{2 i \left (d x +c \right )}}{4 d}-\frac {a^{2} {\mathrm e}^{i \left (d x +c \right )}}{2 d}+\frac {5 \,{\mathrm e}^{i \left (d x +c \right )} b^{2}}{8 d}-\frac {a^{2} {\mathrm e}^{-i \left (d x +c \right )}}{2 d}+\frac {5 \,{\mathrm e}^{-i \left (d x +c \right )} b^{2}}{8 d}-\frac {i a b \,{\mathrm e}^{-2 i \left (d x +c \right )}}{4 d}+\frac {b^{2} {\mathrm e}^{-3 i \left (d x +c \right )}}{24 d}-\frac {i a \left (i a \,{\mathrm e}^{3 i \left (d x +c \right )}+i a \,{\mathrm e}^{i \left (d x +c \right )}+4 b \,{\mathrm e}^{2 i \left (d x +c \right )}-4 b \right )}{d \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )^{2}}-\frac {3 a^{2} \ln \left ({\mathrm e}^{i \left (d x +c \right )}-1\right )}{2 d}+\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}-1\right ) b^{2}}{d}+\frac {3 a^{2} \ln \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )}{2 d}-\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}+1\right ) b^{2}}{d}\) | \(284\) |
Input:
int(cos(d*x+c)*cot(d*x+c)^3*(a+b*sin(d*x+c))^2,x,method=_RETURNVERBOSE)
Output:
1/d*(a^2*(-1/2/sin(d*x+c)^2*cos(d*x+c)^5-1/2*cos(d*x+c)^3-3/2*cos(d*x+c)-3 /2*ln(csc(d*x+c)-cot(d*x+c)))+2*a*b*(-1/sin(d*x+c)*cos(d*x+c)^5-(cos(d*x+c )^3+3/2*cos(d*x+c))*sin(d*x+c)-3/2*d*x-3/2*c)+b^2*(1/3*cos(d*x+c)^3+cos(d* x+c)+ln(csc(d*x+c)-cot(d*x+c))))
Time = 0.10 (sec) , antiderivative size = 210, normalized size of antiderivative = 1.11 \[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=\frac {4 \, b^{2} \cos \left (d x + c\right )^{5} - 36 \, a b d x \cos \left (d x + c\right )^{2} + 36 \, a b d x - 4 \, {\left (3 \, a^{2} - 2 \, b^{2}\right )} \cos \left (d x + c\right )^{3} + 6 \, {\left (3 \, a^{2} - 2 \, b^{2}\right )} \cos \left (d x + c\right ) + 3 \, {\left ({\left (3 \, a^{2} - 2 \, b^{2}\right )} \cos \left (d x + c\right )^{2} - 3 \, a^{2} + 2 \, b^{2}\right )} \log \left (\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) - 3 \, {\left ({\left (3 \, a^{2} - 2 \, b^{2}\right )} \cos \left (d x + c\right )^{2} - 3 \, a^{2} + 2 \, b^{2}\right )} \log \left (-\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) - 12 \, {\left (a b \cos \left (d x + c\right )^{3} - 3 \, a b \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{12 \, {\left (d \cos \left (d x + c\right )^{2} - d\right )}} \] Input:
integrate(cos(d*x+c)*cot(d*x+c)^3*(a+b*sin(d*x+c))^2,x, algorithm="fricas" )
Output:
1/12*(4*b^2*cos(d*x + c)^5 - 36*a*b*d*x*cos(d*x + c)^2 + 36*a*b*d*x - 4*(3 *a^2 - 2*b^2)*cos(d*x + c)^3 + 6*(3*a^2 - 2*b^2)*cos(d*x + c) + 3*((3*a^2 - 2*b^2)*cos(d*x + c)^2 - 3*a^2 + 2*b^2)*log(1/2*cos(d*x + c) + 1/2) - 3*( (3*a^2 - 2*b^2)*cos(d*x + c)^2 - 3*a^2 + 2*b^2)*log(-1/2*cos(d*x + c) + 1/ 2) - 12*(a*b*cos(d*x + c)^3 - 3*a*b*cos(d*x + c))*sin(d*x + c))/(d*cos(d*x + c)^2 - d)
\[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=\int \left (a + b \sin {\left (c + d x \right )}\right )^{2} \cos {\left (c + d x \right )} \cot ^{3}{\left (c + d x \right )}\, dx \] Input:
integrate(cos(d*x+c)*cot(d*x+c)**3*(a+b*sin(d*x+c))**2,x)
Output:
Integral((a + b*sin(c + d*x))**2*cos(c + d*x)*cot(c + d*x)**3, x)
Time = 0.12 (sec) , antiderivative size = 150, normalized size of antiderivative = 0.79 \[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=-\frac {12 \, {\left (3 \, d x + 3 \, c + \frac {3 \, \tan \left (d x + c\right )^{2} + 2}{\tan \left (d x + c\right )^{3} + \tan \left (d x + c\right )}\right )} a b - 2 \, {\left (2 \, \cos \left (d x + c\right )^{3} + 6 \, \cos \left (d x + c\right ) - 3 \, \log \left (\cos \left (d x + c\right ) + 1\right ) + 3 \, \log \left (\cos \left (d x + c\right ) - 1\right )\right )} b^{2} - 3 \, a^{2} {\left (\frac {2 \, \cos \left (d x + c\right )}{\cos \left (d x + c\right )^{2} - 1} - 4 \, \cos \left (d x + c\right ) + 3 \, \log \left (\cos \left (d x + c\right ) + 1\right ) - 3 \, \log \left (\cos \left (d x + c\right ) - 1\right )\right )}}{12 \, d} \] Input:
integrate(cos(d*x+c)*cot(d*x+c)^3*(a+b*sin(d*x+c))^2,x, algorithm="maxima" )
Output:
-1/12*(12*(3*d*x + 3*c + (3*tan(d*x + c)^2 + 2)/(tan(d*x + c)^3 + tan(d*x + c)))*a*b - 2*(2*cos(d*x + c)^3 + 6*cos(d*x + c) - 3*log(cos(d*x + c) + 1 ) + 3*log(cos(d*x + c) - 1))*b^2 - 3*a^2*(2*cos(d*x + c)/(cos(d*x + c)^2 - 1) - 4*cos(d*x + c) + 3*log(cos(d*x + c) + 1) - 3*log(cos(d*x + c) - 1))) /d
Time = 0.18 (sec) , antiderivative size = 252, normalized size of antiderivative = 1.33 \[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=\frac {3 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 72 \, {\left (d x + c\right )} a b + 24 \, a b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 12 \, {\left (3 \, a^{2} - 2 \, b^{2}\right )} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right ) + \frac {3 \, {\left (18 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 12 \, b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 8 \, a b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - a^{2}\right )}}{\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2}} + \frac {16 \, {\left (3 \, a b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 3 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} + 6 \, b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 6 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 6 \, b^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 3 \, a b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 3 \, a^{2} + 4 \, b^{2}\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{3}}}{24 \, d} \] Input:
integrate(cos(d*x+c)*cot(d*x+c)^3*(a+b*sin(d*x+c))^2,x, algorithm="giac")
Output:
1/24*(3*a^2*tan(1/2*d*x + 1/2*c)^2 - 72*(d*x + c)*a*b + 24*a*b*tan(1/2*d*x + 1/2*c) - 12*(3*a^2 - 2*b^2)*log(abs(tan(1/2*d*x + 1/2*c))) + 3*(18*a^2* tan(1/2*d*x + 1/2*c)^2 - 12*b^2*tan(1/2*d*x + 1/2*c)^2 - 8*a*b*tan(1/2*d*x + 1/2*c) - a^2)/tan(1/2*d*x + 1/2*c)^2 + 16*(3*a*b*tan(1/2*d*x + 1/2*c)^5 - 3*a^2*tan(1/2*d*x + 1/2*c)^4 + 6*b^2*tan(1/2*d*x + 1/2*c)^4 - 6*a^2*tan (1/2*d*x + 1/2*c)^2 + 6*b^2*tan(1/2*d*x + 1/2*c)^2 - 3*a*b*tan(1/2*d*x + 1 /2*c) - 3*a^2 + 4*b^2)/(tan(1/2*d*x + 1/2*c)^2 + 1)^3)/d
Time = 32.67 (sec) , antiderivative size = 397, normalized size of antiderivative = 2.10 \[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=\frac {a^2\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{8\,d}-\frac {\ln \left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )\,\left (\frac {3\,a^2}{2}-b^2\right )}{d}-\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6\,\left (\frac {17\,a^2}{2}-16\,b^2\right )+{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4\,\left (\frac {35\,a^2}{2}-16\,b^2\right )+{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\,\left (\frac {19\,a^2}{2}-\frac {32\,b^2}{3}\right )+\frac {a^2}{2}+20\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3+12\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5-4\,a\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7+4\,a\,b\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{d\,\left (4\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8+12\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6+12\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4+4\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\right )}+\frac {6\,a\,b\,\mathrm {atan}\left (\frac {36\,a^2\,b^2}{-18\,a^3\,b+36\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,a^2\,b^2+12\,a\,b^3}-\frac {12\,a\,b^3\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{-18\,a^3\,b+36\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,a^2\,b^2+12\,a\,b^3}+\frac {18\,a^3\,b\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{-18\,a^3\,b+36\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,a^2\,b^2+12\,a\,b^3}\right )}{d}+\frac {a\,b\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{d} \] Input:
int(cos(c + d*x)*cot(c + d*x)^3*(a + b*sin(c + d*x))^2,x)
Output:
(a^2*tan(c/2 + (d*x)/2)^2)/(8*d) - (log(tan(c/2 + (d*x)/2))*((3*a^2)/2 - b ^2))/d - (tan(c/2 + (d*x)/2)^6*((17*a^2)/2 - 16*b^2) + tan(c/2 + (d*x)/2)^ 4*((35*a^2)/2 - 16*b^2) + tan(c/2 + (d*x)/2)^2*((19*a^2)/2 - (32*b^2)/3) + a^2/2 + 20*a*b*tan(c/2 + (d*x)/2)^3 + 12*a*b*tan(c/2 + (d*x)/2)^5 - 4*a*b *tan(c/2 + (d*x)/2)^7 + 4*a*b*tan(c/2 + (d*x)/2))/(d*(4*tan(c/2 + (d*x)/2) ^2 + 12*tan(c/2 + (d*x)/2)^4 + 12*tan(c/2 + (d*x)/2)^6 + 4*tan(c/2 + (d*x) /2)^8)) + (6*a*b*atan((36*a^2*b^2)/(12*a*b^3 - 18*a^3*b + 36*a^2*b^2*tan(c /2 + (d*x)/2)) - (12*a*b^3*tan(c/2 + (d*x)/2))/(12*a*b^3 - 18*a^3*b + 36*a ^2*b^2*tan(c/2 + (d*x)/2)) + (18*a^3*b*tan(c/2 + (d*x)/2))/(12*a*b^3 - 18* a^3*b + 36*a^2*b^2*tan(c/2 + (d*x)/2))))/d + (a*b*tan(c/2 + (d*x)/2))/d
Time = 0.18 (sec) , antiderivative size = 202, normalized size of antiderivative = 1.07 \[ \int \cos (c+d x) \cot ^3(c+d x) (a+b \sin (c+d x))^2 \, dx=\frac {-8 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{4} b^{2}-24 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{3} a b -24 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{2} a^{2}+32 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{2} b^{2}-48 \cos \left (d x +c \right ) \sin \left (d x +c \right ) a b -12 \cos \left (d x +c \right ) a^{2}-36 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \sin \left (d x +c \right )^{2} a^{2}+24 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \sin \left (d x +c \right )^{2} b^{2}+33 \sin \left (d x +c \right )^{2} a^{2}-72 \sin \left (d x +c \right )^{2} a b d x -32 \sin \left (d x +c \right )^{2} b^{2}}{24 \sin \left (d x +c \right )^{2} d} \] Input:
int(cos(d*x+c)*cot(d*x+c)^3*(a+b*sin(d*x+c))^2,x)
Output:
( - 8*cos(c + d*x)*sin(c + d*x)**4*b**2 - 24*cos(c + d*x)*sin(c + d*x)**3* a*b - 24*cos(c + d*x)*sin(c + d*x)**2*a**2 + 32*cos(c + d*x)*sin(c + d*x)* *2*b**2 - 48*cos(c + d*x)*sin(c + d*x)*a*b - 12*cos(c + d*x)*a**2 - 36*log (tan((c + d*x)/2))*sin(c + d*x)**2*a**2 + 24*log(tan((c + d*x)/2))*sin(c + d*x)**2*b**2 + 33*sin(c + d*x)**2*a**2 - 72*sin(c + d*x)**2*a*b*d*x - 32* sin(c + d*x)**2*b**2)/(24*sin(c + d*x)**2*d)