\(\int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx\) [36]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [A] (verified)
Fricas [B] (verification not implemented)
Sympy [B] (verification not implemented)
Maxima [A] (verification not implemented)
Giac [B] (verification not implemented)
Mupad [B] (verification not implemented)
Reduce [B] (verification not implemented)

Optimal result

Integrand size = 18, antiderivative size = 114 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=-\frac {a+b \text {arctanh}(c+d x)}{f (e+f x)}-\frac {b d \log (1-c-d x)}{2 f (d e+f-c f)}+\frac {b d \log (1+c+d x)}{2 f (d e-(1+c) f)}-\frac {b d \log (e+f x)}{(d e+f-c f) (d e-(1+c) f)} \] Output:

-(a+b*arctanh(d*x+c))/f/(f*x+e)-1/2*b*d*ln(-d*x-c+1)/f/(-c*f+d*e+f)+1/2*b* 
d*ln(d*x+c+1)/f/(d*e-(1+c)*f)-b*d*ln(f*x+e)/(-c*f+d*e+f)/(d*e-(1+c)*f)
 

Mathematica [A] (verified)

Time = 0.12 (sec) , antiderivative size = 125, normalized size of antiderivative = 1.10 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=\frac {1}{2} \left (-\frac {2 a}{f (e+f x)}-\frac {2 b \text {arctanh}(c+d x)}{f (e+f x)}+\frac {b d \log (1-c-d x)}{f (-d e+(-1+c) f)}-\frac {b d \log (1+c+d x)}{f (-d e+f+c f)}-\frac {2 b d \log (e+f x)}{d^2 e^2-2 c d e f+\left (-1+c^2\right ) f^2}\right ) \] Input:

Integrate[(a + b*ArcTanh[c + d*x])/(e + f*x)^2,x]
 

Output:

((-2*a)/(f*(e + f*x)) - (2*b*ArcTanh[c + d*x])/(f*(e + f*x)) + (b*d*Log[1 
- c - d*x])/(f*(-(d*e) + (-1 + c)*f)) - (b*d*Log[1 + c + d*x])/(f*(-(d*e) 
+ f + c*f)) - (2*b*d*Log[e + f*x])/(d^2*e^2 - 2*c*d*e*f + (-1 + c^2)*f^2)) 
/2
 

Rubi [A] (verified)

