Integrand size = 11, antiderivative size = 48 \[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=\frac {x \text {arctanh}(\tanh (a+b x))^{1+n}}{b (1+n)}-\frac {\text {arctanh}(\tanh (a+b x))^{2+n}}{b^2 (1+n) (2+n)} \] Output:
x*arctanh(tanh(b*x+a))^(1+n)/b/(1+n)-arctanh(tanh(b*x+a))^(2+n)/b^2/(1+n)/ (2+n)
Time = 0.03 (sec) , antiderivative size = 41, normalized size of antiderivative = 0.85 \[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=\frac {(b (2+n) x-\text {arctanh}(\tanh (a+b x))) \text {arctanh}(\tanh (a+b x))^{1+n}}{b^2 (1+n) (2+n)} \] Input:
Integrate[x*ArcTanh[Tanh[a + b*x]]^n,x]
Output:
((b*(2 + n)*x - ArcTanh[Tanh[a + b*x]])*ArcTanh[Tanh[a + b*x]]^(1 + n))/(b ^2*(1 + n)*(2 + n))
Time = 0.30 (sec) , antiderivative size = 48, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.273, Rules used = {2599, 2588, 15}
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 x \text {arctanh}(\tanh (a+b x))^n \, dx\) |
\(\Big \downarrow \) 2599 |
\(\displaystyle \frac {x \text {arctanh}(\tanh (a+b x))^{n+1}}{b (n+1)}-\frac {\int \text {arctanh}(\tanh (a+b x))^{n+1}dx}{b (n+1)}\) |
\(\Big \downarrow \) 2588 |
\(\displaystyle \frac {x \text {arctanh}(\tanh (a+b x))^{n+1}}{b (n+1)}-\frac {\int \text {arctanh}(\tanh (a+b x))^{n+1}d\text {arctanh}(\tanh (a+b x))}{b^2 (n+1)}\) |
\(\Big \downarrow \) 15 |
\(\displaystyle \frac {x \text {arctanh}(\tanh (a+b x))^{n+1}}{b (n+1)}-\frac {\text {arctanh}(\tanh (a+b x))^{n+2}}{b^2 (n+1) (n+2)}\) |
Input:
Int[x*ArcTanh[Tanh[a + b*x]]^n,x]
Output:
(x*ArcTanh[Tanh[a + b*x]]^(1 + n))/(b*(1 + n)) - ArcTanh[Tanh[a + b*x]]^(2 + n)/(b^2*(1 + n)*(2 + n))
Int[(a_.)*(x_)^(m_.), x_Symbol] :> Simp[a*(x^(m + 1)/(m + 1)), x] /; FreeQ[ {a, m}, x] && NeQ[m, -1]
Int[(u_)^(m_.), x_Symbol] :> With[{c = Simplify[D[u, x]]}, Simp[1/c Subst [Int[x^m, x], x, u], x]] /; FreeQ[m, x] && PiecewiseLinearQ[u, x]
Int[(u_)^(m_)*(v_)^(n_.), x_Symbol] :> With[{a = Simplify[D[u, x]], b = Sim plify[D[v, x]]}, Simp[u^(m + 1)*(v^n/(a*(m + 1))), x] - Simp[b*(n/(a*(m + 1 ))) Int[u^(m + 1)*v^(n - 1), x], x] /; NeQ[b*u - a*v, 0]] /; FreeQ[{m, n} , x] && PiecewiseLinearQ[u, v, x] && NeQ[m, -1] && ((LtQ[m, -1] && GtQ[n, 0 ] && !(ILtQ[m + n, -2] && (FractionQ[m] || GeQ[2*n + m + 1, 0]))) || (IGtQ [n, 0] && IGtQ[m, 0] && LeQ[n, m]) || (IGtQ[n, 0] && !IntegerQ[m]) || (ILt Q[m, 0] && !IntegerQ[n]))
Time = 0.50 (sec) , antiderivative size = 77, normalized size of antiderivative = 1.60
method | result | size |
parallelrisch | \(-\frac {-2 \operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )^{n} \operatorname {arctanh}\left (\tanh \left (b x +a \right )\right ) x b +\operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )^{n} \operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )^{2}-x \,\operatorname {arctanh}\left (\tanh \left (b x +a \right )\right ) \operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )^{n} b n}{b^{2} \left (n^{2}+3 n +2\right )}\) | \(77\) |
default | \(\frac {x^{2} {\mathrm e}^{n \ln \left (\operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )\right )}}{2+n}+\frac {n \left (\operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )-b x \right ) x \,{\mathrm e}^{n \ln \left (\operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )\right )}}{b \left (n^{2}+3 n +2\right )}-\frac {\left (\operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )-b x \right )^{2} {\mathrm e}^{n \ln \left (\operatorname {arctanh}\left (\tanh \left (b x +a \right )\right )\right )}}{b^{2} \left (n^{2}+3 n +2\right )}\) | \(101\) |
risch | \(\frac {\left (\frac {1}{2}\right )^{n} {\left (2 \ln \left ({\mathrm e}^{b x +a}\right )-\frac {i \pi \,\operatorname {csgn}\left (i {\mathrm e}^{2 b x +2 a}\right ) {\left (-\operatorname {csgn}\left (i {\mathrm e}^{2 b x +2 a}\right )+\operatorname {csgn}\left (i {\mathrm e}^{b x +a}\right )\right )}^{2}}{2}-\frac {i \pi \,\operatorname {csgn}\left (\frac {i {\mathrm e}^{2 b x +2 a}}{{\mathrm e}^{2 b x +2 a}+1}\right ) \left (-\operatorname {csgn}\left (\frac {i {\mathrm e}^{2 b x +2 a}}{{\mathrm e}^{2 b x +2 a}+1}\right )+\operatorname {csgn}\left (i {\mathrm e}^{2 b x +2 a}\right )\right ) \left (-\operatorname {csgn}\left (\frac {i {\mathrm e}^{2 b x +2 a}}{{\mathrm e}^{2 b x +2 a}+1}\right )+\operatorname {csgn}\left (\frac {i}{{\mathrm e}^{2 b x +2 a}+1}\right )\right )}{2}\right )}^{1+n} x}{2 b \left (1+n \right )}-\frac {\left (\frac {1}{2}\right )^{n} {\left (2 \ln \left ({\mathrm e}^{b x +a}\right )-\frac {i \pi \,\operatorname {csgn}\left (i {\mathrm e}^{2 b x +2 a}\right ) {\left (-\operatorname {csgn}\left (i {\mathrm e}^{2 b x +2 a}\right )+\operatorname {csgn}\left (i {\mathrm e}^{b x +a}\right )\right )}^{2}}{2}-\frac {i \pi \,\operatorname {csgn}\left (\frac {i {\mathrm e}^{2 b x +2 a}}{{\mathrm e}^{2 b x +2 a}+1}\right ) \left (-\operatorname {csgn}\left (\frac {i {\mathrm e}^{2 b x +2 a}}{{\mathrm e}^{2 b x +2 a}+1}\right )+\operatorname {csgn}\left (i {\mathrm e}^{2 b x +2 a}\right )\right ) \left (-\operatorname {csgn}\left (\frac {i {\mathrm e}^{2 b x +2 a}}{{\mathrm e}^{2 b x +2 a}+1}\right )+\operatorname {csgn}\left (\frac {i}{{\mathrm e}^{2 b x +2 a}+1}\right )\right )}{2}\right )}^{2+n}}{4 b^{2} \left (1+n \right ) \left (2+n \right )}\) | \(388\) |
Input:
int(x*arctanh(tanh(b*x+a))^n,x,method=_RETURNVERBOSE)
Output:
-(-2*arctanh(tanh(b*x+a))^n*arctanh(tanh(b*x+a))*x*b+arctanh(tanh(b*x+a))^ n*arctanh(tanh(b*x+a))^2-x*arctanh(tanh(b*x+a))*arctanh(tanh(b*x+a))^n*b*n )/b^2/(n^2+3*n+2)
Time = 0.08 (sec) , antiderivative size = 91, normalized size of antiderivative = 1.90 \[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=\frac {{\left (a b n x + {\left (b^{2} n + b^{2}\right )} x^{2} - a^{2}\right )} \cosh \left (n \log \left (b x + a\right )\right ) + {\left (a b n x + {\left (b^{2} n + b^{2}\right )} x^{2} - a^{2}\right )} \sinh \left (n \log \left (b x + a\right )\right )}{b^{2} n^{2} + 3 \, b^{2} n + 2 \, b^{2}} \] Input:
integrate(x*arctanh(tanh(b*x+a))^n,x, algorithm="fricas")
Output:
((a*b*n*x + (b^2*n + b^2)*x^2 - a^2)*cosh(n*log(b*x + a)) + (a*b*n*x + (b^ 2*n + b^2)*x^2 - a^2)*sinh(n*log(b*x + a)))/(b^2*n^2 + 3*b^2*n + 2*b^2)
\[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=\begin {cases} \frac {x^{2} \operatorname {atanh}^{n}{\left (\tanh {\left (a \right )} \right )}}{2} & \text {for}\: b = 0 \\- \frac {x}{b \operatorname {atanh}{\left (\tanh {\left (a + b x \right )} \right )}} + \frac {\log {\left (\operatorname {atanh}{\left (\tanh {\left (a + b x \right )} \right )} \right )}}{b^{2}} & \text {for}\: n = -2 \\\int \frac {x}{\operatorname {atanh}{\left (\tanh {\left (a + b x \right )} \right )}}\, dx & \text {for}\: n = -1 \\\frac {b n x \operatorname {atanh}{\left (\tanh {\left (a + b x \right )} \right )} \operatorname {atanh}^{n}{\left (\tanh {\left (a + b x \right )} \right )}}{b^{2} n^{2} + 3 b^{2} n + 2 b^{2}} + \frac {2 b x \operatorname {atanh}{\left (\tanh {\left (a + b x \right )} \right )} \operatorname {atanh}^{n}{\left (\tanh {\left (a + b x \right )} \right )}}{b^{2} n^{2} + 3 b^{2} n + 2 b^{2}} - \frac {\operatorname {atanh}^{2}{\left (\tanh {\left (a + b x \right )} \right )} \operatorname {atanh}^{n}{\left (\tanh {\left (a + b x \right )} \right )}}{b^{2} n^{2} + 3 b^{2} n + 2 b^{2}} & \text {otherwise} \end {cases} \] Input:
integrate(x*atanh(tanh(b*x+a))**n,x)
Output:
Piecewise((x**2*atanh(tanh(a))**n/2, Eq(b, 0)), (-x/(b*atanh(tanh(a + b*x) )) + log(atanh(tanh(a + b*x)))/b**2, Eq(n, -2)), (Integral(x/atanh(tanh(a + b*x)), x), Eq(n, -1)), (b*n*x*atanh(tanh(a + b*x))*atanh(tanh(a + b*x))* *n/(b**2*n**2 + 3*b**2*n + 2*b**2) + 2*b*x*atanh(tanh(a + b*x))*atanh(tanh (a + b*x))**n/(b**2*n**2 + 3*b**2*n + 2*b**2) - atanh(tanh(a + b*x))**2*at anh(tanh(a + b*x))**n/(b**2*n**2 + 3*b**2*n + 2*b**2), True))
Time = 0.19 (sec) , antiderivative size = 42, normalized size of antiderivative = 0.88 \[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=\frac {{\left (b^{2} {\left (n + 1\right )} x^{2} + a b n x - a^{2}\right )} {\left (b x + a\right )}^{n}}{{\left (n^{2} + 3 \, n + 2\right )} b^{2}} \] Input:
integrate(x*arctanh(tanh(b*x+a))^n,x, algorithm="maxima")
Output:
(b^2*(n + 1)*x^2 + a*b*n*x - a^2)*(b*x + a)^n/((n^2 + 3*n + 2)*b^2)
Time = 0.11 (sec) , antiderivative size = 76, normalized size of antiderivative = 1.58 \[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=\frac {{\left (b x + a\right )}^{n} b^{2} n x^{2} + {\left (b x + a\right )}^{n} a b n x + {\left (b x + a\right )}^{n} b^{2} x^{2} - {\left (b x + a\right )}^{n} a^{2}}{b^{2} n^{2} + 3 \, b^{2} n + 2 \, b^{2}} \] Input:
integrate(x*arctanh(tanh(b*x+a))^n,x, algorithm="giac")
Output:
((b*x + a)^n*b^2*n*x^2 + (b*x + a)^n*a*b*n*x + (b*x + a)^n*b^2*x^2 - (b*x + a)^n*a^2)/(b^2*n^2 + 3*b^2*n + 2*b^2)
Time = 3.43 (sec) , antiderivative size = 205, normalized size of antiderivative = 4.27 \[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=-{\left (\frac {\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )}{2}-\frac {\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )}{2}\right )}^n\,\left (\frac {{\left (\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )}^2}{4\,b^2\,\left (n^2+3\,n+2\right )}-\frac {x^2\,\left (n+1\right )}{n^2+3\,n+2}+\frac {n\,x\,\left (\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )}{2\,b\,\left (n^2+3\,n+2\right )}\right ) \] Input:
int(x*atanh(tanh(a + b*x))^n,x)
Output:
-(log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1))/2 - log(2/(exp(2* a)*exp(2*b*x) + 1))/2)^n*((log(2/(exp(2*a)*exp(2*b*x) + 1)) - log((2*exp(2 *a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + 2*b*x)^2/(4*b^2*(3*n + n^2 + 2)) - (x^2*(n + 1))/(3*n + n^2 + 2) + (n*x*(log(2/(exp(2*a)*exp(2*b*x) + 1 )) - log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + 2*b*x))/(2*b *(3*n + n^2 + 2)))
Time = 0.17 (sec) , antiderivative size = 48, normalized size of antiderivative = 1.00 \[ \int x \text {arctanh}(\tanh (a+b x))^n \, dx=\frac {\mathit {atanh} \left (\tanh \left (b x +a \right )\right )^{n} \mathit {atanh} \left (\tanh \left (b x +a \right )\right ) \left (-\mathit {atanh} \left (\tanh \left (b x +a \right )\right )+b n x +2 b x \right )}{b^{2} \left (n^{2}+3 n +2\right )} \] Input:
int(x*atanh(tanh(b*x+a))^n,x)
Output:
(atanh(tanh(a + b*x))**n*atanh(tanh(a + b*x))*( - atanh(tanh(a + b*x)) + b *n*x + 2*b*x))/(b**2*(n**2 + 3*n + 2))