3.361 \(\int \frac{(a+b \tanh ^{-1}(c x^n)) (d+e \log (f x^m))}{x} \, dx\)

Optimal. Leaf size=136 \[ -\frac{b d \text{PolyLog}\left (2,-c x^n\right )}{2 n}+\frac{b d \text{PolyLog}\left (2,c x^n\right )}{2 n}-\frac{b e \log \left (f x^m\right ) \text{PolyLog}\left (2,-c x^n\right )}{2 n}+\frac{b e \log \left (f x^m\right ) \text{PolyLog}\left (2,c x^n\right )}{2 n}+\frac{b e m \text{PolyLog}\left (3,-c x^n\right )}{2 n^2}-\frac{b e m \text{PolyLog}\left (3,c x^n\right )}{2 n^2}+a d \log (x)+\frac{a e \log ^2\left (f x^m\right )}{2 m} \]

[Out]

a*d*Log[x] + (a*e*Log[f*x^m]^2)/(2*m) - (b*d*PolyLog[2, -(c*x^n)])/(2*n) - (b*e*Log[f*x^m]*PolyLog[2, -(c*x^n)
])/(2*n) + (b*d*PolyLog[2, c*x^n])/(2*n) + (b*e*Log[f*x^m]*PolyLog[2, c*x^n])/(2*n) + (b*e*m*PolyLog[3, -(c*x^
n)])/(2*n^2) - (b*e*m*PolyLog[3, c*x^n])/(2*n^2)

________________________________________________________________________________________

Rubi [A]  time = 0.537622, antiderivative size = 136, normalized size of antiderivative = 1., number of steps used = 11, number of rules used = 8, integrand size = 24, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.333, Rules used = {2301, 6742, 6095, 5912, 6071, 6069, 2374, 6589} \[ -\frac{b d \text{PolyLog}\left (2,-c x^n\right )}{2 n}+\frac{b d \text{PolyLog}\left (2,c x^n\right )}{2 n}-\frac{b e \log \left (f x^m\right ) \text{PolyLog}\left (2,-c x^n\right )}{2 n}+\frac{b e \log \left (f x^m\right ) \text{PolyLog}\left (2,c x^n\right )}{2 n}+\frac{b e m \text{PolyLog}\left (3,-c x^n\right )}{2 n^2}-\frac{b e m \text{PolyLog}\left (3,c x^n\right )}{2 n^2}+a d \log (x)+\frac{a e \log ^2\left (f x^m\right )}{2 m} \]

Antiderivative was successfully verified.

[In]

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

[Out]

a*d*Log[x] + (a*e*Log[f*x^m]^2)/(2*m) - (b*d*PolyLog[2, -(c*x^n)])/(2*n) - (b*e*Log[f*x^m]*PolyLog[2, -(c*x^n)
])/(2*n) + (b*d*PolyLog[2, c*x^n])/(2*n) + (b*e*Log[f*x^m]*PolyLog[2, c*x^n])/(2*n) + (b*e*m*PolyLog[3, -(c*x^
n)])/(2*n^2) - (b*e*m*PolyLog[3, c*x^n])/(2*n^2)

Rule 2301

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))/(x_), x_Symbol] :> Simp[(a + b*Log[c*x^n])^2/(2*b*n), x] /; FreeQ[{a
, b, c, n}, x]

Rule 6742

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rule 6095

Int[((a_.) + ArcTanh[(c_.)*(x_)^(n_)]*(b_.))^(p_.)/(x_), x_Symbol] :> Dist[1/n, Subst[Int[(a + b*ArcTanh[c*x])
^p/x, x], x, x^n], x] /; FreeQ[{a, b, c, n}, x] && IGtQ[p, 0]

Rule 5912

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))/(x_), x_Symbol] :> Simp[a*Log[x], x] + (-Simp[(b*PolyLog[2, -(c*x)])/2
, x] + Simp[(b*PolyLog[2, c*x])/2, x]) /; FreeQ[{a, b, c}, x]

Rule 6071

Int[(Log[(d_.)*(x_)^(m_.)]*(ArcTanh[(c_.)*(x_)^(n_.)]*(b_.) + (a_)))/(x_), x_Symbol] :> Dist[a, Int[Log[d*x^m]
/x, x], x] + Dist[b, Int[(Log[d*x^m]*ArcTanh[c*x^n])/x, x], x] /; FreeQ[{a, b, c, d, m, n}, x]

Rule 6069

Int[(ArcTanh[(c_.)*(x_)^(n_.)]*Log[(d_.)*(x_)^(m_.)])/(x_), x_Symbol] :> Dist[1/2, Int[(Log[d*x^m]*Log[1 + c*x
^n])/x, x], x] - Dist[1/2, Int[(Log[d*x^m]*Log[1 - c*x^n])/x, x], x] /; FreeQ[{c, d, m, n}, x]

