Integrand size = 7, antiderivative size = 84 \[ \int \cos (x) \cot (5 x) \, dx=-\frac {1}{5} \text {arctanh}(\cos (x))-\frac {1}{5} \sqrt {\frac {1}{2} \left (3+\sqrt {5}\right )} \text {arctanh}\left (\sqrt {2 \left (3-\sqrt {5}\right )} \cos (x)\right )-\frac {1}{5} \sqrt {\frac {2}{3+\sqrt {5}}} \text {arctanh}\left (\sqrt {2 \left (3+\sqrt {5}\right )} \cos (x)\right )+\cos (x) \] Output:
-1/5*arctanh(cos(x))-1/5*(1/2+1/2*5^(1/2))*arctanh((5^(1/2)-1)*cos(x))-1/5 *2^(1/2)/(3+5^(1/2))^(1/2)*arctanh((5^(1/2)+1)*cos(x))+cos(x)
Time = 0.12 (sec) , antiderivative size = 133, normalized size of antiderivative = 1.58 \[ \int \cos (x) \cot (5 x) \, dx=\frac {1}{100} \left (100 \cos (x)-20 \log \left (\cos \left (\frac {x}{2}\right )\right )+\sqrt {5} \left (-5+\sqrt {5}\right ) \log \left (1-\sqrt {5}-4 \cos (x)\right )+\sqrt {5} \left (5+\sqrt {5}\right ) \log \left (1+\sqrt {5}-4 \cos (x)\right )-\sqrt {5} \left (-5+\sqrt {5}\right ) \log \left (1-\sqrt {5}+4 \cos (x)\right )-\sqrt {5} \left (5+\sqrt {5}\right ) \log \left (1+\sqrt {5}+4 \cos (x)\right )+20 \log \left (\sin \left (\frac {x}{2}\right )\right )\right ) \] Input:
Integrate[Cos[x]*Cot[5*x],x]
Output:
(100*Cos[x] - 20*Log[Cos[x/2]] + Sqrt[5]*(-5 + Sqrt[5])*Log[1 - Sqrt[5] - 4*Cos[x]] + Sqrt[5]*(5 + Sqrt[5])*Log[1 + Sqrt[5] - 4*Cos[x]] - Sqrt[5]*(- 5 + Sqrt[5])*Log[1 - Sqrt[5] + 4*Cos[x]] - Sqrt[5]*(5 + Sqrt[5])*Log[1 + S qrt[5] + 4*Cos[x]] + 20*Log[Sin[x/2]])/100
Time = 0.38 (sec) , antiderivative size = 110, normalized size of antiderivative = 1.31, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.571, Rules used = {3042, 4879, 2460, 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 \cos (x) \cot (5 x) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \cos (x) \cot (5 x)dx\) |
\(\Big \downarrow \) 4879 |
\(\displaystyle -\int \frac {\cos ^2(x) \left (16 \cos ^4(x)-20 \cos ^2(x)+5\right )}{-16 \cos ^6(x)+28 \cos ^4(x)-13 \cos ^2(x)+1}d\cos (x)\) |
\(\Big \downarrow \) 2460 |
\(\displaystyle -\int \left (\frac {2 (\cos (x)-1)}{5 \left (4 \cos ^2(x)+2 \cos (x)-1\right )}-\frac {1}{5 \left (\cos ^2(x)-1\right )}-\frac {2 (\cos (x)+1)}{5 \left (4 \cos ^2(x)-2 \cos (x)-1\right )}-1\right )d\cos (x)\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {1}{5} \text {arctanh}(\cos (x))+\cos (x)+\frac {1}{20} \left (1-\sqrt {5}\right ) \log \left (-4 \cos (x)-\sqrt {5}+1\right )+\frac {1}{20} \left (1+\sqrt {5}\right ) \log \left (-4 \cos (x)+\sqrt {5}+1\right )-\frac {1}{20} \left (1-\sqrt {5}\right ) \log \left (4 \cos (x)-\sqrt {5}+1\right )-\frac {1}{20} \left (1+\sqrt {5}\right ) \log \left (4 \cos (x)+\sqrt {5}+1\right )\) |
Input:
Int[Cos[x]*Cot[5*x],x]
Output:
-1/5*ArcTanh[Cos[x]] + Cos[x] + ((1 - Sqrt[5])*Log[1 - Sqrt[5] - 4*Cos[x]] )/20 + ((1 + Sqrt[5])*Log[1 + Sqrt[5] - 4*Cos[x]])/20 - ((1 - Sqrt[5])*Log [1 - Sqrt[5] + 4*Cos[x]])/20 - ((1 + Sqrt[5])*Log[1 + Sqrt[5] + 4*Cos[x]]) /20
Int[(u_.)*(Px_)^(p_), x_Symbol] :> With[{Qx = Factor[Px /. x -> Sqrt[x]]}, Int[ExpandIntegrand[u*(Qx /. x -> x^2)^p, x], x] /; !SumQ[NonfreeFactors[Q x, x]]] /; PolyQ[Px, x^2] && GtQ[Expon[Px, x], 2] && !BinomialQ[Px, x] && !TrinomialQ[Px, x] && ILtQ[p, 0] && RationalFunctionQ[u, x]
Int[u_, x_Symbol] :> With[{v = FunctionOfTrig[u, x]}, Simp[With[{d = FreeFa ctors[Cos[v], x]}, -d/Coefficient[v, x, 1] Subst[Int[SubstFor[1, Cos[v]/d , u/Sin[v], x], x], x, Cos[v]/d]], x] /; !FalseQ[v] && FunctionOfQ[Nonfree Factors[Cos[v], x], u/Sin[v], x]]
Result contains complex when optimal does not.
Time = 0.21 (sec) , antiderivative size = 224, normalized size of antiderivative = 2.67
method | result | size |
risch | \(\frac {{\mathrm e}^{i x}}{2}+\frac {{\mathrm e}^{-i x}}{2}-\frac {\ln \left ({\mathrm e}^{i x}+1\right )}{5}+\frac {\ln \left ({\mathrm e}^{i x}-1\right )}{5}-\frac {\ln \left ({\mathrm e}^{2 i x}+\frac {\left (\sqrt {5}+1\right ) {\mathrm e}^{i x}}{2}+1\right )}{20}-\frac {\ln \left ({\mathrm e}^{2 i x}+\frac {\left (\sqrt {5}+1\right ) {\mathrm e}^{i x}}{2}+1\right ) \sqrt {5}}{20}-\frac {\ln \left ({\mathrm e}^{2 i x}-\frac {\left (\sqrt {5}-1\right ) {\mathrm e}^{i x}}{2}+1\right )}{20}+\frac {\ln \left ({\mathrm e}^{2 i x}-\frac {\left (\sqrt {5}-1\right ) {\mathrm e}^{i x}}{2}+1\right ) \sqrt {5}}{20}+\frac {\ln \left ({\mathrm e}^{2 i x}+\frac {\left (\sqrt {5}-1\right ) {\mathrm e}^{i x}}{2}+1\right )}{20}-\frac {\ln \left ({\mathrm e}^{2 i x}+\frac {\left (\sqrt {5}-1\right ) {\mathrm e}^{i x}}{2}+1\right ) \sqrt {5}}{20}+\frac {\ln \left ({\mathrm e}^{2 i x}-\frac {\left (\sqrt {5}+1\right ) {\mathrm e}^{i x}}{2}+1\right )}{20}+\frac {\ln \left ({\mathrm e}^{2 i x}-\frac {\left (\sqrt {5}+1\right ) {\mathrm e}^{i x}}{2}+1\right ) \sqrt {5}}{20}\) | \(224\) |
Input:
int(cos(x)*cot(5*x),x,method=_RETURNVERBOSE)
Output:
1/2*exp(I*x)+1/2*exp(-I*x)-1/5*ln(exp(I*x)+1)+1/5*ln(exp(I*x)-1)-1/20*ln(e xp(2*I*x)+1/2*(5^(1/2)+1)*exp(I*x)+1)-1/20*ln(exp(2*I*x)+1/2*(5^(1/2)+1)*e xp(I*x)+1)*5^(1/2)-1/20*ln(exp(2*I*x)-1/2*(5^(1/2)-1)*exp(I*x)+1)+1/20*ln( exp(2*I*x)-1/2*(5^(1/2)-1)*exp(I*x)+1)*5^(1/2)+1/20*ln(exp(2*I*x)+1/2*(5^( 1/2)-1)*exp(I*x)+1)-1/20*ln(exp(2*I*x)+1/2*(5^(1/2)-1)*exp(I*x)+1)*5^(1/2) +1/20*ln(exp(2*I*x)-1/2*(5^(1/2)+1)*exp(I*x)+1)+1/20*ln(exp(2*I*x)-1/2*(5^ (1/2)+1)*exp(I*x)+1)*5^(1/2)
Leaf count of result is larger than twice the leaf count of optimal. 137 vs. \(2 (45) = 90\).
Time = 0.09 (sec) , antiderivative size = 137, normalized size of antiderivative = 1.63 \[ \int \cos (x) \cot (5 x) \, dx=\frac {1}{20} \, \sqrt {5} \log \left (-\frac {4 \, {\left (\sqrt {5} - 1\right )} \cos \left (x\right ) - 8 \, \cos \left (x\right )^{2} + \sqrt {5} - 3}{4 \, \cos \left (x\right )^{2} + 2 \, \cos \left (x\right ) - 1}\right ) + \frac {1}{20} \, \sqrt {5} \log \left (-\frac {4 \, {\left (\sqrt {5} + 1\right )} \cos \left (x\right ) - 8 \, \cos \left (x\right )^{2} - \sqrt {5} - 3}{4 \, \cos \left (x\right )^{2} - 2 \, \cos \left (x\right ) - 1}\right ) + \cos \left (x\right ) - \frac {1}{20} \, \log \left (4 \, \cos \left (x\right )^{2} + 2 \, \cos \left (x\right ) - 1\right ) + \frac {1}{20} \, \log \left (4 \, \cos \left (x\right )^{2} - 2 \, \cos \left (x\right ) - 1\right ) - \frac {1}{10} \, \log \left (\frac {1}{2} \, \cos \left (x\right ) + \frac {1}{2}\right ) + \frac {1}{10} \, \log \left (-\frac {1}{2} \, \cos \left (x\right ) + \frac {1}{2}\right ) \] Input:
integrate(cos(x)*cot(5*x),x, algorithm="fricas")
Output:
1/20*sqrt(5)*log(-(4*(sqrt(5) - 1)*cos(x) - 8*cos(x)^2 + sqrt(5) - 3)/(4*c os(x)^2 + 2*cos(x) - 1)) + 1/20*sqrt(5)*log(-(4*(sqrt(5) + 1)*cos(x) - 8*c os(x)^2 - sqrt(5) - 3)/(4*cos(x)^2 - 2*cos(x) - 1)) + cos(x) - 1/20*log(4* cos(x)^2 + 2*cos(x) - 1) + 1/20*log(4*cos(x)^2 - 2*cos(x) - 1) - 1/10*log( 1/2*cos(x) + 1/2) + 1/10*log(-1/2*cos(x) + 1/2)
\[ \int \cos (x) \cot (5 x) \, dx=\int \cos {\left (x \right )} \cot {\left (5 x \right )}\, dx \] Input:
integrate(cos(x)*cot(5*x),x)
Output:
Integral(cos(x)*cot(5*x), x)
\[ \int \cos (x) \cot (5 x) \, dx=\int { \cos \left (x\right ) \cot \left (5 \, x\right ) \,d x } \] Input:
integrate(cos(x)*cot(5*x),x, algorithm="maxima")
Output:
cos(x) + 1/10*integrate(-(cos(2*x)*sin(4*x) - cos(4*x)*sin(2*x) + cos(3/2* arctan2(sin(2*x), cos(2*x)))*sin(2*x) + cos(1/2*arctan2(sin(2*x), cos(2*x) ))*sin(2*x) - cos(2*x)*sin(3/2*arctan2(sin(2*x), cos(2*x))) - cos(2*x)*sin (1/2*arctan2(sin(2*x), cos(2*x))) - sin(2*x))/(2*(cos(2*x) + 1)*cos(4*x) + cos(4*x)^2 + cos(2*x)^2 - 2*(cos(4*x) + cos(2*x) - cos(1/2*arctan2(sin(2* x), cos(2*x))) + 1)*cos(3/2*arctan2(sin(2*x), cos(2*x))) + cos(3/2*arctan2 (sin(2*x), cos(2*x)))^2 - 2*(cos(4*x) + cos(2*x) + 1)*cos(1/2*arctan2(sin( 2*x), cos(2*x))) + cos(1/2*arctan2(sin(2*x), cos(2*x)))^2 + sin(4*x)^2 + 2 *sin(4*x)*sin(2*x) + sin(2*x)^2 - 2*(sin(4*x) + sin(2*x) - sin(1/2*arctan2 (sin(2*x), cos(2*x))))*sin(3/2*arctan2(sin(2*x), cos(2*x))) + sin(3/2*arct an2(sin(2*x), cos(2*x)))^2 - 2*(sin(4*x) + sin(2*x))*sin(1/2*arctan2(sin(2 *x), cos(2*x))) + sin(1/2*arctan2(sin(2*x), cos(2*x)))^2 + 2*cos(2*x) + 1) , x) + 1/10*integrate((cos(2*x)*sin(4*x) - cos(4*x)*sin(2*x) - cos(3/2*arc tan2(sin(2*x), cos(2*x)))*sin(2*x) - cos(1/2*arctan2(sin(2*x), cos(2*x)))* sin(2*x) + cos(2*x)*sin(3/2*arctan2(sin(2*x), cos(2*x))) + cos(2*x)*sin(1/ 2*arctan2(sin(2*x), cos(2*x))) - sin(2*x))/(2*(cos(2*x) + 1)*cos(4*x) + co s(4*x)^2 + cos(2*x)^2 + 2*(cos(4*x) + cos(2*x) + cos(1/2*arctan2(sin(2*x), cos(2*x))) + 1)*cos(3/2*arctan2(sin(2*x), cos(2*x))) + cos(3/2*arctan2(si n(2*x), cos(2*x)))^2 + 2*(cos(4*x) + cos(2*x) + 1)*cos(1/2*arctan2(sin(2*x ), cos(2*x))) + cos(1/2*arctan2(sin(2*x), cos(2*x)))^2 + sin(4*x)^2 + 2...
Leaf count of result is larger than twice the leaf count of optimal. 117 vs. \(2 (45) = 90\).
Time = 0.13 (sec) , antiderivative size = 117, normalized size of antiderivative = 1.39 \[ \int \cos (x) \cot (5 x) \, dx=\frac {1}{20} \, \sqrt {5} \log \left (\frac {{\left | -2 \, \sqrt {5} + 8 \, \cos \left (x\right ) + 2 \right |}}{{\left | 2 \, \sqrt {5} + 8 \, \cos \left (x\right ) + 2 \right |}}\right ) + \frac {1}{20} \, \sqrt {5} \log \left (\frac {{\left | -2 \, \sqrt {5} + 8 \, \cos \left (x\right ) - 2 \right |}}{{\left | 2 \, \sqrt {5} + 8 \, \cos \left (x\right ) - 2 \right |}}\right ) + \cos \left (x\right ) - \frac {1}{10} \, \log \left (\cos \left (x\right ) + 1\right ) + \frac {1}{10} \, \log \left (-\cos \left (x\right ) + 1\right ) - \frac {1}{20} \, \log \left ({\left | 4 \, \cos \left (x\right )^{2} + 2 \, \cos \left (x\right ) - 1 \right |}\right ) + \frac {1}{20} \, \log \left ({\left | 4 \, \cos \left (x\right )^{2} - 2 \, \cos \left (x\right ) - 1 \right |}\right ) \] Input:
integrate(cos(x)*cot(5*x),x, algorithm="giac")
Output:
1/20*sqrt(5)*log(abs(-2*sqrt(5) + 8*cos(x) + 2)/abs(2*sqrt(5) + 8*cos(x) + 2)) + 1/20*sqrt(5)*log(abs(-2*sqrt(5) + 8*cos(x) - 2)/abs(2*sqrt(5) + 8*c os(x) - 2)) + cos(x) - 1/10*log(cos(x) + 1) + 1/10*log(-cos(x) + 1) - 1/20 *log(abs(4*cos(x)^2 + 2*cos(x) - 1)) + 1/20*log(abs(4*cos(x)^2 - 2*cos(x) - 1))
Time = 17.32 (sec) , antiderivative size = 611, normalized size of antiderivative = 7.27 \[ \int \cos (x) \cot (5 x) \, dx=\text {Too large to display} \] Input:
int(cot(5*x)*cos(x),x)
Output:
(atan((tan(x/2)^2*4813499234516992i)/(1220703125*((213485644414976*5^(1/2) )/1220703125 - (2152646198689792*5^(1/2)*tan(x/2)^2)/1220703125 - (4959229 085483008*tan(x/2)^2)/1220703125 + 110872433262592/244140625)) - 954873235 37408i/(244140625*((213485644414976*5^(1/2))/1220703125 - (215264619868979 2*5^(1/2)*tan(x/2)^2)/1220703125 - (4959229085483008*tan(x/2)^2)/122070312 5 + 110872433262592/244140625)) - (5^(1/2)*247887795585024i)/(1220703125*( (213485644414976*5^(1/2))/1220703125 - (2152646198689792*5^(1/2)*tan(x/2)^ 2)/1220703125 - (4959229085483008*tan(x/2)^2)/1220703125 + 110872433262592 /244140625)) + (5^(1/2)*tan(x/2)^2*2217818569310208i)/(1220703125*((213485 644414976*5^(1/2))/1220703125 - (2152646198689792*5^(1/2)*tan(x/2)^2)/1220 703125 - (4959229085483008*tan(x/2)^2)/1220703125 + 110872433262592/244140 625)))*1i)/10 + (atan(95487323537408i/(244140625*((213485644414976*5^(1/2) )/1220703125 - (2152646198689792*5^(1/2)*tan(x/2)^2)/1220703125 + (4959229 085483008*tan(x/2)^2)/1220703125 - 110872433262592/244140625)) - (5^(1/2)* 247887795585024i)/(1220703125*((213485644414976*5^(1/2))/1220703125 - (215 2646198689792*5^(1/2)*tan(x/2)^2)/1220703125 + (4959229085483008*tan(x/2)^ 2)/1220703125 - 110872433262592/244140625)) - (tan(x/2)^2*4813499234516992 i)/(1220703125*((213485644414976*5^(1/2))/1220703125 - (2152646198689792*5 ^(1/2)*tan(x/2)^2)/1220703125 + (4959229085483008*tan(x/2)^2)/1220703125 - 110872433262592/244140625)) + (5^(1/2)*tan(x/2)^2*2217818569310208i)/(...
\[ \int \cos (x) \cot (5 x) \, dx=\int \cos \left (x \right ) \cot \left (5 x \right )d x \] Input:
int(cos(x)*cot(5*x),x)
Output:
int(cos(x)*cot(5*x),x)