Optimal. Leaf size=43 \[ \frac{\log \left (\cosh \left (a+b \log \left (c x^n\right )\right )\right )}{b n}-\frac{\tanh ^2\left (a+b \log \left (c x^n\right )\right )}{2 b n} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0406062, antiderivative size = 43, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 17, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.118, Rules used = {3473, 3475} \[ \frac{\log \left (\cosh \left (a+b \log \left (c x^n\right )\right )\right )}{b n}-\frac{\tanh ^2\left (a+b \log \left (c x^n\right )\right )}{2 b n} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3473
Rule 3475
Rubi steps
\begin{align*} \int \frac{\tanh ^3\left (a+b \log \left (c x^n\right )\right )}{x} \, dx &=\frac{\operatorname{Subst}\left (\int \tanh ^3(a+b x) \, dx,x,\log \left (c x^n\right )\right )}{n}\\ &=-\frac{\tanh ^2\left (a+b \log \left (c x^n\right )\right )}{2 b n}+\frac{\operatorname{Subst}\left (\int \tanh (a+b x) \, dx,x,\log \left (c x^n\right )\right )}{n}\\ &=\frac{\log \left (\cosh \left (a+b \log \left (c x^n\right )\right )\right )}{b n}-\frac{\tanh ^2\left (a+b \log \left (c x^n\right )\right )}{2 b n}\\ \end{align*}
Mathematica [A] time = 0.133635, size = 43, normalized size = 1. \[ \frac{\log \left (\cosh \left (a+b \log \left (c x^n\right )\right )\right )}{b n}-\frac{\tanh ^2\left (a+b \log \left (c x^n\right )\right )}{2 b n} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.007, size = 67, normalized size = 1.6 \begin{align*} -{\frac{ \left ( \tanh \left ( a+b\ln \left ( c{x}^{n} \right ) \right ) \right ) ^{2}}{2\,bn}}-{\frac{\ln \left ( \tanh \left ( a+b\ln \left ( c{x}^{n} \right ) \right ) -1 \right ) }{2\,bn}}-{\frac{\ln \left ( \tanh \left ( a+b\ln \left ( c{x}^{n} \right ) \right ) +1 \right ) }{2\,bn}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 1.50507, size = 410, normalized size = 9.53 \begin{align*} \frac{4 \, c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 3}{4 \,{\left (b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 2 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} - \frac{2 \, c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 3}{4 \,{\left (b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 2 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} + \frac{3 \,{\left (2 \, c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 1\right )}}{4 \,{\left (b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 2 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} - \frac{3}{4 \,{\left (b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 2 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} + \frac{\log \left (\frac{{\left (c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 1\right )} e^{\left (-2 \, a\right )}}{c^{2 \, b}}\right )}{b n} - \log \left (x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 2.05109, size = 1841, normalized size = 42.81 \begin{align*} \text{result too large to display} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 5.77996, size = 75, normalized size = 1.74 \begin{align*} \begin{cases} \log{\left (x \right )} \tanh ^{3}{\left (a \right )} & \text{for}\: b = 0 \wedge n = 0 \\\log{\left (x \right )} \tanh ^{3}{\left (a + b \log{\left (c \right )} \right )} & \text{for}\: n = 0 \\\log{\left (x \right )} \tanh ^{3}{\left (a \right )} & \text{for}\: b = 0 \\\log{\left (x \right )} - \frac{\log{\left (\tanh{\left (a + b n \log{\left (x \right )} + b \log{\left (c \right )} \right )} + 1 \right )}}{b n} - \frac{\tanh ^{2}{\left (a + b n \log{\left (x \right )} + b \log{\left (c \right )} \right )}}{2 b n} & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.38078, size = 170, normalized size = 3.95 \begin{align*} \frac{\log \left (2 \, x^{2 \, b n}{\left | c \right |}^{2 \, b} \cos \left (\pi b \mathrm{sgn}\left (c\right ) - \pi b\right ) e^{\left (2 \, a\right )} + x^{4 \, b n}{\left | c \right |}^{4 \, b} e^{\left (4 \, a\right )} + 1\right )}{2 \, b n} - \frac{3 \, c^{4 \, b} x^{4 \, b n} e^{\left (4 \, a\right )} + 2 \, c^{2 \, b} x^{2 \, b n} e^{\left (2 \, a\right )} + 3}{2 \,{\left (c^{2 \, b} x^{2 \, b n} e^{\left (2 \, a\right )} + 1\right )}^{2} b n} - \log \left (x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]