Integrand size = 11, antiderivative size = 174 \[ \int \arctan (c+d \coth (a+b x)) \, dx=x \arctan (c+d \coth (a+b x))+\frac {1}{2} i x \log \left (1-\frac {(i-c-d) e^{2 a+2 b x}}{i-c+d}\right )-\frac {1}{2} i x \log \left (1-\frac {(i+c+d) e^{2 a+2 b x}}{i+c-d}\right )+\frac {i \operatorname {PolyLog}\left (2,\frac {(i-c-d) e^{2 a+2 b x}}{i-c+d}\right )}{4 b}-\frac {i \operatorname {PolyLog}\left (2,\frac {(i+c+d) e^{2 a+2 b x}}{i+c-d}\right )}{4 b} \] Output:
x*arctan(c+d*coth(b*x+a))+1/2*I*x*ln(1-(I-c-d)*exp(2*b*x+2*a)/(I-c+d))-1/2 *I*x*ln(1-(I+c+d)*exp(2*b*x+2*a)/(I+c-d))+1/4*I*polylog(2,(I-c-d)*exp(2*b* x+2*a)/(I-c+d))/b-1/4*I*polylog(2,(I+c+d)*exp(2*b*x+2*a)/(I+c-d))/b
Time = 1.92 (sec) , antiderivative size = 287, normalized size of antiderivative = 1.65 \[ \int \arctan (c+d \coth (a+b x)) \, dx=x \arctan (c+d \coth (a+b x))+\frac {4 a \sqrt {-d^2} \arctan \left (\frac {1+c^2-d^2-\left (1+c^2+2 c d+d^2\right ) e^{2 (a+b x)}}{2 d}\right )+2 d (a+b x) \log \left (1-\frac {\left (1+(c+d)^2\right ) e^{2 (a+b x)}}{1+c^2-d^2+2 \sqrt {-d^2}}\right )-2 d (a+b x) \log \left (1+\frac {\left (1+(c+d)^2\right ) e^{2 (a+b x)}}{-1-c^2+d^2+2 \sqrt {-d^2}}\right )+d \operatorname {PolyLog}\left (2,\frac {\left (1+c^2+2 c d+d^2\right ) e^{2 (a+b x)}}{1+c^2-d^2+2 \sqrt {-d^2}}\right )-d \operatorname {PolyLog}\left (2,-\frac {\left (1+c^2+2 c d+d^2\right ) e^{2 (a+b x)}}{-1-c^2+d^2+2 \sqrt {-d^2}}\right )}{4 b \sqrt {-d^2}} \] Input:
Integrate[ArcTan[c + d*Coth[a + b*x]],x]
Output:
x*ArcTan[c + d*Coth[a + b*x]] + (4*a*Sqrt[-d^2]*ArcTan[(1 + c^2 - d^2 - (1 + c^2 + 2*c*d + d^2)*E^(2*(a + b*x)))/(2*d)] + 2*d*(a + b*x)*Log[1 - ((1 + (c + d)^2)*E^(2*(a + b*x)))/(1 + c^2 - d^2 + 2*Sqrt[-d^2])] - 2*d*(a + b *x)*Log[1 + ((1 + (c + d)^2)*E^(2*(a + b*x)))/(-1 - c^2 + d^2 + 2*Sqrt[-d^ 2])] + d*PolyLog[2, ((1 + c^2 + 2*c*d + d^2)*E^(2*(a + b*x)))/(1 + c^2 - d ^2 + 2*Sqrt[-d^2])] - d*PolyLog[2, -(((1 + c^2 + 2*c*d + d^2)*E^(2*(a + b* x)))/(-1 - c^2 + d^2 + 2*Sqrt[-d^2]))])/(4*b*Sqrt[-d^2])
Time = 0.69 (sec) , antiderivative size = 237, normalized size of antiderivative = 1.36, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.364, Rules used = {5716, 2620, 2715, 2838}
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 \arctan (d \coth (a+b x)+c) \, dx\) |
\(\Big \downarrow \) 5716 |
\(\displaystyle b (1+i (c+d)) \int \frac {e^{2 a+2 b x} x}{-c-(-c-d+i) e^{2 a+2 b x}+d+i}dx-b (1-i (c+d)) \int \frac {e^{2 a+2 b x} x}{c-(c+d+i) e^{2 a+2 b x}-d+i}dx+x \arctan (d \coth (a+b x)+c)\) |
\(\Big \downarrow \) 2620 |
\(\displaystyle b (1+i (c+d)) \left (\frac {\int \log \left (1-\frac {(-c-d+i) e^{2 a+2 b x}}{-c+d+i}\right )dx}{2 b (-c-d+i)}-\frac {x \log \left (1-\frac {(-c-d+i) e^{2 a+2 b x}}{-c+d+i}\right )}{2 b (-c-d+i)}\right )-b (1-i (c+d)) \left (\frac {\int \log \left (1-\frac {(c+d+i) e^{2 a+2 b x}}{c-d+i}\right )dx}{2 b (c+d+i)}-\frac {x \log \left (1-\frac {(c+d+i) e^{2 a+2 b x}}{c-d+i}\right )}{2 b (c+d+i)}\right )+x \arctan (d \coth (a+b x)+c)\) |
\(\Big \downarrow \) 2715 |
\(\displaystyle b (1+i (c+d)) \left (\frac {\int e^{-2 a-2 b x} \log \left (1-\frac {(-c-d+i) e^{2 a+2 b x}}{-c+d+i}\right )de^{2 a+2 b x}}{4 b^2 (-c-d+i)}-\frac {x \log \left (1-\frac {(-c-d+i) e^{2 a+2 b x}}{-c+d+i}\right )}{2 b (-c-d+i)}\right )-b (1-i (c+d)) \left (\frac {\int e^{-2 a-2 b x} \log \left (1-\frac {(c+d+i) e^{2 a+2 b x}}{c-d+i}\right )de^{2 a+2 b x}}{4 b^2 (c+d+i)}-\frac {x \log \left (1-\frac {(c+d+i) e^{2 a+2 b x}}{c-d+i}\right )}{2 b (c+d+i)}\right )+x \arctan (d \coth (a+b x)+c)\) |
\(\Big \downarrow \) 2838 |
\(\displaystyle x \arctan (d \coth (a+b x)+c)+b (1+i (c+d)) \left (-\frac {\operatorname {PolyLog}\left (2,\frac {(-c-d+i) e^{2 a+2 b x}}{-c+d+i}\right )}{4 b^2 (-c-d+i)}-\frac {x \log \left (1-\frac {(-c-d+i) e^{2 a+2 b x}}{-c+d+i}\right )}{2 b (-c-d+i)}\right )-b (1-i (c+d)) \left (-\frac {\operatorname {PolyLog}\left (2,\frac {(c+d+i) e^{2 a+2 b x}}{c-d+i}\right )}{4 b^2 (c+d+i)}-\frac {x \log \left (1-\frac {(c+d+i) e^{2 a+2 b x}}{c-d+i}\right )}{2 b (c+d+i)}\right )\) |
Input:
Int[ArcTan[c + d*Coth[a + b*x]],x]
Output:
x*ArcTan[c + d*Coth[a + b*x]] + b*(1 + I*(c + d))*(-1/2*(x*Log[1 - ((I - c - d)*E^(2*a + 2*b*x))/(I - c + d)])/(b*(I - c - d)) - PolyLog[2, ((I - c - d)*E^(2*a + 2*b*x))/(I - c + d)]/(4*b^2*(I - c - d))) - b*(1 - I*(c + d) )*(-1/2*(x*Log[1 - ((I + c + d)*E^(2*a + 2*b*x))/(I + c - d)])/(b*(I + c + d)) - PolyLog[2, ((I + c + d)*E^(2*a + 2*b*x))/(I + c - d)]/(4*b^2*(I + c + d)))
Int[(((F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.))/ ((a_) + (b_.)*((F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)), x_Symbol] :> Simp [((c + d*x)^m/(b*f*g*n*Log[F]))*Log[1 + b*((F^(g*(e + f*x)))^n/a)], x] - Si mp[d*(m/(b*f*g*n*Log[F])) Int[(c + d*x)^(m - 1)*Log[1 + b*((F^(g*(e + f*x )))^n/a)], x], x] /; FreeQ[{F, a, b, c, d, e, f, g, n}, x] && IGtQ[m, 0]
Int[Log[(a_) + (b_.)*((F_)^((e_.)*((c_.) + (d_.)*(x_))))^(n_.)], x_Symbol] :> Simp[1/(d*e*n*Log[F]) Subst[Int[Log[a + b*x]/x, x], x, (F^(e*(c + d*x) ))^n], x] /; FreeQ[{F, a, b, c, d, e, n}, x] && GtQ[a, 0]
Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> Simp[-PolyLog[2 , (-c)*e*x^n]/n, x] /; FreeQ[{c, d, e, n}, x] && EqQ[c*d, 1]
Int[ArcTan[(c_.) + Coth[(a_.) + (b_.)*(x_)]*(d_.)], x_Symbol] :> Simp[x*Arc Tan[c + d*Coth[a + b*x]], x] + (-Simp[I*b*(I - c - d) Int[x*(E^(2*a + 2*b *x)/(I - c + d - (I - c - d)*E^(2*a + 2*b*x))), x], x] + Simp[I*b*(I + c + d) Int[x*(E^(2*a + 2*b*x)/(I + c - d - (I + c + d)*E^(2*a + 2*b*x))), x], x]) /; FreeQ[{a, b, c, d}, x] && NeQ[(c - d)^2, -1]
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 351 vs. \(2 (150 ) = 300\).
Time = 1.57 (sec) , antiderivative size = 352, normalized size of antiderivative = 2.02
method | result | size |
derivativedivides | \(\frac {\frac {\arctan \left (c +d \coth \left (b x +a \right )\right ) d \ln \left (-d \coth \left (b x +a \right )-d \right )}{2}-\frac {\arctan \left (c +d \coth \left (b x +a \right )\right ) d \ln \left (-d \coth \left (b x +a \right )+d \right )}{2}+\frac {d^{2} \left (\frac {\frac {i \ln \left (-d \coth \left (b x +a \right )+d \right ) \ln \left (\frac {i+d \coth \left (b x +a \right )+c}{i+c +d}\right )}{2}-\frac {i \ln \left (-d \coth \left (b x +a \right )+d \right ) \ln \left (\frac {i-d \coth \left (b x +a \right )-c}{i-c -d}\right )}{2}+\frac {i \operatorname {dilog}\left (\frac {i+d \coth \left (b x +a \right )+c}{i+c +d}\right )}{2}-\frac {i \operatorname {dilog}\left (\frac {i-d \coth \left (b x +a \right )-c}{i-c -d}\right )}{2}}{d}-\frac {\frac {i \ln \left (-d \coth \left (b x +a \right )-d \right ) \ln \left (\frac {i+d \coth \left (b x +a \right )+c}{i+c -d}\right )}{2}-\frac {i \ln \left (-d \coth \left (b x +a \right )-d \right ) \ln \left (\frac {i-d \coth \left (b x +a \right )-c}{i-c +d}\right )}{2}+\frac {i \operatorname {dilog}\left (\frac {i+d \coth \left (b x +a \right )+c}{i+c -d}\right )}{2}-\frac {i \operatorname {dilog}\left (\frac {i-d \coth \left (b x +a \right )-c}{i-c +d}\right )}{2}}{d}\right )}{2}}{b d}\) | \(352\) |
default | \(\frac {\frac {\arctan \left (c +d \coth \left (b x +a \right )\right ) d \ln \left (-d \coth \left (b x +a \right )-d \right )}{2}-\frac {\arctan \left (c +d \coth \left (b x +a \right )\right ) d \ln \left (-d \coth \left (b x +a \right )+d \right )}{2}+\frac {d^{2} \left (\frac {\frac {i \ln \left (-d \coth \left (b x +a \right )+d \right ) \ln \left (\frac {i+d \coth \left (b x +a \right )+c}{i+c +d}\right )}{2}-\frac {i \ln \left (-d \coth \left (b x +a \right )+d \right ) \ln \left (\frac {i-d \coth \left (b x +a \right )-c}{i-c -d}\right )}{2}+\frac {i \operatorname {dilog}\left (\frac {i+d \coth \left (b x +a \right )+c}{i+c +d}\right )}{2}-\frac {i \operatorname {dilog}\left (\frac {i-d \coth \left (b x +a \right )-c}{i-c -d}\right )}{2}}{d}-\frac {\frac {i \ln \left (-d \coth \left (b x +a \right )-d \right ) \ln \left (\frac {i+d \coth \left (b x +a \right )+c}{i+c -d}\right )}{2}-\frac {i \ln \left (-d \coth \left (b x +a \right )-d \right ) \ln \left (\frac {i-d \coth \left (b x +a \right )-c}{i-c +d}\right )}{2}+\frac {i \operatorname {dilog}\left (\frac {i+d \coth \left (b x +a \right )+c}{i+c -d}\right )}{2}-\frac {i \operatorname {dilog}\left (\frac {i-d \coth \left (b x +a \right )-c}{i-c +d}\right )}{2}}{d}\right )}{2}}{b d}\) | \(352\) |
risch | \(\text {Expression too large to display}\) | \(4130\) |
Input:
int(arctan(c+d*coth(b*x+a)),x,method=_RETURNVERBOSE)
Output:
1/b/d*(1/2*arctan(c+d*coth(b*x+a))*d*ln(-d*coth(b*x+a)-d)-1/2*arctan(c+d*c oth(b*x+a))*d*ln(-d*coth(b*x+a)+d)+1/2*d^2*(1/d*(1/2*I*ln(-d*coth(b*x+a)+d )*ln((I+d*coth(b*x+a)+c)/(I+c+d))-1/2*I*ln(-d*coth(b*x+a)+d)*ln((I-d*coth( b*x+a)-c)/(I-c-d))+1/2*I*dilog((I+d*coth(b*x+a)+c)/(I+c+d))-1/2*I*dilog((I -d*coth(b*x+a)-c)/(I-c-d)))-1/d*(1/2*I*ln(-d*coth(b*x+a)-d)*ln((I+d*coth(b *x+a)+c)/(I+c-d))-1/2*I*ln(-d*coth(b*x+a)-d)*ln((I-d*coth(b*x+a)-c)/(I-c+d ))+1/2*I*dilog((I+d*coth(b*x+a)+c)/(I+c-d))-1/2*I*dilog((I-d*coth(b*x+a)-c )/(I-c+d)))))
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 813 vs. \(2 (128) = 256\).
Time = 0.22 (sec) , antiderivative size = 813, normalized size of antiderivative = 4.67 \[ \int \arctan (c+d \coth (a+b x)) \, dx =\text {Too large to display} \] Input:
integrate(arctan(c+d*coth(b*x+a)),x, algorithm="fricas")
Output:
1/2*(2*b*x*arctan((d*cosh(b*x + a) + c*sinh(b*x + a))/sinh(b*x + a)) - I*a *log(2*(c^2 + 2*c*d + d^2 + 1)*cosh(b*x + a) + 2*(c^2 + 2*c*d + d^2 + 1)*s inh(b*x + a) + 2*(c^2 - d^2 - 2*I*d + 1)*sqrt((c^2 - d^2 + 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))) - I*a*log(2*(c^2 + 2*c*d + d^2 + 1)*cosh(b*x + a) + 2*(c^2 + 2*c*d + d^2 + 1)*sinh(b*x + a) - 2*(c^2 - d^2 - 2*I*d + 1)*sqrt(( c^2 - d^2 + 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))) + I*a*log(2*(c^2 + 2*c*d + d^2 + 1)*cosh(b*x + a) + 2*(c^2 + 2*c*d + d^2 + 1)*sinh(b*x + a) + 2*(c^ 2 - d^2 + 2*I*d + 1)*sqrt((c^2 - d^2 - 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1)) ) + I*a*log(2*(c^2 + 2*c*d + d^2 + 1)*cosh(b*x + a) + 2*(c^2 + 2*c*d + d^2 + 1)*sinh(b*x + a) - 2*(c^2 - d^2 + 2*I*d + 1)*sqrt((c^2 - d^2 - 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))) + (I*b*x + I*a)*log(sqrt((c^2 - d^2 + 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))*(cosh(b*x + a) + sinh(b*x + a)) + 1) + (I*b*x + I*a)*log(-sqrt((c^2 - d^2 + 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))*(cosh(b *x + a) + sinh(b*x + a)) + 1) + (-I*b*x - I*a)*log(sqrt((c^2 - d^2 - 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))*(cosh(b*x + a) + sinh(b*x + a)) + 1) + (-I* b*x - I*a)*log(-sqrt((c^2 - d^2 - 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))*(cos h(b*x + a) + sinh(b*x + a)) + 1) + I*dilog(sqrt((c^2 - d^2 + 2*I*d + 1)/(c ^2 - 2*c*d + d^2 + 1))*(cosh(b*x + a) + sinh(b*x + a))) + I*dilog(-sqrt((c ^2 - d^2 + 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))*(cosh(b*x + a) + sinh(b*x + a))) - I*dilog(sqrt((c^2 - d^2 - 2*I*d + 1)/(c^2 - 2*c*d + d^2 + 1))*(...
\[ \int \arctan (c+d \coth (a+b x)) \, dx=\int \operatorname {atan}{\left (c + d \coth {\left (a + b x \right )} \right )}\, dx \] Input:
integrate(atan(c+d*coth(b*x+a)),x)
Output:
Integral(atan(c + d*coth(a + b*x)), x)
\[ \int \arctan (c+d \coth (a+b x)) \, dx=\int { \arctan \left (d \coth \left (b x + a\right ) + c\right ) \,d x } \] Input:
integrate(arctan(c+d*coth(b*x+a)),x, algorithm="maxima")
Output:
4*b*d*integrate(x*e^(2*b*x + 2*a)/(c^2 - 2*c*d + d^2 + (c^2*e^(4*a) + 2*c* d*e^(4*a) + d^2*e^(4*a) + e^(4*a))*e^(4*b*x) - 2*(c^2*e^(2*a) - d^2*e^(2*a ) + e^(2*a))*e^(2*b*x) + 1), x) + x*arctan2((c*e^(2*a) + d*e^(2*a))*e^(2*b *x) - c + d, e^(2*b*x + 2*a) - 1)
\[ \int \arctan (c+d \coth (a+b x)) \, dx=\int { \arctan \left (d \coth \left (b x + a\right ) + c\right ) \,d x } \] Input:
integrate(arctan(c+d*coth(b*x+a)),x, algorithm="giac")
Output:
integrate(arctan(d*coth(b*x + a) + c), x)
Timed out. \[ \int \arctan (c+d \coth (a+b x)) \, dx=\int \mathrm {atan}\left (c+d\,\mathrm {coth}\left (a+b\,x\right )\right ) \,d x \] Input:
int(atan(c + d*coth(a + b*x)),x)
Output:
int(atan(c + d*coth(a + b*x)), x)
\[ \int \arctan (c+d \coth (a+b x)) \, dx=\int \mathit {atan} \left (\coth \left (b x +a \right ) d +c \right )d x \] Input:
int(atan(c+d*coth(b*x+a)),x)
Output:
int(atan(coth(a + b*x)*d + c),x)