Integrand size = 19, antiderivative size = 133 \[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=-\frac {a}{24 d (1-\cos (c+d x))^3}+\frac {9 a}{32 d (1-\cos (c+d x))^2}-\frac {15 a}{16 d (1-\cos (c+d x))}+\frac {a}{32 d (1+\cos (c+d x))^2}-\frac {a}{4 d (1+\cos (c+d x))}-\frac {21 a \log (1-\cos (c+d x))}{32 d}-\frac {11 a \log (1+\cos (c+d x))}{32 d} \] Output:
-1/24*a/d/(1-cos(d*x+c))^3+9/32*a/d/(1-cos(d*x+c))^2-15/16*a/d/(1-cos(d*x+ c))+1/32*a/d/(1+cos(d*x+c))^2-1/4*a/d/(1+cos(d*x+c))-21/32*a*ln(1-cos(d*x+ c))/d-11/32*a*ln(1+cos(d*x+c))/d
Time = 0.19 (sec) , antiderivative size = 220, normalized size of antiderivative = 1.65 \[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=-\frac {11 a \csc ^2\left (\frac {1}{2} (c+d x)\right )}{64 d}+\frac {a \csc ^4\left (\frac {1}{2} (c+d x)\right )}{32 d}-\frac {a \csc ^6\left (\frac {1}{2} (c+d x)\right )}{384 d}-\frac {3 a \csc ^2(c+d x)}{2 d}+\frac {3 a \csc ^4(c+d x)}{4 d}-\frac {a \csc ^6(c+d x)}{6 d}+\frac {5 a \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )}{16 d}-\frac {5 a \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )}{16 d}-\frac {a \log (\sin (c+d x))}{d}+\frac {11 a \sec ^2\left (\frac {1}{2} (c+d x)\right )}{64 d}-\frac {a \sec ^4\left (\frac {1}{2} (c+d x)\right )}{32 d}+\frac {a \sec ^6\left (\frac {1}{2} (c+d x)\right )}{384 d} \] Input:
Integrate[Cot[c + d*x]^7*(a + a*Sec[c + d*x]),x]
Output:
(-11*a*Csc[(c + d*x)/2]^2)/(64*d) + (a*Csc[(c + d*x)/2]^4)/(32*d) - (a*Csc [(c + d*x)/2]^6)/(384*d) - (3*a*Csc[c + d*x]^2)/(2*d) + (3*a*Csc[c + d*x]^ 4)/(4*d) - (a*Csc[c + d*x]^6)/(6*d) + (5*a*Log[Cos[(c + d*x)/2]])/(16*d) - (5*a*Log[Sin[(c + d*x)/2]])/(16*d) - (a*Log[Sin[c + d*x]])/d + (11*a*Sec[ (c + d*x)/2]^2)/(64*d) - (a*Sec[(c + d*x)/2]^4)/(32*d) + (a*Sec[(c + d*x)/ 2]^6)/(384*d)
Time = 0.29 (sec) , antiderivative size = 111, normalized size of antiderivative = 0.83, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.316, Rules used = {3042, 25, 4367, 27, 99, 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 \cot ^7(c+d x) (a \sec (c+d x)+a) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int -\frac {a \csc \left (c+d x+\frac {\pi }{2}\right )+a}{\cot \left (c+d x+\frac {\pi }{2}\right )^7}dx\) |
\(\Big \downarrow \) 25 |
\(\displaystyle -\int \frac {\csc \left (\frac {1}{2} (2 c+\pi )+d x\right ) a+a}{\cot \left (\frac {1}{2} (2 c+\pi )+d x\right )^7}dx\) |
\(\Big \downarrow \) 4367 |
\(\displaystyle -\frac {a^8 \int \frac {\cos ^6(c+d x)}{a^7 (1-\cos (c+d x))^4 (\cos (c+d x)+1)^3}d\cos (c+d x)}{d}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\frac {a \int \frac {\cos ^6(c+d x)}{(1-\cos (c+d x))^4 (\cos (c+d x)+1)^3}d\cos (c+d x)}{d}\) |
\(\Big \downarrow \) 99 |
\(\displaystyle -\frac {a \int \left (\frac {11}{32 (\cos (c+d x)+1)}-\frac {1}{4 (\cos (c+d x)+1)^2}+\frac {1}{16 (\cos (c+d x)+1)^3}+\frac {21}{32 (\cos (c+d x)-1)}+\frac {15}{16 (\cos (c+d x)-1)^2}+\frac {9}{16 (\cos (c+d x)-1)^3}+\frac {1}{8 (\cos (c+d x)-1)^4}\right )d\cos (c+d x)}{d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {a \left (\frac {15}{16 (1-\cos (c+d x))}+\frac {1}{4 (\cos (c+d x)+1)}-\frac {9}{32 (1-\cos (c+d x))^2}-\frac {1}{32 (\cos (c+d x)+1)^2}+\frac {1}{24 (1-\cos (c+d x))^3}+\frac {21}{32} \log (1-\cos (c+d x))+\frac {11}{32} \log (\cos (c+d x)+1)\right )}{d}\) |
Input:
Int[Cot[c + d*x]^7*(a + a*Sec[c + d*x]),x]
Output:
-((a*(1/(24*(1 - Cos[c + d*x])^3) - 9/(32*(1 - Cos[c + d*x])^2) + 15/(16*( 1 - Cos[c + d*x])) - 1/(32*(1 + Cos[c + d*x])^2) + 1/(4*(1 + Cos[c + d*x]) ) + (21*Log[1 - Cos[c + d*x]])/32 + (11*Log[1 + Cos[c + d*x]])/32))/d)
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_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) )^(p_), x_] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, p}, x] && IntegersQ[m, n] && (IntegerQ[p] | | (GtQ[m, 0] && GeQ[n, -1]))
Int[cot[(c_.) + (d_.)*(x_)]^(m_.)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(n _.), x_Symbol] :> Simp[1/(a^(m - n - 1)*b^n*d) Subst[Int[(a - b*x)^((m - 1)/2)*((a + b*x)^((m - 1)/2 + n)/x^(m + n)), x], x, Sin[c + d*x]], x] /; Fr eeQ[{a, b, c, d}, x] && IntegerQ[(m - 1)/2] && EqQ[a^2 - b^2, 0] && Integer Q[n]
Time = 0.44 (sec) , antiderivative size = 151, normalized size of antiderivative = 1.14
method | result | size |
derivativedivides | \(\frac {a \left (-\frac {\cos \left (d x +c \right )^{7}}{6 \sin \left (d x +c \right )^{6}}+\frac {\cos \left (d x +c \right )^{7}}{24 \sin \left (d x +c \right )^{4}}-\frac {\cos \left (d x +c \right )^{7}}{16 \sin \left (d x +c \right )^{2}}-\frac {\cos \left (d x +c \right )^{5}}{16}-\frac {5 \cos \left (d x +c \right )^{3}}{48}-\frac {5 \cos \left (d x +c \right )}{16}-\frac {5 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{16}\right )+a \left (-\frac {\cot \left (d x +c \right )^{6}}{6}+\frac {\cot \left (d x +c \right )^{4}}{4}-\frac {\cot \left (d x +c \right )^{2}}{2}-\ln \left (\sin \left (d x +c \right )\right )\right )}{d}\) | \(151\) |
default | \(\frac {a \left (-\frac {\cos \left (d x +c \right )^{7}}{6 \sin \left (d x +c \right )^{6}}+\frac {\cos \left (d x +c \right )^{7}}{24 \sin \left (d x +c \right )^{4}}-\frac {\cos \left (d x +c \right )^{7}}{16 \sin \left (d x +c \right )^{2}}-\frac {\cos \left (d x +c \right )^{5}}{16}-\frac {5 \cos \left (d x +c \right )^{3}}{48}-\frac {5 \cos \left (d x +c \right )}{16}-\frac {5 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{16}\right )+a \left (-\frac {\cot \left (d x +c \right )^{6}}{6}+\frac {\cot \left (d x +c \right )^{4}}{4}-\frac {\cot \left (d x +c \right )^{2}}{2}-\ln \left (\sin \left (d x +c \right )\right )\right )}{d}\) | \(151\) |
risch | \(i a x +\frac {2 i a c}{d}+\frac {a \left (33 \,{\mathrm e}^{9 i \left (d x +c \right )}+78 \,{\mathrm e}^{8 i \left (d x +c \right )}-184 \,{\mathrm e}^{7 i \left (d x +c \right )}+2 \,{\mathrm e}^{6 i \left (d x +c \right )}+270 \,{\mathrm e}^{5 i \left (d x +c \right )}+2 \,{\mathrm e}^{4 i \left (d x +c \right )}-184 \,{\mathrm e}^{3 i \left (d x +c \right )}+78 \,{\mathrm e}^{2 i \left (d x +c \right )}+33 \,{\mathrm e}^{i \left (d x +c \right )}\right )}{24 d \left ({\mathrm e}^{i \left (d x +c \right )}-1\right )^{6} \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )^{4}}-\frac {11 a \ln \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )}{16 d}-\frac {21 a \ln \left ({\mathrm e}^{i \left (d x +c \right )}-1\right )}{16 d}\) | \(183\) |
Input:
int(cot(d*x+c)^7*(a+a*sec(d*x+c)),x,method=_RETURNVERBOSE)
Output:
1/d*(a*(-1/6/sin(d*x+c)^6*cos(d*x+c)^7+1/24/sin(d*x+c)^4*cos(d*x+c)^7-1/16 /sin(d*x+c)^2*cos(d*x+c)^7-1/16*cos(d*x+c)^5-5/48*cos(d*x+c)^3-5/16*cos(d* x+c)-5/16*ln(csc(d*x+c)-cot(d*x+c)))+a*(-1/6*cot(d*x+c)^6+1/4*cot(d*x+c)^4 -1/2*cot(d*x+c)^2-ln(sin(d*x+c))))
Leaf count of result is larger than twice the leaf count of optimal. 241 vs. \(2 (113) = 226\).
Time = 0.10 (sec) , antiderivative size = 241, normalized size of antiderivative = 1.81 \[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=\frac {66 \, a \cos \left (d x + c\right )^{4} + 78 \, a \cos \left (d x + c\right )^{3} - 158 \, a \cos \left (d x + c\right )^{2} - 58 \, a \cos \left (d x + c\right ) - 33 \, {\left (a \cos \left (d x + c\right )^{5} - a \cos \left (d x + c\right )^{4} - 2 \, a \cos \left (d x + c\right )^{3} + 2 \, a \cos \left (d x + c\right )^{2} + a \cos \left (d x + c\right ) - a\right )} \log \left (\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) - 63 \, {\left (a \cos \left (d x + c\right )^{5} - a \cos \left (d x + c\right )^{4} - 2 \, a \cos \left (d x + c\right )^{3} + 2 \, a \cos \left (d x + c\right )^{2} + a \cos \left (d x + c\right ) - a\right )} \log \left (-\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) + 88 \, a}{96 \, {\left (d \cos \left (d x + c\right )^{5} - d \cos \left (d x + c\right )^{4} - 2 \, d \cos \left (d x + c\right )^{3} + 2 \, d \cos \left (d x + c\right )^{2} + d \cos \left (d x + c\right ) - d\right )}} \] Input:
integrate(cot(d*x+c)^7*(a+a*sec(d*x+c)),x, algorithm="fricas")
Output:
1/96*(66*a*cos(d*x + c)^4 + 78*a*cos(d*x + c)^3 - 158*a*cos(d*x + c)^2 - 5 8*a*cos(d*x + c) - 33*(a*cos(d*x + c)^5 - a*cos(d*x + c)^4 - 2*a*cos(d*x + c)^3 + 2*a*cos(d*x + c)^2 + a*cos(d*x + c) - a)*log(1/2*cos(d*x + c) + 1/ 2) - 63*(a*cos(d*x + c)^5 - a*cos(d*x + c)^4 - 2*a*cos(d*x + c)^3 + 2*a*co s(d*x + c)^2 + a*cos(d*x + c) - a)*log(-1/2*cos(d*x + c) + 1/2) + 88*a)/(d *cos(d*x + c)^5 - d*cos(d*x + c)^4 - 2*d*cos(d*x + c)^3 + 2*d*cos(d*x + c) ^2 + d*cos(d*x + c) - d)
\[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=a \left (\int \cot ^{7}{\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx + \int \cot ^{7}{\left (c + d x \right )}\, dx\right ) \] Input:
integrate(cot(d*x+c)**7*(a+a*sec(d*x+c)),x)
Output:
a*(Integral(cot(c + d*x)**7*sec(c + d*x), x) + Integral(cot(c + d*x)**7, x ))
Time = 0.04 (sec) , antiderivative size = 126, normalized size of antiderivative = 0.95 \[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=-\frac {33 \, a \log \left (\cos \left (d x + c\right ) + 1\right ) + 63 \, a \log \left (\cos \left (d x + c\right ) - 1\right ) - \frac {2 \, {\left (33 \, a \cos \left (d x + c\right )^{4} + 39 \, a \cos \left (d x + c\right )^{3} - 79 \, a \cos \left (d x + c\right )^{2} - 29 \, a \cos \left (d x + c\right ) + 44 \, a\right )}}{\cos \left (d x + c\right )^{5} - \cos \left (d x + c\right )^{4} - 2 \, \cos \left (d x + c\right )^{3} + 2 \, \cos \left (d x + c\right )^{2} + \cos \left (d x + c\right ) - 1}}{96 \, d} \] Input:
integrate(cot(d*x+c)^7*(a+a*sec(d*x+c)),x, algorithm="maxima")
Output:
-1/96*(33*a*log(cos(d*x + c) + 1) + 63*a*log(cos(d*x + c) - 1) - 2*(33*a*c os(d*x + c)^4 + 39*a*cos(d*x + c)^3 - 79*a*cos(d*x + c)^2 - 29*a*cos(d*x + c) + 44*a)/(cos(d*x + c)^5 - cos(d*x + c)^4 - 2*cos(d*x + c)^3 + 2*cos(d* x + c)^2 + cos(d*x + c) - 1))/d
Time = 0.15 (sec) , antiderivative size = 99, normalized size of antiderivative = 0.74 \[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=-\frac {1}{96} \, a {\left (\frac {33 \, \log \left ({\left | \cos \left (d x + c\right ) + 1 \right |}\right )}{d} + \frac {63 \, \log \left ({\left | \cos \left (d x + c\right ) - 1 \right |}\right )}{d} - \frac {2 \, {\left (33 \, \cos \left (d x + c\right )^{4} + 39 \, \cos \left (d x + c\right )^{3} - 79 \, \cos \left (d x + c\right )^{2} - 29 \, \cos \left (d x + c\right ) + 44\right )}}{d {\left (\cos \left (d x + c\right ) + 1\right )}^{2} {\left (\cos \left (d x + c\right ) - 1\right )}^{3}}\right )} \] Input:
integrate(cot(d*x+c)^7*(a+a*sec(d*x+c)),x, algorithm="giac")
Output:
-1/96*a*(33*log(abs(cos(d*x + c) + 1))/d + 63*log(abs(cos(d*x + c) - 1))/d - 2*(33*cos(d*x + c)^4 + 39*cos(d*x + c)^3 - 79*cos(d*x + c)^2 - 29*cos(d *x + c) + 44)/(d*(cos(d*x + c) + 1)^2*(cos(d*x + c) - 1)^3))
Time = 13.31 (sec) , antiderivative size = 118, normalized size of antiderivative = 0.89 \[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=\frac {a\,\ln \left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )}{d}-\frac {{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6\,\left (11\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4-\frac {7\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{4}+\frac {a}{6}\right )}{32\,d}-\frac {7\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{64\,d}+\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4}{128\,d}-\frac {21\,a\,\ln \left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{16\,d} \] Input:
int(cot(c + d*x)^7*(a + a/cos(c + d*x)),x)
Output:
(a*log(tan(c/2 + (d*x)/2)^2 + 1))/d - (cot(c/2 + (d*x)/2)^6*(a/6 - (7*a*ta n(c/2 + (d*x)/2)^2)/4 + 11*a*tan(c/2 + (d*x)/2)^4))/(32*d) - (7*a*tan(c/2 + (d*x)/2)^2)/(64*d) + (a*tan(c/2 + (d*x)/2)^4)/(128*d) - (21*a*log(tan(c/ 2 + (d*x)/2)))/(16*d)
Time = 0.17 (sec) , antiderivative size = 121, normalized size of antiderivative = 0.91 \[ \int \cot ^7(c+d x) (a+a \sec (c+d x)) \, dx=\frac {a \left (384 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{6}-504 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{6}+3 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{10}-42 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{8}-132 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+21 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-2\right )}{384 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{6} d} \] Input:
int(cot(d*x+c)^7*(a+a*sec(d*x+c)),x)
Output:
(a*(384*log(tan((c + d*x)/2)**2 + 1)*tan((c + d*x)/2)**6 - 504*log(tan((c + d*x)/2))*tan((c + d*x)/2)**6 + 3*tan((c + d*x)/2)**10 - 42*tan((c + d*x) /2)**8 - 132*tan((c + d*x)/2)**4 + 21*tan((c + d*x)/2)**2 - 2))/(384*tan(( c + d*x)/2)**6*d)