Integrand size = 27, antiderivative size = 59 \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=-\frac {x}{2 a}-\frac {\text {arctanh}(\cos (c+d x))}{a d}+\frac {\cos (c+d x)}{a d}-\frac {\cos (c+d x) \sin (c+d x)}{2 a d} \] Output:
-1/2*x/a-arctanh(cos(d*x+c))/a/d+cos(d*x+c)/a/d-1/2*cos(d*x+c)*sin(d*x+c)/ a/d
Time = 0.71 (sec) , antiderivative size = 60, normalized size of antiderivative = 1.02 \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=-\frac {-4 \cos (c+d x)+2 \left (c+d x+2 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )-2 \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )\right )+\sin (2 (c+d x))}{4 a d} \] Input:
Integrate[(Cos[c + d*x]^3*Cot[c + d*x])/(a + a*Sin[c + d*x]),x]
Output:
-1/4*(-4*Cos[c + d*x] + 2*(c + d*x + 2*Log[Cos[(c + d*x)/2]] - 2*Log[Sin[( c + d*x)/2]]) + Sin[2*(c + d*x)])/(a*d)
Time = 0.38 (sec) , antiderivative size = 55, normalized size of antiderivative = 0.93, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {3042, 3318, 3042, 25, 3072, 262, 219, 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 {\cos ^3(c+d x) \cot (c+d x)}{a \sin (c+d x)+a} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\cos (c+d x)^4}{\sin (c+d x) (a \sin (c+d x)+a)}dx\) |
\(\Big \downarrow \) 3318 |
\(\displaystyle \frac {\int \cos (c+d x) \cot (c+d x)dx}{a}-\frac {\int \cos ^2(c+d x)dx}{a}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int -\sin \left (c+d x+\frac {\pi }{2}\right ) \tan \left (c+d x+\frac {\pi }{2}\right )dx}{a}-\frac {\int \sin \left (c+d x+\frac {\pi }{2}\right )^2dx}{a}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle -\frac {\int \sin \left (c+d x+\frac {\pi }{2}\right )^2dx}{a}-\frac {\int \sin \left (\frac {1}{2} (2 c+\pi )+d x\right ) \tan \left (\frac {1}{2} (2 c+\pi )+d x\right )dx}{a}\) |
\(\Big \downarrow \) 3072 |
\(\displaystyle -\frac {\int \sin \left (c+d x+\frac {\pi }{2}\right )^2dx}{a}-\frac {\int \frac {\cos ^2(c+d x)}{1-\cos ^2(c+d x)}d\cos (c+d x)}{a d}\) |
\(\Big \downarrow \) 262 |
\(\displaystyle -\frac {\int \sin \left (c+d x+\frac {\pi }{2}\right )^2dx}{a}-\frac {\int \frac {1}{1-\cos ^2(c+d x)}d\cos (c+d x)-\cos (c+d x)}{a d}\) |
\(\Big \downarrow \) 219 |
\(\displaystyle -\frac {\int \sin \left (c+d x+\frac {\pi }{2}\right )^2dx}{a}-\frac {\text {arctanh}(\cos (c+d x))-\cos (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 {\text {arctanh}(\cos (c+d x))-\cos (c+d x)}{a d}\) |
\(\Big \downarrow \) 24 |
\(\displaystyle -\frac {\text {arctanh}(\cos (c+d x))-\cos (c+d x)}{a d}-\frac {\frac {\sin (c+d x) \cos (c+d x)}{2 d}+\frac {x}{2}}{a}\) |
Input:
Int[(Cos[c + d*x]^3*Cot[c + d*x])/(a + a*Sin[c + d*x]),x]
Output:
-((ArcTanh[Cos[c + d*x]] - Cos[c + d*x])/(a*d)) - (x/2 + (Cos[c + d*x]*Sin [c + d*x])/(2*d))/a
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))* ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt Q[a, 0] || LtQ[b, 0])
Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> Simp[c*(c*x) ^(m - 1)*((a + b*x^2)^(p + 1)/(b*(m + 2*p + 1))), x] - Simp[a*c^2*((m - 1)/ (b*(m + 2*p + 1))) Int[(c*x)^(m - 2)*(a + b*x^2)^p, x], x] /; FreeQ[{a, b , c, p}, x] && GtQ[m, 2 - 1] && NeQ[m + 2*p + 1, 0] && IntBinomialQ[a, b, c , 2, m, p, x]
Int[((a_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*tan[(e_.) + (f_.)*(x_)]^(n_.), x_ Symbol] :> With[{ff = FreeFactors[Sin[e + f*x], x]}, Simp[ff/f Subst[Int[ (ff*x)^(m + n)/(a^2 - ff^2*x^2)^((n + 1)/2), x], x, a*(Sin[e + f*x]/ff)], x ]] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n + 1)/2]
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.51 (sec) , antiderivative size = 87, normalized size of antiderivative = 1.47
method | result | size |
derivativedivides | \(\frac {\ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )-\frac {2 \left (-\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3}}{2}-\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{2}-1\right )}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{2}}-\arctan \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d a}\) | \(87\) |
default | \(\frac {\ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )-\frac {2 \left (-\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3}}{2}-\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+\frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{2}-1\right )}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{2}}-\arctan \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d a}\) | \(87\) |
risch | \(-\frac {x}{2 a}+\frac {{\mathrm e}^{i \left (d x +c \right )}}{2 a d}+\frac {{\mathrm e}^{-i \left (d x +c \right )}}{2 a d}-\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )}{d a}+\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}-1\right )}{d a}-\frac {\sin \left (2 d x +2 c \right )}{4 d a}\) | \(98\) |
Input:
int(cos(d*x+c)^3*cot(d*x+c)/(a+a*sin(d*x+c)),x,method=_RETURNVERBOSE)
Output:
1/d/a*(ln(tan(1/2*d*x+1/2*c))-2*(-1/2*tan(1/2*d*x+1/2*c)^3-tan(1/2*d*x+1/2 *c)^2+1/2*tan(1/2*d*x+1/2*c)-1)/(1+tan(1/2*d*x+1/2*c)^2)^2-arctan(tan(1/2* d*x+1/2*c)))
Time = 0.09 (sec) , antiderivative size = 57, normalized size of antiderivative = 0.97 \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=-\frac {d x + \cos \left (d x + c\right ) \sin \left (d x + c\right ) - 2 \, \cos \left (d x + c\right ) + \log \left (\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) - \log \left (-\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right )}{2 \, a d} \] Input:
integrate(cos(d*x+c)^3*cot(d*x+c)/(a+a*sin(d*x+c)),x, algorithm="fricas")
Output:
-1/2*(d*x + cos(d*x + c)*sin(d*x + c) - 2*cos(d*x + c) + log(1/2*cos(d*x + c) + 1/2) - log(-1/2*cos(d*x + c) + 1/2))/(a*d)
Timed out. \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=\text {Timed out} \] Input:
integrate(cos(d*x+c)**3*cot(d*x+c)/(a+a*sin(d*x+c)),x)
Output:
Timed out
Leaf count of result is larger than twice the leaf count of optimal. 156 vs. \(2 (55) = 110\).
Time = 0.11 (sec) , antiderivative size = 156, normalized size of antiderivative = 2.64 \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=-\frac {\frac {\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - \frac {2 \, \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} - \frac {\sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} - 2}{a + \frac {2 \, a \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {a \sin \left (d x + c\right )^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}}} + \frac {\arctan \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a} - \frac {\log \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a}}{d} \] Input:
integrate(cos(d*x+c)^3*cot(d*x+c)/(a+a*sin(d*x+c)),x, algorithm="maxima")
Output:
-((sin(d*x + c)/(cos(d*x + c) + 1) - 2*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 - sin(d*x + c)^3/(cos(d*x + c) + 1)^3 - 2)/(a + 2*a*sin(d*x + c)^2/(cos(d *x + c) + 1)^2 + a*sin(d*x + c)^4/(cos(d*x + c) + 1)^4) + arctan(sin(d*x + c)/(cos(d*x + c) + 1))/a - log(sin(d*x + c)/(cos(d*x + c) + 1))/a)/d
Time = 0.16 (sec) , antiderivative size = 88, normalized size of antiderivative = 1.49 \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=-\frac {\frac {d x + c}{a} - \frac {2 \, \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right )}{a} - \frac {2 \, {\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 2 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 2\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{2} a}}{2 \, d} \] Input:
integrate(cos(d*x+c)^3*cot(d*x+c)/(a+a*sin(d*x+c)),x, algorithm="giac")
Output:
-1/2*((d*x + c)/a - 2*log(abs(tan(1/2*d*x + 1/2*c)))/a - 2*(tan(1/2*d*x + 1/2*c)^3 + 2*tan(1/2*d*x + 1/2*c)^2 - tan(1/2*d*x + 1/2*c) + 2)/((tan(1/2* d*x + 1/2*c)^2 + 1)^2*a))/d
Time = 17.77 (sec) , antiderivative size = 136, normalized size of antiderivative = 2.31 \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=\frac {\ln \left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{a\,d}+\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3+2\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2-\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+2}{d\,\left (a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4+2\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+a\right )}+\frac {\mathrm {atan}\left (\frac {1}{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+2}-\frac {2\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+2}\right )}{a\,d} \] Input:
int((cos(c + d*x)^3*cot(c + d*x))/(a + a*sin(c + d*x)),x)
Output:
log(tan(c/2 + (d*x)/2))/(a*d) + (2*tan(c/2 + (d*x)/2)^2 - tan(c/2 + (d*x)/ 2) + tan(c/2 + (d*x)/2)^3 + 2)/(d*(a + 2*a*tan(c/2 + (d*x)/2)^2 + a*tan(c/ 2 + (d*x)/2)^4)) + atan(1/(tan(c/2 + (d*x)/2) + 2) - (2*tan(c/2 + (d*x)/2) )/(tan(c/2 + (d*x)/2) + 2))/(a*d)
Time = 1.36 (sec) , antiderivative size = 51, normalized size of antiderivative = 0.86 \[ \int \frac {\cos ^3(c+d x) \cot (c+d x)}{a+a \sin (c+d x)} \, dx=\frac {-\cos \left (d x +c \right ) \sin \left (d x +c \right )+2 \cos \left (d x +c \right )+2 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )-c -d x -2}{2 a d} \] Input:
int(cos(d*x+c)^3*cot(d*x+c)/(a+a*sin(d*x+c)),x)
Output:
( - cos(c + d*x)*sin(c + d*x) + 2*cos(c + d*x) + 2*log(tan((c + d*x)/2)) - c - d*x - 2)/(2*a*d)