Rule 2374

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :> -Sim
p[(PolyLog[2, -(d*f*x^m)]*(a + b*Log[c*x^n])^p)/m, x] + Dist[(b*n*p)/m, Int[(PolyLog[2, -(d*f*x^m)]*(a + b*Log
[c*x^n])^(p - 1))/x, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 0] && EqQ[d*e, 1]

Rule 6589

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rubi steps

\begin{align*} \int \frac{\left (a+b \tanh ^{-1}\left (c x^n\right )\right ) \left (d+e \log \left (f x^m\right )\right )}{x} \, dx &=\int \left (\frac{d \left (a+b \tanh ^{-1}\left (c x^n\right )\right )}{x}+\frac{e \left (a+b \tanh ^{-1}\left (c x^n\right )\right ) \log \left (f x^m\right )}{x}\right ) \, dx\\ &=d \int \frac{a+b \tanh ^{-1}\left (c x^n\right )}{x} \, dx+e \int \frac{\left (a+b \tanh ^{-1}\left (c x^n\right )\right ) \log \left (f x^m\right )}{x} \, dx\\ &=(a e) \int \frac{\log \left (f x^m\right )}{x} \, dx+(b e) \int \frac{\tanh ^{-1}\left (c x^n\right ) \log \left (f x^m\right )}{x} \, dx+\frac{d \operatorname{Subst}\left (\int \frac{a+b \tanh ^{-1}(c x)}{x} \, dx,x,x^n\right )}{n}\\ &=a d \log (x)+\frac{a e \log ^2\left (f x^m\right )}{2 m}-\frac{b d \text{Li}_2\left (-c x^n\right )}{2 n}+\frac{b d \text{Li}_2\left (c x^n\right )}{2 n}-\frac{1}{2} (b e) \int \frac{\log \left (f x^m\right ) \log \left (1-c x^n\right )}{x} \, dx+\frac{1}{2} (b e) \int \frac{\log \left (f x^m\right ) \log \left (1+c x^n\right )}{x} \, dx\\ &=a d \log (x)+\frac{a e \log ^2\left (f x^m\right )}{2 m}-\frac{b d \text{Li}_2\left (-c x^n\right )}{2 n}-\frac{b e \log \left (f x^m\right ) \text{Li}_2\left (-c x^n\right )}{2 n}+\frac{b d \text{Li}_2\left (c x^n\right )}{2 n}+\frac{b e \log \left (f x^m\right ) \text{Li}_2\left (c x^n\right )}{2 n}+\frac{(b e m) \int \frac{\text{Li}_2\left (-c x^n\right )}{x} \, dx}{2 n}-\frac{(b e m) \int \frac{\text{Li}_2\left (c x^n\right )}{x} \, dx}{2 n}\\ &=a d \log (x)+\frac{a e \log ^2\left (f x^m\right )}{2 m}-\frac{b d \text{Li}_2\left (-c x^n\right )}{2 n}-\frac{b e \log \left (f x^m\right ) \text{Li}_2\left (-c x^n\right )}{2 n}+\frac{b d \text{Li}_2\left (c x^n\right )}{2 n}+\frac{b e \log \left (f x^m\right ) \text{Li}_2\left (c x^n\right )}{2 n}+\frac{b e m \text{Li}_3\left (-c x^n\right )}{2 n^2}-\frac{b e m \text{Li}_3\left (c x^n\right )}{2 n^2}\\ \end{align*}

Mathematica [C]  time = 0.283437, size = 114, normalized size = 0.84 \[ \frac{b c x^n \left (d+e \log \left (f x^m\right )\right ) \text{HypergeometricPFQ}\left (\left \{\frac{1}{2},\frac{1}{2},1\right \},\left \{\frac{3}{2},\frac{3}{2}\right \},c^2 x^{2 n}\right )}{n}-\frac{b c e m x^n \text{HypergeometricPFQ}\left (\left \{\frac{1}{2},\frac{1}{2},\frac{1}{2},1\right \},\left \{\frac{3}{2},\frac{3}{2},\frac{3}{2}\right \},c^2 x^{2 n}\right )}{n^2}+\frac{1}{2} a \log (x) \left (2 d+2 e \log \left (f x^m\right )-e m \log (x)\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

-((b*c*e*m*x^n*HypergeometricPFQ[{1/2, 1/2, 1/2, 1}, {3/2, 3/2, 3/2}, c^2*x^(2*n)])/n^2) + (b*c*x^n*Hypergeome
tricPFQ[{1/2, 1/2, 1}, {3/2, 3/2}, c^2*x^(2*n)]*(d + e*Log[f*x^m]))/n + (a*Log[x]*(2*d - e*m*Log[x] + 2*e*Log[
f*x^m]))/2

________________________________________________________________________________________

Maple [C]  time = 0.285, size = 668, normalized size = 4.9 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*arctanh(c*x^n))*(d+e*ln(f*x^m))/x,x)

[Out]

1/4*I/n*dilog(1-c*x^n)*Pi*b*e*csgn(I*f)*csgn(I*f*x^m)^2+1/4*I/n*Pi*dilog(c*x^n+1)*b*e*csgn(I*f)*csgn(I*x^m)*cs
gn(I*f*x^m)-1/2*I/n*Pi*ln(x^n)*a*e*csgn(I*f)*csgn(I*x^m)*csgn(I*f*x^m)+1/2*I/n*Pi*ln(x^n)*a*e*csgn(I*x^m)*csgn
(I*f*x^m)^2+1/4*I/n*dilog(1-c*x^n)*Pi*b*e*csgn(I*x^m)*csgn(I*f*x^m)^2-1/4*I/n*Pi*dilog(c*x^n+1)*b*e*csgn(I*x^m
)*csgn(I*f*x^m)^2+1/2*I/n*Pi*ln(x^n)*a*e*csgn(I*f)*csgn(I*f*x^m)^2-1/2*I/n*Pi*ln(x^n)*a*e*csgn(I*f*x^m)^3+1/4*
I/n*Pi*dilog(c*x^n+1)*b*e*csgn(I*f*x^m)^3+1/2*e*b/n*ln(1-c*x^n)*ln(c*x^n)*m*ln(x)+1/2*e*b/n*m*ln(x)*polylog(2,
c*x^n)-1/2*e*b/n*ln(1-c*x^n)*ln(c*x^n)*ln(x^m)+1/2*e*b/n*dilog(c*x^n)*m*ln(x)+1/2*b*e*m*polylog(3,-c*x^n)/n^2-
1/2*b*e*m*polylog(3,c*x^n)/n^2-1/4*I/n*Pi*dilog(c*x^n+1)*b*e*csgn(I*f)*csgn(I*f*x^m)^2-1/2*e*b/n*dilog(c*x^n)*
ln(x^m)+1/2/n*dilog(1-c*x^n)*ln(f)*b*e-1/2/n*ln(f)*dilog(c*x^n+1)*b*e+1/n*ln(f)*ln(x^n)*a*e-1/2*e*b/n*dilog(c*
x^n+1)*ln(x^m)-1/4*I/n*dilog(1-c*x^n)*Pi*b*e*csgn(I*f*x^m)^3-1/2*e*b/n*m*ln(x)*polylog(2,-c*x^n)+1/2*e*b/n*dil
og(c*x^n+1)*m*ln(x)-1/2/n*dilog(c*x^n+1)*b*d+1/n*ln(x^n)*a*d+1/2*e*a/m*ln(x^m)^2-1/4*I/n*dilog(1-c*x^n)*Pi*b*e
*csgn(I*f)*csgn(I*x^m)*csgn(I*f*x^m)+1/2/n*dilog(1-c*x^n)*b*d

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \frac{a e \log \left (f x^{m}\right )^{2}}{2 \, m} + a d \log \left (x\right ) - \frac{1}{4} \,{\left (b e m \log \left (x\right )^{2} - 2 \, b e \log \left (x\right ) \log \left (x^{m}\right ) - 2 \,{\left (e \log \left (f\right ) + d\right )} b \log \left (x\right )\right )} \log \left (c x^{n} + 1\right ) + \frac{1}{4} \,{\left (b e m \log \left (x\right )^{2} - 2 \, b e \log \left (x\right ) \log \left (x^{m}\right ) - 2 \,{\left (e \log \left (f\right ) + d\right )} b \log \left (x\right )\right )} \log \left (-c x^{n} + 1\right ) + \int \frac{2 \, b c e n x^{n} \log \left (x\right ) \log \left (x^{m}\right ) -{\left (b c e m n \log \left (x\right )^{2} - 2 \,{\left (e n \log \left (f\right ) + d n\right )} b c \log \left (x\right )\right )} x^{n}}{2 \,{\left (c^{2} x x^{2 \, n} - x\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*a*e*log(f*x^m)^2/m + a*d*log(x) - 1/4*(b*e*m*log(x)^2 - 2*b*e*log(x)*log(x^m) - 2*(e*log(f) + d)*b*log(x))
*log(c*x^n + 1) + 1/4*(b*e*m*log(x)^2 - 2*b*e*log(x)*log(x^m) - 2*(e*log(f) + d)*b*log(x))*log(-c*x^n + 1) + i
ntegrate(1/2*(2*b*c*e*n*x^n*log(x)*log(x^m) - (b*c*e*m*n*log(x)^2 - 2*(e*n*log(f) + d*n)*b*c*log(x))*x^n)/(c^2
*x*x^(2*n) - x), x)

________________________________________________________________________________________

Fricas [C]  time = 1.75005, size = 980, normalized size = 7.21 \begin{align*} \frac{2 \, a e m n^{2} \log \left (x\right )^{2} - 2 \, b e m{\rm polylog}\left (3, c \cosh \left (n \log \left (x\right )\right ) + c \sinh \left (n \log \left (x\right )\right )\right ) + 2 \, b e m{\rm polylog}\left (3, -c \cosh \left (n \log \left (x\right )\right ) - c \sinh \left (n \log \left (x\right )\right )\right ) + 2 \,{\left (b e m n \log \left (x\right ) + b e n \log \left (f\right ) + b d n\right )}{\rm Li}_2\left (c \cosh \left (n \log \left (x\right )\right ) + c \sinh \left (n \log \left (x\right )\right )\right ) - 2 \,{\left (b e m n \log \left (x\right ) + b e n \log \left (f\right ) + b d n\right )}{\rm Li}_2\left (-c \cosh \left (n \log \left (x\right )\right ) - c \sinh \left (n \log \left (x\right )\right )\right ) -{\left (b e m n^{2} \log \left (x\right )^{2} + 2 \,{\left (b e n^{2} \log \left (f\right ) + b d n^{2}\right )} \log \left (x\right )\right )} \log \left (c \cosh \left (n \log \left (x\right )\right ) + c \sinh \left (n \log \left (x\right )\right ) + 1\right ) +{\left (b e m n^{2} \log \left (x\right )^{2} + 2 \,{\left (b e n^{2} \log \left (f\right ) + b d n^{2}\right )} \log \left (x\right )\right )} \log \left (-c \cosh \left (n \log \left (x\right )\right ) - c \sinh \left (n \log \left (x\right )\right ) + 1\right ) + 4 \,{\left (a e n^{2} \log \left (f\right ) + a d n^{2}\right )} \log \left (x\right ) +{\left (b e m n^{2} \log \left (x\right )^{2} + 2 \,{\left (b e n^{2} \log \left (f\right ) + b d n^{2}\right )} \log \left (x\right )\right )} \log \left (-\frac{c \cosh \left (n \log \left (x\right )\right ) + c \sinh \left (n \log \left (x\right )\right ) + 1}{c \cosh \left (n \log \left (x\right )\right ) + c \sinh \left (n \log \left (x\right )\right ) - 1}\right )}{4 \, n^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(2*a*e*m*n^2*log(x)^2 - 2*b*e*m*polylog(3, c*cosh(n*log(x)) + c*sinh(n*log(x))) + 2*b*e*m*polylog(3, -c*co
sh(n*log(x)) - c*sinh(n*log(x))) + 2*(b*e*m*n*log(x) + b*e*n*log(f) + b*d*n)*dilog(c*cosh(n*log(x)) + c*sinh(n
*log(x))) - 2*(b*e*m*n*log(x) + b*e*n*log(f) + b*d*n)*dilog(-c*cosh(n*log(x)) - c*sinh(n*log(x))) - (b*e*m*n^2
*log(x)^2 + 2*(b*e*n^2*log(f) + b*d*n^2)*log(x))*log(c*cosh(n*log(x)) + c*sinh(n*log(x)) + 1) + (b*e*m*n^2*log
(x)^2 + 2*(b*e*n^2*log(f) + b*d*n^2)*log(x))*log(-c*cosh(n*log(x)) - c*sinh(n*log(x)) + 1) + 4*(a*e*n^2*log(f)
 + a*d*n^2)*log(x) + (b*e*m*n^2*log(x)^2 + 2*(b*e*n^2*log(f) + b*d*n^2)*log(x))*log(-(c*cosh(n*log(x)) + c*sin
h(n*log(x)) + 1)/(c*cosh(n*log(x)) + c*sinh(n*log(x)) - 1)))/n^2

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*atanh(c*x**n))*(d+e*ln(f*x**m))/x,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (b \operatorname{artanh}\left (c x^{n}\right ) + a\right )}{\left (e \log \left (f x^{m}\right ) + d\right )}}{x}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

integrate((b*arctanh(c*x^n) + a)*(e*log(f*x^m) + d)/x, x)