Time = 0.42 (sec) , antiderivative size = 121, normalized size of antiderivative = 1.06, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {6659, 2081, 1141, 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 {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx\)

\(\Big \downarrow \) 6659

\(\displaystyle \frac {b d \int \frac {1}{(e+f x) \left (1-(c+d x)^2\right )}dx}{f}-\frac {a+b \text {arctanh}(c+d x)}{f (e+f x)}\)

\(\Big \downarrow \) 2081

\(\displaystyle \frac {b d \int \frac {1}{(e+f x) \left (-c^2-2 d x c-d^2 x^2+1\right )}dx}{f}-\frac {a+b \text {arctanh}(c+d x)}{f (e+f x)}\)

\(\Big \downarrow \) 1141

\(\displaystyle -\frac {b d^3 \int \left (\frac {f^2}{d^2 (d e-c f+f) (d e-(c+1) f) (e+f x)}-\frac {1}{2 d (d e-c f+f) (-c-d x+1)}-\frac {1}{2 d (d e-c f-f) (c+d x+1)}\right )dx}{f}-\frac {a+b \text {arctanh}(c+d x)}{f (e+f x)}\)

\(\Big \downarrow \) 2009

\(\displaystyle -\frac {a+b \text {arctanh}(c+d x)}{f (e+f x)}-\frac {b d^3 \left (\frac {\log (-c-d x+1)}{2 d^2 (-c f+d e+f)}-\frac {\log (c+d x+1)}{2 d^2 (d e-(c+1) f)}+\frac {f \log (e+f x)}{d^2 (-c f+d e+f) (d e-(c+1) f)}\right )}{f}\)

Input:

Int[(a + b*ArcTanh[c + d*x])/(e + f*x)^2,x]
 

Output:

-((a + b*ArcTanh[c + d*x])/(f*(e + f*x))) - (b*d^3*(Log[1 - c - d*x]/(2*d^ 
2*(d*e + f - c*f)) - Log[1 + c + d*x]/(2*d^2*(d*e - (1 + c)*f)) + (f*Log[e 
 + f*x])/(d^2*(d*e + f - c*f)*(d*e - (1 + c)*f))))/f
 

Defintions of rubi rules used

rule 1141
Int[((d_.) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_ 
Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Simp[1/c^p   Int[ExpandIntegrand[ 
(d + e*x)^m*(b/2 - q/2 + c*x)^p*(b/2 + q/2 + c*x)^p, x], x], x] /; EqQ[p, - 
1] ||  !FractionalPowerFactorQ[q]] /; FreeQ[{a, b, c, d, e}, x] && ILtQ[p, 
0] && IntegerQ[m] && NiceSqrtQ[b^2 - 4*a*c]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 2081
Int[(u_)^(m_.)*(v_)^(p_.), x_Symbol] :> Int[ExpandToSum[u, x]^m*ExpandToSum 
[v, x]^p, x] /; FreeQ[{m, p}, x] && LinearQ[u, x] && QuadraticQ[v, x] &&  ! 
(LinearMatchQ[u, x] && QuadraticMatchQ[v, x])
 

rule 6659
Int[((a_.) + ArcTanh[(c_) + (d_.)*(x_)]*(b_.))^(p_.)*((e_.) + (f_.)*(x_))^( 
m_), x_Symbol] :> Simp[(e + f*x)^(m + 1)*((a + b*ArcTanh[c + d*x])^p/(f*(m 
+ 1))), x] - Simp[b*d*(p/(f*(m + 1)))   Int[(e + f*x)^(m + 1)*((a + b*ArcTa 
nh[c + d*x])^(p - 1)/(1 - (c + d*x)^2)), x], x] /; FreeQ[{a, b, c, d, e, f} 
, x] && IGtQ[p, 0] && ILtQ[m, -1]
 
Maple [A] (verified)

Time = 0.76 (sec) , antiderivative size = 137, normalized size of antiderivative = 1.20

method result size
parts \(-\frac {a}{\left (f x +e \right ) f}-\frac {b d \,\operatorname {arctanh}\left (d x +c \right )}{\left (d f x +d e \right ) f}-\frac {b d \ln \left (f \left (d x +c \right )-c f +d e \right )}{\left (c f -d e +f \right ) \left (c f -d e -f \right )}+\frac {b d \ln \left (d x +c -1\right )}{f \left (2 c f -2 d e -2 f \right )}-\frac {b d \ln \left (d x +c +1\right )}{f \left (2 c f -2 d e +2 f \right )}\) \(137\)
derivativedivides \(\frac {\frac {a \,d^{2}}{\left (c f -d e -f \left (d x +c \right )\right ) f}+b \,d^{2} \left (\frac {\operatorname {arctanh}\left (d x +c \right )}{\left (c f -d e -f \left (d x +c \right )\right ) f}-\frac {-\frac {\ln \left (d x +c -1\right )}{2 c f -2 d e -2 f}+\frac {f \ln \left (c f -d e -f \left (d x +c \right )\right )}{\left (c f -d e -f \right ) \left (c f -d e +f \right )}+\frac {\ln \left (d x +c +1\right )}{2 c f -2 d e +2 f}}{f}\right )}{d}\) \(160\)
default \(\frac {\frac {a \,d^{2}}{\left (c f -d e -f \left (d x +c \right )\right ) f}+b \,d^{2} \left (\frac {\operatorname {arctanh}\left (d x +c \right )}{\left (c f -d e -f \left (d x +c \right )\right ) f}-\frac {-\frac {\ln \left (d x +c -1\right )}{2 c f -2 d e -2 f}+\frac {f \ln \left (c f -d e -f \left (d x +c \right )\right )}{\left (c f -d e -f \right ) \left (c f -d e +f \right )}+\frac {\ln \left (d x +c +1\right )}{2 c f -2 d e +2 f}}{f}\right )}{d}\) \(160\)
parallelrisch \(\frac {-a \,d^{4} e^{2}-a \,c^{2} d^{2} f^{2}+a \,d^{2} f^{2}+2 a c \,d^{3} e f +\operatorname {arctanh}\left (d x +c \right ) b \,d^{3} e f -x \,\operatorname {arctanh}\left (d x +c \right ) b c \,d^{3} f^{2}+x \,\operatorname {arctanh}\left (d x +c \right ) b \,d^{4} e f +\operatorname {arctanh}\left (d x +c \right ) b c \,d^{3} e f +\ln \left (d x +c -1\right ) x b \,d^{3} f^{2}-\ln \left (f x +e \right ) x b \,d^{3} f^{2}+\ln \left (d x +c -1\right ) b \,d^{3} e f -\ln \left (f x +e \right ) b \,d^{3} e f +x \,\operatorname {arctanh}\left (d x +c \right ) b \,d^{3} f^{2}-\operatorname {arctanh}\left (d x +c \right ) b \,c^{2} d^{2} f^{2}+\operatorname {arctanh}\left (d x +c \right ) b \,d^{2} f^{2}}{\left (c^{2} f^{2}-2 c d e f +d^{2} e^{2}-f^{2}\right ) \left (f x +e \right ) d^{2} f}\) \(247\)
risch \(-\frac {b \ln \left (d x +c +1\right )}{2 f \left (f x +e \right )}-\frac {\ln \left (d x +c +1\right ) b c d \,f^{2} x -\ln \left (d x +c +1\right ) b \,d^{2} e f x -\ln \left (-d x -c +1\right ) b c d \,f^{2} x +\ln \left (-d x -c +1\right ) b \,d^{2} e f x +\ln \left (d x +c +1\right ) b c d e f -\ln \left (d x +c +1\right ) b \,d^{2} e^{2}-\ln \left (d x +c +1\right ) b d \,f^{2} x +\ln \left (-d x -c +1\right ) b c d e f -\ln \left (-d x -c +1\right ) b d \,f^{2} x +2 \ln \left (-f x -e \right ) b d \,f^{2} x -b \,c^{2} f^{2} \ln \left (-d x -c +1\right )-\ln \left (d x +c +1\right ) b d e f -\ln \left (-d x -c +1\right ) b d e f +2 \ln \left (-f x -e \right ) b d e f +2 a \,c^{2} f^{2}-4 a c d e f +2 d^{2} e^{2} a +b \,f^{2} \ln \left (-d x -c +1\right )-2 a \,f^{2}}{2 \left (c^{2} f^{2}-2 c d e f +d^{2} e^{2}-f^{2}\right ) \left (f x +e \right ) f}\) \(335\)

Input:

int((a+b*arctanh(d*x+c))/(f*x+e)^2,x,method=_RETURNVERBOSE)
 

Output:

-a/(f*x+e)/f-b*d/(d*f*x+d*e)/f*arctanh(d*x+c)-b*d/(c*f-d*e+f)/(c*f-d*e-f)* 
ln(f*(d*x+c)-c*f+d*e)+b*d/f/(2*c*f-2*d*e-2*f)*ln(d*x+c-1)-b*d/f/(2*c*f-2*d 
*e+2*f)*ln(d*x+c+1)
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 263 vs. \(2 (110) = 220\).

Time = 0.20 (sec) , antiderivative size = 263, normalized size of antiderivative = 2.31 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=-\frac {2 \, a d^{2} e^{2} - 4 \, a c d e f + 2 \, {\left (a c^{2} - a\right )} f^{2} - {\left (b d^{2} e^{2} - {\left (b c - b\right )} d e f + {\left (b d^{2} e f - {\left (b c - b\right )} d f^{2}\right )} x\right )} \log \left (d x + c + 1\right ) + {\left (b d^{2} e^{2} - {\left (b c + b\right )} d e f + {\left (b d^{2} e f - {\left (b c + b\right )} d f^{2}\right )} x\right )} \log \left (d x + c - 1\right ) + 2 \, {\left (b d f^{2} x + b d e f\right )} \log \left (f x + e\right ) + {\left (b d^{2} e^{2} - 2 \, b c d e f + {\left (b c^{2} - b\right )} f^{2}\right )} \log \left (-\frac {d x + c + 1}{d x + c - 1}\right )}{2 \, {\left (d^{2} e^{3} f - 2 \, c d e^{2} f^{2} + {\left (c^{2} - 1\right )} e f^{3} + {\left (d^{2} e^{2} f^{2} - 2 \, c d e f^{3} + {\left (c^{2} - 1\right )} f^{4}\right )} x\right )}} \] Input:

integrate((a+b*arctanh(d*x+c))/(f*x+e)^2,x, algorithm="fricas")
 

Output:

-1/2*(2*a*d^2*e^2 - 4*a*c*d*e*f + 2*(a*c^2 - a)*f^2 - (b*d^2*e^2 - (b*c - 
b)*d*e*f + (b*d^2*e*f - (b*c - b)*d*f^2)*x)*log(d*x + c + 1) + (b*d^2*e^2 
- (b*c + b)*d*e*f + (b*d^2*e*f - (b*c + b)*d*f^2)*x)*log(d*x + c - 1) + 2* 
(b*d*f^2*x + b*d*e*f)*log(f*x + e) + (b*d^2*e^2 - 2*b*c*d*e*f + (b*c^2 - b 
)*f^2)*log(-(d*x + c + 1)/(d*x + c - 1)))/(d^2*e^3*f - 2*c*d*e^2*f^2 + (c^ 
2 - 1)*e*f^3 + (d^2*e^2*f^2 - 2*c*d*e*f^3 + (c^2 - 1)*f^4)*x)
 

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 1605 vs. \(2 (92) = 184\).

Time = 4.57 (sec) , antiderivative size = 1605, normalized size of antiderivative = 14.08 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=\text {Too large to display} \] Input:

