Integrand size = 27, antiderivative size = 60 \[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=-\frac {\csc (c+d x)}{a d}-\frac {b \log (\sin (c+d x))}{a^2 d}-\frac {\left (1-\frac {b^2}{a^2}\right ) \log (a+b \sin (c+d x))}{b d} \] Output:
-csc(d*x+c)/a/d-b*ln(sin(d*x+c))/a^2/d-(1-b^2/a^2)*ln(a+b*sin(d*x+c))/b/d
Time = 0.07 (sec) , antiderivative size = 54, normalized size of antiderivative = 0.90 \[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=\frac {-a b \csc (c+d x)-b^2 \log (\sin (c+d x))+\left (-a^2+b^2\right ) \log (a+b \sin (c+d x))}{a^2 b d} \] Input:
Integrate[(Cos[c + d*x]*Cot[c + d*x]^2)/(a + b*Sin[c + d*x]),x]
Output:
(-(a*b*Csc[c + d*x]) - b^2*Log[Sin[c + d*x]] + (-a^2 + b^2)*Log[a + b*Sin[ c + d*x]])/(a^2*b*d)
Time = 0.32 (sec) , antiderivative size = 60, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.185, Rules used = {3042, 3316, 27, 522, 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 \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\cos (c+d x)^3}{\sin (c+d x)^2 (a+b \sin (c+d x))}dx\) |
\(\Big \downarrow \) 3316 |
\(\displaystyle \frac {\int \frac {\csc ^2(c+d x) \left (b^2-b^2 \sin ^2(c+d x)\right )}{a+b \sin (c+d x)}d(b \sin (c+d x))}{b^3 d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {\int \frac {\csc ^2(c+d x) \left (b^2-b^2 \sin ^2(c+d x)\right )}{b^2 (a+b \sin (c+d x))}d(b \sin (c+d x))}{b d}\) |
\(\Big \downarrow \) 522 |
\(\displaystyle \frac {\int \left (\frac {\csc ^2(c+d x)}{a}-\frac {b \csc (c+d x)}{a^2}+\frac {b^2-a^2}{a^2 (a+b \sin (c+d x))}\right )d(b \sin (c+d x))}{b d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {-\frac {b^2 \log (b \sin (c+d x))}{a^2}-\left (1-\frac {b^2}{a^2}\right ) \log (a+b \sin (c+d x))-\frac {b \csc (c+d x)}{a}}{b d}\) |
Input:
Int[(Cos[c + d*x]*Cot[c + d*x]^2)/(a + b*Sin[c + d*x]),x]
Output:
(-((b*Csc[c + d*x])/a) - (b^2*Log[b*Sin[c + d*x]])/a^2 - (1 - b^2/a^2)*Log [a + b*Sin[c + d*x]])/(b*d)
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((e_.)*(x_))^(m_.)*((c_) + (d_.)*(x_))^(n_.)*((a_) + (b_.)*(x_)^2)^(p_. ), x_Symbol] :> Int[ExpandIntegrand[(e*x)^m*(c + d*x)^n*(a + b*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, m, n}, x] && IGtQ[p, 0]
Int[cos[(e_.) + (f_.)*(x_)]^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_ .)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Simp[1/(b^p* f) Subst[Int[(a + x)^m*(c + (d/b)*x)^n*(b^2 - x^2)^((p - 1)/2), x], x, b* Sin[e + f*x]], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IntegerQ[(p - 1) /2] && NeQ[a^2 - b^2, 0]
Time = 0.89 (sec) , antiderivative size = 59, normalized size of antiderivative = 0.98
method | result | size |
derivativedivides | \(\frac {\frac {\left (-a^{2}+b^{2}\right ) \ln \left (a +b \sin \left (d x +c \right )\right )}{a^{2} b}-\frac {1}{a \sin \left (d x +c \right )}-\frac {b \ln \left (\sin \left (d x +c \right )\right )}{a^{2}}}{d}\) | \(59\) |
default | \(\frac {\frac {\left (-a^{2}+b^{2}\right ) \ln \left (a +b \sin \left (d x +c \right )\right )}{a^{2} b}-\frac {1}{a \sin \left (d x +c \right )}-\frac {b \ln \left (\sin \left (d x +c \right )\right )}{a^{2}}}{d}\) | \(59\) |
risch | \(\frac {i x}{b}+\frac {2 i c}{b d}-\frac {2 i {\mathrm e}^{i \left (d x +c \right )}}{d a \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )}-\frac {b \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )}{a^{2} d}-\frac {\ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{b}-1\right )}{b d}+\frac {b \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{b}-1\right )}{a^{2} d}\) | \(143\) |
Input:
int(cos(d*x+c)*cot(d*x+c)^2/(a+b*sin(d*x+c)),x,method=_RETURNVERBOSE)
Output:
1/d*((-a^2+b^2)/a^2/b*ln(a+b*sin(d*x+c))-1/a/sin(d*x+c)-b/a^2*ln(sin(d*x+c )))
Time = 0.10 (sec) , antiderivative size = 69, normalized size of antiderivative = 1.15 \[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=-\frac {b^{2} \log \left (\frac {1}{2} \, \sin \left (d x + c\right )\right ) \sin \left (d x + c\right ) + {\left (a^{2} - b^{2}\right )} \log \left (b \sin \left (d x + c\right ) + a\right ) \sin \left (d x + c\right ) + a b}{a^{2} b d \sin \left (d x + c\right )} \] Input:
integrate(cos(d*x+c)*cot(d*x+c)^2/(a+b*sin(d*x+c)),x, algorithm="fricas")
Output:
-(b^2*log(1/2*sin(d*x + c))*sin(d*x + c) + (a^2 - b^2)*log(b*sin(d*x + c) + a)*sin(d*x + c) + a*b)/(a^2*b*d*sin(d*x + c))
\[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=\int \frac {\cos {\left (c + d x \right )} \cot ^{2}{\left (c + d x \right )}}{a + b \sin {\left (c + d x \right )}}\, dx \] Input:
integrate(cos(d*x+c)*cot(d*x+c)**2/(a+b*sin(d*x+c)),x)
Output:
Integral(cos(c + d*x)*cot(c + d*x)**2/(a + b*sin(c + d*x)), x)
Time = 0.03 (sec) , antiderivative size = 57, normalized size of antiderivative = 0.95 \[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=-\frac {\frac {b \log \left (\sin \left (d x + c\right )\right )}{a^{2}} + \frac {{\left (a^{2} - b^{2}\right )} \log \left (b \sin \left (d x + c\right ) + a\right )}{a^{2} b} + \frac {1}{a \sin \left (d x + c\right )}}{d} \] Input:
integrate(cos(d*x+c)*cot(d*x+c)^2/(a+b*sin(d*x+c)),x, algorithm="maxima")
Output:
-(b*log(sin(d*x + c))/a^2 + (a^2 - b^2)*log(b*sin(d*x + c) + a)/(a^2*b) + 1/(a*sin(d*x + c)))/d
Time = 0.13 (sec) , antiderivative size = 66, normalized size of antiderivative = 1.10 \[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=-\frac {b \log \left ({\left | \sin \left (d x + c\right ) \right |}\right )}{a^{2} d} - \frac {{\left (a^{2} - b^{2}\right )} \log \left ({\left | b \sin \left (d x + c\right ) + a \right |}\right )}{a^{2} b d} - \frac {1}{a d \sin \left (d x + c\right )} \] Input:
integrate(cos(d*x+c)*cot(d*x+c)^2/(a+b*sin(d*x+c)),x, algorithm="giac")
Output:
-b*log(abs(sin(d*x + c)))/(a^2*d) - (a^2 - b^2)*log(abs(b*sin(d*x + c) + a ))/(a^2*b*d) - 1/(a*d*sin(d*x + c))
Time = 39.21 (sec) , antiderivative size = 118, normalized size of antiderivative = 1.97 \[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=\frac {\ln \left (a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+2\,b\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+a\right )\,\left (\frac {b}{a^2}-\frac {1}{b}\right )}{d}-\frac {\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{2\,a\,d}-\frac {\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{2\,a\,d}+\frac {\ln \left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )}{b\,d}-\frac {b\,\ln \left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{a^2\,d} \] Input:
int((cos(c + d*x)*cot(c + d*x)^2)/(a + b*sin(c + d*x)),x)
Output:
(log(a + 2*b*tan(c/2 + (d*x)/2) + a*tan(c/2 + (d*x)/2)^2)*(b/a^2 - 1/b))/d - tan(c/2 + (d*x)/2)/(2*a*d) - cot(c/2 + (d*x)/2)/(2*a*d) + log(tan(c/2 + (d*x)/2)^2 + 1)/(b*d) - (b*log(tan(c/2 + (d*x)/2)))/(a^2*d)
Time = 1.16 (sec) , antiderivative size = 145, normalized size of antiderivative = 2.42 \[ \int \frac {\cos (c+d x) \cot ^2(c+d x)}{a+b \sin (c+d x)} \, dx=\frac {\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) \sin \left (d x +c \right ) a^{2}-\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right ) b +a \right ) \sin \left (d x +c \right ) a^{2}+\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right ) b +a \right ) \sin \left (d x +c \right ) b^{2}-\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \sin \left (d x +c \right ) b^{2}-a b}{\sin \left (d x +c \right ) a^{2} b d} \] Input:
int(cos(d*x+c)*cot(d*x+c)^2/(a+b*sin(d*x+c)),x)
Output:
(log(tan((c + d*x)/2)**2 + 1)*sin(c + d*x)*a**2 - log(tan((c + d*x)/2)**2* a + 2*tan((c + d*x)/2)*b + a)*sin(c + d*x)*a**2 + log(tan((c + d*x)/2)**2* a + 2*tan((c + d*x)/2)*b + a)*sin(c + d*x)*b**2 - log(tan((c + d*x)/2))*si n(c + d*x)*b**2 - a*b)/(sin(c + d*x)*a**2*b*d)