Integrand size = 17, antiderivative size = 45 \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=\log (x)-\frac {\tanh \left (a+b \log \left (c x^n\right )\right )}{b n}-\frac {\tanh ^3\left (a+b \log \left (c x^n\right )\right )}{3 b n} \]
[Out]
Time = 0.03 (sec) , antiderivative size = 45, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.118, Rules used = {3554, 8} \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=-\frac {\tanh ^3\left (a+b \log \left (c x^n\right )\right )}{3 b n}-\frac {\tanh \left (a+b \log \left (c x^n\right )\right )}{b n}+\log (x) \]
[In]
[Out]
Rule 8
Rule 3554
Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int \tanh ^4(a+b x) \, dx,x,\log \left (c x^n\right )\right )}{n} \\ & = -\frac {\tanh ^3\left (a+b \log \left (c x^n\right )\right )}{3 b n}+\frac {\text {Subst}\left (\int \tanh ^2(a+b x) \, dx,x,\log \left (c x^n\right )\right )}{n} \\ & = -\frac {\tanh \left (a+b \log \left (c x^n\right )\right )}{b n}-\frac {\tanh ^3\left (a+b \log \left (c x^n\right )\right )}{3 b n}+\frac {\text {Subst}\left (\int 1 \, dx,x,\log \left (c x^n\right )\right )}{n} \\ & = \log (x)-\frac {\tanh \left (a+b \log \left (c x^n\right )\right )}{b n}-\frac {\tanh ^3\left (a+b \log \left (c x^n\right )\right )}{3 b n} \\ \end{align*}
Time = 0.10 (sec) , antiderivative size = 62, normalized size of antiderivative = 1.38 \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=\frac {\text {arctanh}\left (\tanh \left (a+b \log \left (c x^n\right )\right )\right )}{b n}-\frac {\tanh \left (a+b \log \left (c x^n\right )\right )}{b n}-\frac {\tanh ^3\left (a+b \log \left (c x^n\right )\right )}{3 b n} \]
[In]
[Out]
Time = 0.33 (sec) , antiderivative size = 42, normalized size of antiderivative = 0.93
method | result | size |
parallelrisch | \(-\frac {-3 \ln \left (x \right ) b n +{\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )}^{3}+3 \tanh \left (a +b \ln \left (c \,x^{n}\right )\right )}{3 b n}\) | \(42\) |
derivativedivides | \(\frac {-\frac {{\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )}^{3}}{3}-\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )-\frac {\ln \left (\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )-1\right )}{2}+\frac {\ln \left (\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )+1\right )}{2}}{n b}\) | \(69\) |
default | \(\frac {-\frac {{\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )}^{3}}{3}-\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )-\frac {\ln \left (\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )-1\right )}{2}+\frac {\ln \left (\tanh \left (a +b \ln \left (c \,x^{n}\right )\right )+1\right )}{2}}{n b}\) | \(69\) |
risch | \(\ln \left (x \right )+\frac {4 \left (x^{n}\right )^{4 b} c^{4 b} {\mathrm e}^{4 a} {\mathrm e}^{2 i b \pi \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}} {\mathrm e}^{-2 i b \pi \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) \operatorname {csgn}\left (i c \right )} {\mathrm e}^{-2 i b \pi \operatorname {csgn}\left (i c \,x^{n}\right )^{3}} {\mathrm e}^{2 i b \pi \operatorname {csgn}\left (i c \,x^{n}\right )^{2} \operatorname {csgn}\left (i c \right )}+4 \left (x^{n}\right )^{2 b} c^{2 b} {\mathrm e}^{2 a} {\mathrm e}^{i b \pi \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}} {\mathrm e}^{-i b \pi \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) \operatorname {csgn}\left (i c \right )} {\mathrm e}^{-i b \pi \operatorname {csgn}\left (i c \,x^{n}\right )^{3}} {\mathrm e}^{i b \pi \operatorname {csgn}\left (i c \,x^{n}\right )^{2} \operatorname {csgn}\left (i c \right )}+\frac {8}{3}}{b n {\left (\left (x^{n}\right )^{2 b} c^{2 b} {\mathrm e}^{2 a} {\mathrm e}^{i b \pi \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}} {\mathrm e}^{-i b \pi \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) \operatorname {csgn}\left (i c \right )} {\mathrm e}^{-i b \pi \operatorname {csgn}\left (i c \,x^{n}\right )^{3}} {\mathrm e}^{i b \pi \operatorname {csgn}\left (i c \,x^{n}\right )^{2} \operatorname {csgn}\left (i c \right )}+1\right )}^{3}}\) | \(329\) |
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 194 vs. \(2 (43) = 86\).
Time = 0.27 (sec) , antiderivative size = 194, normalized size of antiderivative = 4.31 \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=\frac {{\left (3 \, b n \log \left (x\right ) + 4\right )} \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{3} + 3 \, {\left (3 \, b n \log \left (x\right ) + 4\right )} \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} - 12 \, \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) - 4 \, \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{3} + 3 \, {\left (3 \, b n \log \left (x\right ) + 4\right )} \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )}{3 \, {\left (b n \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{3} + 3 \, b n \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} + 3 \, b n \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )\right )}} \]
[In]
[Out]
Time = 1.65 (sec) , antiderivative size = 65, normalized size of antiderivative = 1.44 \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=\begin {cases} \log {\left (x \right )} \tanh ^{4}{\left (a \right )} & \text {for}\: b = 0 \wedge \left (b = 0 \vee n = 0\right ) \\\log {\left (x \right )} \tanh ^{4}{\left (a + b \log {\left (c \right )} \right )} & \text {for}\: n = 0 \\\frac {\log {\left (c x^{n} \right )}}{n} - \frac {\tanh ^{3}{\left (a + b \log {\left (c x^{n} \right )} \right )}}{3 b n} - \frac {\tanh {\left (a + b \log {\left (c x^{n} \right )} \right )}}{b n} & \text {otherwise} \end {cases} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 494 vs. \(2 (43) = 86\).
Time = 0.28 (sec) , antiderivative size = 494, normalized size of antiderivative = 10.98 \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=\frac {18 \, c^{4 \, b} e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 27 \, c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 11}{12 \, {\left (b c^{6 \, b} n e^{\left (6 \, b \log \left (x^{n}\right ) + 6 \, a\right )} + 3 \, b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 3 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} + \frac {6 \, c^{4 \, b} e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 15 \, c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 11}{12 \, {\left (b c^{6 \, b} n e^{\left (6 \, b \log \left (x^{n}\right ) + 6 \, a\right )} + 3 \, b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 3 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} + \frac {2 \, {\left (3 \, c^{4 \, b} e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 3 \, c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 1\right )}}{3 \, {\left (b c^{6 \, b} n e^{\left (6 \, b \log \left (x^{n}\right ) + 6 \, a\right )} + 3 \, b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 3 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} - \frac {3 \, c^{2 \, b} e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + 1}{2 \, {\left (b c^{6 \, b} n e^{\left (6 \, b \log \left (x^{n}\right ) + 6 \, a\right )} + 3 \, b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 3 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} + \frac {2}{3 \, {\left (b c^{6 \, b} n e^{\left (6 \, b \log \left (x^{n}\right ) + 6 \, a\right )} + 3 \, b c^{4 \, b} n e^{\left (4 \, b \log \left (x^{n}\right ) + 4 \, a\right )} + 3 \, b c^{2 \, b} n e^{\left (2 \, b \log \left (x^{n}\right ) + 2 \, a\right )} + b n\right )}} + \log \left (x\right ) \]
[In]
[Out]
none
Time = 0.40 (sec) , antiderivative size = 67, normalized size of antiderivative = 1.49 \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=\frac {4 \, {\left (3 \, c^{4 \, b} x^{4 \, b n} e^{\left (4 \, a\right )} + 3 \, c^{2 \, b} x^{2 \, b n} e^{\left (2 \, a\right )} + 2\right )}}{3 \, {\left (c^{2 \, b} x^{2 \, b n} e^{\left (2 \, a\right )} + 1\right )}^{3} b n} + \log \left (x\right ) \]
[In]
[Out]
Time = 1.76 (sec) , antiderivative size = 162, normalized size of antiderivative = 3.60 \[ \int \frac {\tanh ^4\left (a+b \log \left (c x^n\right )\right )}{x} \, dx=\ln \left (x\right )+\frac {\frac {4}{3\,b\,n}+\frac {4\,{\mathrm {e}}^{4\,a}\,{\left (c\,x^n\right )}^{4\,b}}{3\,b\,n}}{3\,{\mathrm {e}}^{2\,a}\,{\left (c\,x^n\right )}^{2\,b}+3\,{\mathrm {e}}^{4\,a}\,{\left (c\,x^n\right )}^{4\,b}+{\mathrm {e}}^{6\,a}\,{\left (c\,x^n\right )}^{6\,b}+1}+\frac {4}{3\,b\,n\,\left ({\mathrm {e}}^{2\,a}\,{\left (c\,x^n\right )}^{2\,b}+1\right )}+\frac {4\,{\mathrm {e}}^{2\,a}\,{\left (c\,x^n\right )}^{2\,b}}{3\,b\,n\,\left (2\,{\mathrm {e}}^{2\,a}\,{\left (c\,x^n\right )}^{2\,b}+{\mathrm {e}}^{4\,a}\,{\left (c\,x^n\right )}^{4\,b}+1\right )} \]
[In]
[Out]