integrate((a+b*atanh(d*x+c))/(f*x+e)**2,x)
 

Output:

Piecewise((-(a + b*atanh(c))/(e*f + f**2*x), Eq(d, 0)), ((a*x + b*c*atanh( 
c + d*x)/d + b*x*atanh(c + d*x) + b*log(c/d + x + 1/d)/d - b*atanh(c + d*x 
)/d)/e**2, Eq(f, 0)), (-2*a*f/(2*e*f**2 + 2*f**3*x) + b*d*e*atanh(d*e/f + 
d*x - 1)/(2*e*f**2 + 2*f**3*x) + b*d*f*x*atanh(d*e/f + d*x - 1)/(2*e*f**2 
+ 2*f**3*x) - 2*b*f*atanh(d*e/f + d*x - 1)/(2*e*f**2 + 2*f**3*x) - b*f/(2* 
e*f**2 + 2*f**3*x), Eq(c, (d*e - f)/f)), (-2*a*f/(2*e*f**2 + 2*f**3*x) - b 
*d*e*atanh(d*e/f + d*x + 1)/(2*e*f**2 + 2*f**3*x) - b*d*f*x*atanh(d*e/f + 
d*x + 1)/(2*e*f**2 + 2*f**3*x) - 2*b*f*atanh(d*e/f + d*x + 1)/(2*e*f**2 + 
2*f**3*x) + b*f/(2*e*f**2 + 2*f**3*x), Eq(c, (d*e + f)/f)), (-a*c**2*f**2/ 
(c**2*e*f**3 + c**2*f**4*x - 2*c*d*e**2*f**2 - 2*c*d*e*f**3*x + d**2*e**3* 
f + d**2*e**2*f**2*x - e*f**3 - f**4*x) + 2*a*c*d*e*f/(c**2*e*f**3 + c**2* 
f**4*x - 2*c*d*e**2*f**2 - 2*c*d*e*f**3*x + d**2*e**3*f + d**2*e**2*f**2*x 
 - e*f**3 - f**4*x) - a*d**2*e**2/(c**2*e*f**3 + c**2*f**4*x - 2*c*d*e**2* 
f**2 - 2*c*d*e*f**3*x + d**2*e**3*f + d**2*e**2*f**2*x - e*f**3 - f**4*x) 
+ a*f**2/(c**2*e*f**3 + c**2*f**4*x - 2*c*d*e**2*f**2 - 2*c*d*e*f**3*x + d 
**2*e**3*f + d**2*e**2*f**2*x - e*f**3 - f**4*x) - b*c**2*f**2*atanh(c + d 
*x)/(c**2*e*f**3 + c**2*f**4*x - 2*c*d*e**2*f**2 - 2*c*d*e*f**3*x + d**2*e 
**3*f + d**2*e**2*f**2*x - e*f**3 - f**4*x) + b*c*d*e*f*atanh(c + d*x)/(c* 
*2*e*f**3 + c**2*f**4*x - 2*c*d*e**2*f**2 - 2*c*d*e*f**3*x + d**2*e**3*f + 
 d**2*e**2*f**2*x - e*f**3 - f**4*x) - b*c*d*f**2*x*atanh(c + d*x)/(c**...
 

Maxima [A] (verification not implemented)

Time = 0.04 (sec) , antiderivative size = 121, normalized size of antiderivative = 1.06 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=\frac {1}{2} \, {\left (d {\left (\frac {\log \left (d x + c + 1\right )}{d e f - {\left (c + 1\right )} f^{2}} - \frac {\log \left (d x + c - 1\right )}{d e f - {\left (c - 1\right )} f^{2}} - \frac {2 \, \log \left (f x + e\right )}{d^{2} e^{2} - 2 \, c d e f + {\left (c^{2} - 1\right )} f^{2}}\right )} - \frac {2 \, \operatorname {artanh}\left (d x + c\right )}{f^{2} x + e f}\right )} b - \frac {a}{f^{2} x + e f} \] Input:

integrate((a+b*arctanh(d*x+c))/(f*x+e)^2,x, algorithm="maxima")
 

Output:

1/2*(d*(log(d*x + c + 1)/(d*e*f - (c + 1)*f^2) - log(d*x + c - 1)/(d*e*f - 
 (c - 1)*f^2) - 2*log(f*x + e)/(d^2*e^2 - 2*c*d*e*f + (c^2 - 1)*f^2)) - 2* 
arctanh(d*x + c)/(f^2*x + e*f))*b - a/(f^2*x + e*f)
 

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 474 vs. \(2 (110) = 220\).

Time = 0.13 (sec) , antiderivative size = 474, normalized size of antiderivative = 4.16 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=-\frac {1}{2} \, {\left ({\left (c + 1\right )} d - {\left (c - 1\right )} d\right )} {\left (\frac {b \log \left (-\frac {{\left (d x + c + 1\right )} d e}{d x + c - 1} + d e + \frac {{\left (d x + c + 1\right )} c f}{d x + c - 1} - c f - \frac {{\left (d x + c + 1\right )} f}{d x + c - 1} - f\right )}{d^{2} e^{2} - 2 \, c d e f + c^{2} f^{2} - f^{2}} - \frac {b \log \left (-\frac {d x + c + 1}{d x + c - 1}\right )}{\frac {{\left (d x + c + 1\right )} d^{2} e^{2}}{d x + c - 1} - d^{2} e^{2} - \frac {2 \, {\left (d x + c + 1\right )} c d e f}{d x + c - 1} + 2 \, c d e f + \frac {{\left (d x + c + 1\right )} c^{2} f^{2}}{d x + c - 1} - c^{2} f^{2} + \frac {2 \, {\left (d x + c + 1\right )} d e f}{d x + c - 1} - \frac {2 \, {\left (d x + c + 1\right )} c f^{2}}{d x + c - 1} + \frac {{\left (d x + c + 1\right )} f^{2}}{d x + c - 1} + f^{2}} - \frac {b \log \left (-\frac {d x + c + 1}{d x + c - 1}\right )}{d^{2} e^{2} - 2 \, c d e f + c^{2} f^{2} - f^{2}} - \frac {2 \, a}{\frac {{\left (d x + c + 1\right )} d^{2} e^{2}}{d x + c - 1} - d^{2} e^{2} - \frac {2 \, {\left (d x + c + 1\right )} c d e f}{d x + c - 1} + 2 \, c d e f + \frac {{\left (d x + c + 1\right )} c^{2} f^{2}}{d x + c - 1} - c^{2} f^{2} + \frac {2 \, {\left (d x + c + 1\right )} d e f}{d x + c - 1} - \frac {2 \, {\left (d x + c + 1\right )} c f^{2}}{d x + c - 1} + \frac {{\left (d x + c + 1\right )} f^{2}}{d x + c - 1} + f^{2}}\right )} \] Input:

integrate((a+b*arctanh(d*x+c))/(f*x+e)^2,x, algorithm="giac")
 

Output:

-1/2*((c + 1)*d - (c - 1)*d)*(b*log(-(d*x + c + 1)*d*e/(d*x + c - 1) + d*e 
 + (d*x + c + 1)*c*f/(d*x + c - 1) - c*f - (d*x + c + 1)*f/(d*x + c - 1) - 
 f)/(d^2*e^2 - 2*c*d*e*f + c^2*f^2 - f^2) - b*log(-(d*x + c + 1)/(d*x + c 
- 1))/((d*x + c + 1)*d^2*e^2/(d*x + c - 1) - d^2*e^2 - 2*(d*x + c + 1)*c*d 
*e*f/(d*x + c - 1) + 2*c*d*e*f + (d*x + c + 1)*c^2*f^2/(d*x + c - 1) - c^2 
*f^2 + 2*(d*x + c + 1)*d*e*f/(d*x + c - 1) - 2*(d*x + c + 1)*c*f^2/(d*x + 
c - 1) + (d*x + c + 1)*f^2/(d*x + c - 1) + f^2) - b*log(-(d*x + c + 1)/(d* 
x + c - 1))/(d^2*e^2 - 2*c*d*e*f + c^2*f^2 - f^2) - 2*a/((d*x + c + 1)*d^2 
*e^2/(d*x + c - 1) - d^2*e^2 - 2*(d*x + c + 1)*c*d*e*f/(d*x + c - 1) + 2*c 
*d*e*f + (d*x + c + 1)*c^2*f^2/(d*x + c - 1) - c^2*f^2 + 2*(d*x + c + 1)*d 
*e*f/(d*x + c - 1) - 2*(d*x + c + 1)*c*f^2/(d*x + c - 1) + (d*x + c + 1)*f 
^2/(d*x + c - 1) + f^2))
 

Mupad [B] (verification not implemented)

Time = 4.51 (sec) , antiderivative size = 170, normalized size of antiderivative = 1.49 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=\ln \left (e+f\,x\right )\,\left (\frac {b\,\left (c-1\right )}{2\,e\,\left (d\,e-f\,\left (c-1\right )\right )}-\frac {b\,\left (c+1\right )}{2\,e\,\left (d\,e-f\,\left (c+1\right )\right )}\right )-\frac {a}{x\,f^2+e\,f}+\frac {b\,\ln \left (1-d\,x-c\right )}{f\,\left (2\,e+2\,f\,x\right )}-\frac {b\,\ln \left (c+d\,x+1\right )}{2\,f\,\left (e+f\,x\right )}-\frac {b\,d\,\ln \left (c+d\,x-1\right )}{2\,f^2-2\,c\,f^2+2\,d\,e\,f}-\frac {b\,d\,\ln \left (c+d\,x+1\right )}{2\,c\,f^2+2\,f^2-2\,d\,e\,f} \] Input:

