Integrand size = 29, antiderivative size = 132 \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=-\frac {7 a^2 \text {arctanh}(\cos (c+d x))}{16 d}-\frac {2 a^2 \cot ^5(c+d x)}{5 d}+\frac {5 a^2 \cot (c+d x) \csc (c+d x)}{16 d}-\frac {a^2 \cot ^3(c+d x) \csc (c+d x)}{4 d}+\frac {a^2 \cot (c+d x) \csc ^3(c+d x)}{8 d}-\frac {a^2 \cot ^3(c+d x) \csc ^3(c+d x)}{6 d} \] Output:
-7/16*a^2*arctanh(cos(d*x+c))/d-2/5*a^2*cot(d*x+c)^5/d+5/16*a^2*cot(d*x+c) *csc(d*x+c)/d-1/4*a^2*cot(d*x+c)^3*csc(d*x+c)/d+1/8*a^2*cot(d*x+c)*csc(d*x +c)^3/d-1/6*a^2*cot(d*x+c)^3*csc(d*x+c)^3/d
Leaf count is larger than twice the leaf count of optimal. \(267\) vs. \(2(132)=264\).
Time = 0.29 (sec) , antiderivative size = 267, normalized size of antiderivative = 2.02 \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=a^2 \left (-\frac {\cot \left (\frac {1}{2} (c+d x)\right )}{5 d}+\frac {9 \csc ^2\left (\frac {1}{2} (c+d x)\right )}{64 d}+\frac {7 \cot \left (\frac {1}{2} (c+d x)\right ) \csc ^2\left (\frac {1}{2} (c+d x)\right )}{80 d}-\frac {\cot \left (\frac {1}{2} (c+d x)\right ) \csc ^4\left (\frac {1}{2} (c+d x)\right )}{80 d}-\frac {\csc ^6\left (\frac {1}{2} (c+d x)\right )}{384 d}-\frac {7 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )}{16 d}+\frac {7 \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )}{16 d}-\frac {9 \sec ^2\left (\frac {1}{2} (c+d x)\right )}{64 d}+\frac {\sec ^6\left (\frac {1}{2} (c+d x)\right )}{384 d}+\frac {\tan \left (\frac {1}{2} (c+d x)\right )}{5 d}-\frac {7 \sec ^2\left (\frac {1}{2} (c+d x)\right ) \tan \left (\frac {1}{2} (c+d x)\right )}{80 d}+\frac {\sec ^4\left (\frac {1}{2} (c+d x)\right ) \tan \left (\frac {1}{2} (c+d x)\right )}{80 d}\right ) \] Input:
Integrate[Cot[c + d*x]^4*Csc[c + d*x]^3*(a + a*Sin[c + d*x])^2,x]
Output:
a^2*(-1/5*Cot[(c + d*x)/2]/d + (9*Csc[(c + d*x)/2]^2)/(64*d) + (7*Cot[(c + d*x)/2]*Csc[(c + d*x)/2]^2)/(80*d) - (Cot[(c + d*x)/2]*Csc[(c + d*x)/2]^4 )/(80*d) - Csc[(c + d*x)/2]^6/(384*d) - (7*Log[Cos[(c + d*x)/2]])/(16*d) + (7*Log[Sin[(c + d*x)/2]])/(16*d) - (9*Sec[(c + d*x)/2]^2)/(64*d) + Sec[(c + d*x)/2]^6/(384*d) + Tan[(c + d*x)/2]/(5*d) - (7*Sec[(c + d*x)/2]^2*Tan[ (c + d*x)/2])/(80*d) + (Sec[(c + d*x)/2]^4*Tan[(c + d*x)/2])/(80*d))
Time = 0.48 (sec) , antiderivative size = 132, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.103, Rules used = {3042, 3352, 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 ^4(c+d x) \csc ^3(c+d x) (a \sin (c+d x)+a)^2 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\cos (c+d x)^4 (a \sin (c+d x)+a)^2}{\sin (c+d x)^7}dx\) |
\(\Big \downarrow \) 3352 |
\(\displaystyle \int \left (a^2 \cot ^4(c+d x) \csc ^3(c+d x)+2 a^2 \cot ^4(c+d x) \csc ^2(c+d x)+a^2 \cot ^4(c+d x) \csc (c+d x)\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {7 a^2 \text {arctanh}(\cos (c+d x))}{16 d}-\frac {2 a^2 \cot ^5(c+d x)}{5 d}-\frac {a^2 \cot ^3(c+d x) \csc ^3(c+d x)}{6 d}-\frac {a^2 \cot ^3(c+d x) \csc (c+d x)}{4 d}+\frac {a^2 \cot (c+d x) \csc ^3(c+d x)}{8 d}+\frac {5 a^2 \cot (c+d x) \csc (c+d x)}{16 d}\) |
Input:
Int[Cot[c + d*x]^4*Csc[c + d*x]^3*(a + a*Sin[c + d*x])^2,x]
Output:
(-7*a^2*ArcTanh[Cos[c + d*x]])/(16*d) - (2*a^2*Cot[c + d*x]^5)/(5*d) + (5* a^2*Cot[c + d*x]*Csc[c + d*x])/(16*d) - (a^2*Cot[c + d*x]^3*Csc[c + d*x])/ (4*d) + (a^2*Cot[c + d*x]*Csc[c + d*x]^3)/(8*d) - (a^2*Cot[c + d*x]^3*Csc[ c + d*x]^3)/(6*d)
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n _)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> Int[ExpandTrig [(g*cos[e + f*x])^p, (d*sin[e + f*x])^n*(a + b*sin[e + f*x])^m, x], x] /; F reeQ[{a, b, d, e, f, g, n, p}, x] && EqQ[a^2 - b^2, 0] && IGtQ[m, 0]
Result contains complex when optimal does not.
Time = 0.34 (sec) , antiderivative size = 192, normalized size of antiderivative = 1.45
method | result | size |
risch | \(-\frac {a^{2} \left (135 \,{\mathrm e}^{11 i \left (d x +c \right )}-445 \,{\mathrm e}^{9 i \left (d x +c \right )}+480 i {\mathrm e}^{10 i \left (d x +c \right )}-330 \,{\mathrm e}^{7 i \left (d x +c \right )}-480 i {\mathrm e}^{8 i \left (d x +c \right )}-330 \,{\mathrm e}^{5 i \left (d x +c \right )}+960 i {\mathrm e}^{6 i \left (d x +c \right )}-445 \,{\mathrm e}^{3 i \left (d x +c \right )}-960 i {\mathrm e}^{4 i \left (d x +c \right )}+135 \,{\mathrm e}^{i \left (d x +c \right )}+96 i {\mathrm e}^{2 i \left (d x +c \right )}-96 i\right )}{120 d \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )^{6}}-\frac {7 a^{2} \ln \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )}{16 d}+\frac {7 a^{2} \ln \left ({\mathrm e}^{i \left (d x +c \right )}-1\right )}{16 d}\) | \(192\) |
derivativedivides | \(\frac {a^{2} \left (-\frac {\cos \left (d x +c \right )^{5}}{4 \sin \left (d x +c \right )^{4}}+\frac {\cos \left (d x +c \right )^{5}}{8 \sin \left (d x +c \right )^{2}}+\frac {\cos \left (d x +c \right )^{3}}{8}+\frac {3 \cos \left (d x +c \right )}{8}+\frac {3 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{8}\right )-\frac {2 a^{2} \cos \left (d x +c \right )^{5}}{5 \sin \left (d x +c \right )^{5}}+a^{2} \left (-\frac {\cos \left (d x +c \right )^{5}}{6 \sin \left (d x +c \right )^{6}}-\frac {\cos \left (d x +c \right )^{5}}{24 \sin \left (d x +c \right )^{4}}+\frac {\cos \left (d x +c \right )^{5}}{48 \sin \left (d x +c \right )^{2}}+\frac {\cos \left (d x +c \right )^{3}}{48}+\frac {\cos \left (d x +c \right )}{16}+\frac {\ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{16}\right )}{d}\) | \(199\) |
default | \(\frac {a^{2} \left (-\frac {\cos \left (d x +c \right )^{5}}{4 \sin \left (d x +c \right )^{4}}+\frac {\cos \left (d x +c \right )^{5}}{8 \sin \left (d x +c \right )^{2}}+\frac {\cos \left (d x +c \right )^{3}}{8}+\frac {3 \cos \left (d x +c \right )}{8}+\frac {3 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{8}\right )-\frac {2 a^{2} \cos \left (d x +c \right )^{5}}{5 \sin \left (d x +c \right )^{5}}+a^{2} \left (-\frac {\cos \left (d x +c \right )^{5}}{6 \sin \left (d x +c \right )^{6}}-\frac {\cos \left (d x +c \right )^{5}}{24 \sin \left (d x +c \right )^{4}}+\frac {\cos \left (d x +c \right )^{5}}{48 \sin \left (d x +c \right )^{2}}+\frac {\cos \left (d x +c \right )^{3}}{48}+\frac {\cos \left (d x +c \right )}{16}+\frac {\ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{16}\right )}{d}\) | \(199\) |
Input:
int(cot(d*x+c)^4*csc(d*x+c)^3*(a+a*sin(d*x+c))^2,x,method=_RETURNVERBOSE)
Output:
-1/120*a^2*(135*exp(11*I*(d*x+c))-445*exp(9*I*(d*x+c))+480*I*exp(10*I*(d*x +c))-330*exp(7*I*(d*x+c))-480*I*exp(8*I*(d*x+c))-330*exp(5*I*(d*x+c))+960* I*exp(6*I*(d*x+c))-445*exp(3*I*(d*x+c))-960*I*exp(4*I*(d*x+c))+135*exp(I*( d*x+c))+96*I*exp(2*I*(d*x+c))-96*I)/d/(exp(2*I*(d*x+c))-1)^6-7/16*a^2/d*ln (exp(I*(d*x+c))+1)+7/16*a^2/d*ln(exp(I*(d*x+c))-1)
Time = 0.10 (sec) , antiderivative size = 211, normalized size of antiderivative = 1.60 \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=\frac {192 \, a^{2} \cos \left (d x + c\right )^{5} \sin \left (d x + c\right ) - 270 \, a^{2} \cos \left (d x + c\right )^{5} + 560 \, a^{2} \cos \left (d x + c\right )^{3} - 210 \, a^{2} \cos \left (d x + c\right ) - 105 \, {\left (a^{2} \cos \left (d x + c\right )^{6} - 3 \, a^{2} \cos \left (d x + c\right )^{4} + 3 \, a^{2} \cos \left (d x + c\right )^{2} - a^{2}\right )} \log \left (\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) + 105 \, {\left (a^{2} \cos \left (d x + c\right )^{6} - 3 \, a^{2} \cos \left (d x + c\right )^{4} + 3 \, a^{2} \cos \left (d x + c\right )^{2} - a^{2}\right )} \log \left (-\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right )}{480 \, {\left (d \cos \left (d x + c\right )^{6} - 3 \, d \cos \left (d x + c\right )^{4} + 3 \, d \cos \left (d x + c\right )^{2} - d\right )}} \] Input:
integrate(cot(d*x+c)^4*csc(d*x+c)^3*(a+a*sin(d*x+c))^2,x, algorithm="frica s")
Output:
1/480*(192*a^2*cos(d*x + c)^5*sin(d*x + c) - 270*a^2*cos(d*x + c)^5 + 560* a^2*cos(d*x + c)^3 - 210*a^2*cos(d*x + c) - 105*(a^2*cos(d*x + c)^6 - 3*a^ 2*cos(d*x + c)^4 + 3*a^2*cos(d*x + c)^2 - a^2)*log(1/2*cos(d*x + c) + 1/2) + 105*(a^2*cos(d*x + c)^6 - 3*a^2*cos(d*x + c)^4 + 3*a^2*cos(d*x + c)^2 - a^2)*log(-1/2*cos(d*x + c) + 1/2))/(d*cos(d*x + c)^6 - 3*d*cos(d*x + c)^4 + 3*d*cos(d*x + c)^2 - d)
Timed out. \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=\text {Timed out} \] Input:
integrate(cot(d*x+c)**4*csc(d*x+c)**3*(a+a*sin(d*x+c))**2,x)
Output:
Timed out
Time = 0.04 (sec) , antiderivative size = 181, normalized size of antiderivative = 1.37 \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=\frac {5 \, a^{2} {\left (\frac {2 \, {\left (3 \, \cos \left (d x + c\right )^{5} + 8 \, \cos \left (d x + c\right )^{3} - 3 \, \cos \left (d x + c\right )\right )}}{\cos \left (d x + c\right )^{6} - 3 \, \cos \left (d x + c\right )^{4} + 3 \, \cos \left (d x + c\right )^{2} - 1} - 3 \, \log \left (\cos \left (d x + c\right ) + 1\right ) + 3 \, \log \left (\cos \left (d x + c\right ) - 1\right )\right )} - 30 \, a^{2} {\left (\frac {2 \, {\left (5 \, \cos \left (d x + c\right )^{3} - 3 \, \cos \left (d x + c\right )\right )}}{\cos \left (d x + c\right )^{4} - 2 \, \cos \left (d x + c\right )^{2} + 1} + 3 \, \log \left (\cos \left (d x + c\right ) + 1\right ) - 3 \, \log \left (\cos \left (d x + c\right ) - 1\right )\right )} - \frac {192 \, a^{2}}{\tan \left (d x + c\right )^{5}}}{480 \, d} \] Input:
integrate(cot(d*x+c)^4*csc(d*x+c)^3*(a+a*sin(d*x+c))^2,x, algorithm="maxim a")
Output:
1/480*(5*a^2*(2*(3*cos(d*x + c)^5 + 8*cos(d*x + c)^3 - 3*cos(d*x + c))/(co s(d*x + c)^6 - 3*cos(d*x + c)^4 + 3*cos(d*x + c)^2 - 1) - 3*log(cos(d*x + c) + 1) + 3*log(cos(d*x + c) - 1)) - 30*a^2*(2*(5*cos(d*x + c)^3 - 3*cos(d *x + c))/(cos(d*x + c)^4 - 2*cos(d*x + c)^2 + 1) + 3*log(cos(d*x + c) + 1) - 3*log(cos(d*x + c) - 1)) - 192*a^2/tan(d*x + c)^5)/d
Time = 0.23 (sec) , antiderivative size = 229, normalized size of antiderivative = 1.73 \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=\frac {5 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{6} + 24 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 15 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 120 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 255 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 840 \, a^{2} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right ) + 240 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - \frac {2058 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{6} + 240 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 255 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 120 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 15 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 24 \, a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 5 \, a^{2}}{\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{6}}}{1920 \, d} \] Input:
integrate(cot(d*x+c)^4*csc(d*x+c)^3*(a+a*sin(d*x+c))^2,x, algorithm="giac" )
Output:
1/1920*(5*a^2*tan(1/2*d*x + 1/2*c)^6 + 24*a^2*tan(1/2*d*x + 1/2*c)^5 + 15* a^2*tan(1/2*d*x + 1/2*c)^4 - 120*a^2*tan(1/2*d*x + 1/2*c)^3 - 255*a^2*tan( 1/2*d*x + 1/2*c)^2 + 840*a^2*log(abs(tan(1/2*d*x + 1/2*c))) + 240*a^2*tan( 1/2*d*x + 1/2*c) - (2058*a^2*tan(1/2*d*x + 1/2*c)^6 + 240*a^2*tan(1/2*d*x + 1/2*c)^5 - 255*a^2*tan(1/2*d*x + 1/2*c)^4 - 120*a^2*tan(1/2*d*x + 1/2*c) ^3 + 15*a^2*tan(1/2*d*x + 1/2*c)^2 + 24*a^2*tan(1/2*d*x + 1/2*c) + 5*a^2)/ tan(1/2*d*x + 1/2*c)^6)/d
Time = 18.28 (sec) , antiderivative size = 339, normalized size of antiderivative = 2.57 \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=\frac {a^2\,\left (5\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{12}-5\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{12}+24\,\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{11}-24\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{11}\,\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )+15\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{10}-120\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^9-255\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8+240\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7-240\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5+255\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4+120\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^9\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3-15\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{10}\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+840\,\ln \left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6\right )}{1920\,d\,{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6\,{\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6} \] Input:
int((cot(c + d*x)^4*(a + a*sin(c + d*x))^2)/sin(c + d*x)^3,x)
Output:
(a^2*(5*sin(c/2 + (d*x)/2)^12 - 5*cos(c/2 + (d*x)/2)^12 + 24*cos(c/2 + (d* x)/2)*sin(c/2 + (d*x)/2)^11 - 24*cos(c/2 + (d*x)/2)^11*sin(c/2 + (d*x)/2) + 15*cos(c/2 + (d*x)/2)^2*sin(c/2 + (d*x)/2)^10 - 120*cos(c/2 + (d*x)/2)^3 *sin(c/2 + (d*x)/2)^9 - 255*cos(c/2 + (d*x)/2)^4*sin(c/2 + (d*x)/2)^8 + 24 0*cos(c/2 + (d*x)/2)^5*sin(c/2 + (d*x)/2)^7 - 240*cos(c/2 + (d*x)/2)^7*sin (c/2 + (d*x)/2)^5 + 255*cos(c/2 + (d*x)/2)^8*sin(c/2 + (d*x)/2)^4 + 120*co s(c/2 + (d*x)/2)^9*sin(c/2 + (d*x)/2)^3 - 15*cos(c/2 + (d*x)/2)^10*sin(c/2 + (d*x)/2)^2 + 840*log(sin(c/2 + (d*x)/2)/cos(c/2 + (d*x)/2))*cos(c/2 + ( d*x)/2)^6*sin(c/2 + (d*x)/2)^6))/(1920*d*cos(c/2 + (d*x)/2)^6*sin(c/2 + (d *x)/2)^6)
Time = 0.16 (sec) , antiderivative size = 123, normalized size of antiderivative = 0.93 \[ \int \cot ^4(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x))^2 \, dx=\frac {a^{2} \left (-96 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{5}+135 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{4}+192 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{3}+10 \cos \left (d x +c \right ) \sin \left (d x +c \right )^{2}-96 \cos \left (d x +c \right ) \sin \left (d x +c \right )-40 \cos \left (d x +c \right )+105 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \sin \left (d x +c \right )^{6}\right )}{240 \sin \left (d x +c \right )^{6} d} \] Input:
int(cot(d*x+c)^4*csc(d*x+c)^3*(a+a*sin(d*x+c))^2,x)
Output:
(a**2*( - 96*cos(c + d*x)*sin(c + d*x)**5 + 135*cos(c + d*x)*sin(c + d*x)* *4 + 192*cos(c + d*x)*sin(c + d*x)**3 + 10*cos(c + d*x)*sin(c + d*x)**2 - 96*cos(c + d*x)*sin(c + d*x) - 40*cos(c + d*x) + 105*log(tan((c + d*x)/2)) *sin(c + d*x)**6))/(240*sin(c + d*x)**6*d)