int((a + b*atanh(c + d*x))/(e + f*x)^2,x)
 

Output:

log(e + f*x)*((b*(c - 1))/(2*e*(d*e - f*(c - 1))) - (b*(c + 1))/(2*e*(d*e 
- f*(c + 1)))) - a/(e*f + f^2*x) + (b*log(1 - d*x - c))/(f*(2*e + 2*f*x)) 
- (b*log(c + d*x + 1))/(2*f*(e + f*x)) - (b*d*log(c + d*x - 1))/(2*f^2 - 2 
*c*f^2 + 2*d*e*f) - (b*d*log(c + d*x + 1))/(2*c*f^2 + 2*f^2 - 2*d*e*f)
 

Reduce [B] (verification not implemented)

Time = 0.16 (sec) , antiderivative size = 412, normalized size of antiderivative = 3.61 \[ \int \frac {a+b \text {arctanh}(c+d x)}{(e+f x)^2} \, dx=\frac {-\mathrm {log}\left (d x +c -1\right ) b c d e f x +\mathrm {log}\left (d x +c +1\right ) b c d e f x +\mathrm {log}\left (d x +c +1\right ) b d \,e^{2}+\mathrm {log}\left (d x +c +1\right ) b e f +\mathrm {log}\left (d x +c +1\right ) b \,f^{2} x -2 \mathit {atanh} \left (d x +c \right ) b \,f^{2} x -2 \,\mathrm {log}\left (f x +e \right ) b d \,e^{2}+2 a \,c^{2} f^{2} x +2 a \,d^{2} e^{2} x +\mathrm {log}\left (d x +c -1\right ) b d \,e^{2}-\mathrm {log}\left (d x +c -1\right ) b e f -\mathrm {log}\left (d x +c -1\right ) b \,f^{2} x +2 \mathit {atanh} \left (d x +c \right ) b \,c^{2} f^{2} x +2 \mathit {atanh} \left (d x +c \right ) b \,d^{2} e^{2} x -4 \mathit {atanh} \left (d x +c \right ) b c d e f x -\mathrm {log}\left (d x +c +1\right ) b \,c^{2} e f -\mathrm {log}\left (d x +c +1\right ) b \,c^{2} f^{2} x +\mathrm {log}\left (d x +c +1\right ) b c d \,e^{2}+\mathrm {log}\left (d x +c +1\right ) b d e f x -2 \,\mathrm {log}\left (f x +e \right ) b d e f x -4 a c d e f x +\mathrm {log}\left (d x +c -1\right ) b \,c^{2} e f +\mathrm {log}\left (d x +c -1\right ) b d e f x +\mathrm {log}\left (d x +c -1\right ) b \,c^{2} f^{2} x -\mathrm {log}\left (d x +c -1\right ) b c d \,e^{2}-2 a \,f^{2} x}{2 e \left (c^{2} f^{3} x -2 c d e \,f^{2} x +d^{2} e^{2} f x +c^{2} e \,f^{2}-2 c d \,e^{2} f +d^{2} e^{3}-f^{3} x -e \,f^{2}\right )} \] Input:

int((a+b*atanh(d*x+c))/(f*x+e)^2,x)
 

Output:

(2*atanh(c + d*x)*b*c**2*f**2*x - 4*atanh(c + d*x)*b*c*d*e*f*x + 2*atanh(c 
 + d*x)*b*d**2*e**2*x - 2*atanh(c + d*x)*b*f**2*x + log(c + d*x - 1)*b*c** 
2*e*f + log(c + d*x - 1)*b*c**2*f**2*x - log(c + d*x - 1)*b*c*d*e**2 - log 
(c + d*x - 1)*b*c*d*e*f*x + log(c + d*x - 1)*b*d*e**2 + log(c + d*x - 1)*b 
*d*e*f*x - log(c + d*x - 1)*b*e*f - log(c + d*x - 1)*b*f**2*x - log(c + d* 
x + 1)*b*c**2*e*f - log(c + d*x + 1)*b*c**2*f**2*x + log(c + d*x + 1)*b*c* 
d*e**2 + log(c + d*x + 1)*b*c*d*e*f*x + log(c + d*x + 1)*b*d*e**2 + log(c 
+ d*x + 1)*b*d*e*f*x + log(c + d*x + 1)*b*e*f + log(c + d*x + 1)*b*f**2*x 
- 2*log(e + f*x)*b*d*e**2 - 2*log(e + f*x)*b*d*e*f*x + 2*a*c**2*f**2*x - 4 
*a*c*d*e*f*x + 2*a*d**2*e**2*x - 2*a*f**2*x)/(2*e*(c**2*e*f**2 + c**2*f**3 
*x - 2*c*d*e**2*f - 2*c*d*e*f**2*x + d**2*e**3 + d**2*e**2*f*x - e*f**2 - 
f**3*x))