Integrand size = 37, antiderivative size = 103 \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=\frac {d x}{a}+\frac {(b d-2 a e) \text {arctanh}\left (\frac {b+2 c f^{g+h x}}{\sqrt {b^2-4 a c}}\right )}{a \sqrt {b^2-4 a c} h \log (f)}-\frac {d \log \left (a+b f^{g+h x}+c f^{2 g+2 h x}\right )}{2 a h \log (f)} \]
[Out]
Time = 0.10 (sec) , antiderivative size = 103, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.162, Rules used = {2320, 814, 648, 632, 212, 642} \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=\frac {(b d-2 a e) \text {arctanh}\left (\frac {b+2 c f^{g+h x}}{\sqrt {b^2-4 a c}}\right )}{a h \log (f) \sqrt {b^2-4 a c}}-\frac {d \log \left (a+b f^{g+h x}+c f^{2 g+2 h x}\right )}{2 a h \log (f)}+\frac {d x}{a} \]
[In]
[Out]
Rule 212
Rule 632
Rule 642
Rule 648
Rule 814
Rule 2320
Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int \frac {d+e x}{x \left (a+b x+c x^2\right )} \, dx,x,f^{g+h x}\right )}{h \log (f)} \\ & = \frac {\text {Subst}\left (\int \left (\frac {d}{a x}+\frac {-b d+a e-c d x}{a \left (a+b x+c x^2\right )}\right ) \, dx,x,f^{g+h x}\right )}{h \log (f)} \\ & = \frac {d x}{a}+\frac {\text {Subst}\left (\int \frac {-b d+a e-c d x}{a+b x+c x^2} \, dx,x,f^{g+h x}\right )}{a h \log (f)} \\ & = \frac {d x}{a}-\frac {d \text {Subst}\left (\int \frac {b+2 c x}{a+b x+c x^2} \, dx,x,f^{g+h x}\right )}{2 a h \log (f)}-\frac {(b d-2 a e) \text {Subst}\left (\int \frac {1}{a+b x+c x^2} \, dx,x,f^{g+h x}\right )}{2 a h \log (f)} \\ & = \frac {d x}{a}-\frac {d \log \left (a+b f^{g+h x}+c f^{2 g+2 h x}\right )}{2 a h \log (f)}+\frac {(b d-2 a e) \text {Subst}\left (\int \frac {1}{b^2-4 a c-x^2} \, dx,x,b+2 c f^{g+h x}\right )}{a h \log (f)} \\ & = \frac {d x}{a}+\frac {(b d-2 a e) \tanh ^{-1}\left (\frac {b+2 c f^{g+h x}}{\sqrt {b^2-4 a c}}\right )}{a \sqrt {b^2-4 a c} h \log (f)}-\frac {d \log \left (a+b f^{g+h x}+c f^{2 g+2 h x}\right )}{2 a h \log (f)} \\ \end{align*}
Time = 0.19 (sec) , antiderivative size = 118, normalized size of antiderivative = 1.15 \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=\frac {(-2 b d+4 a e) \arctan \left (\frac {b+2 c f^{g+h x}}{\sqrt {-b^2+4 a c}}\right )+\sqrt {-b^2+4 a c} d \left (2 \log \left (f^{g+h x}\right )-\log \left (a+f^{g+h x} \left (b+c f^{g+h x}\right )\right )\right )}{2 a \sqrt {-b^2+4 a c} h \log (f)} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. \(992\) vs. \(2(97)=194\).
Time = 0.12 (sec) , antiderivative size = 993, normalized size of antiderivative = 9.64
method | result | size |
risch | \(\frac {4 \ln \left (f \right )^{2} a c d \,h^{2} x}{4 \ln \left (f \right )^{2} a^{2} c \,h^{2}-\ln \left (f \right )^{2} a \,b^{2} h^{2}}-\frac {\ln \left (f \right )^{2} b^{2} d \,h^{2} x}{4 \ln \left (f \right )^{2} a^{2} c \,h^{2}-\ln \left (f \right )^{2} a \,b^{2} h^{2}}+\frac {4 \ln \left (f \right )^{2} a c d g h}{4 \ln \left (f \right )^{2} a^{2} c \,h^{2}-\ln \left (f \right )^{2} a \,b^{2} h^{2}}-\frac {\ln \left (f \right )^{2} b^{2} d g h}{4 \ln \left (f \right )^{2} a^{2} c \,h^{2}-\ln \left (f \right )^{2} a \,b^{2} h^{2}}-\frac {2 \ln \left (f^{h x +g}+\frac {2 a b e -b^{2} d +\sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 c \left (2 a e -b d \right )}\right ) c d}{\left (4 c a -b^{2}\right ) h \ln \left (f \right )}+\frac {\ln \left (f^{h x +g}+\frac {2 a b e -b^{2} d +\sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 c \left (2 a e -b d \right )}\right ) b^{2} d}{2 a \left (4 c a -b^{2}\right ) h \ln \left (f \right )}+\frac {\ln \left (f^{h x +g}+\frac {2 a b e -b^{2} d +\sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 c \left (2 a e -b d \right )}\right ) \sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 a \left (4 c a -b^{2}\right ) h \ln \left (f \right )}-\frac {2 \ln \left (f^{h x +g}-\frac {-2 a b e +b^{2} d +\sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 c \left (2 a e -b d \right )}\right ) c d}{\left (4 c a -b^{2}\right ) h \ln \left (f \right )}+\frac {\ln \left (f^{h x +g}-\frac {-2 a b e +b^{2} d +\sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 c \left (2 a e -b d \right )}\right ) b^{2} d}{2 a \left (4 c a -b^{2}\right ) h \ln \left (f \right )}-\frac {\ln \left (f^{h x +g}-\frac {-2 a b e +b^{2} d +\sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 c \left (2 a e -b d \right )}\right ) \sqrt {-16 a^{3} c \,e^{2}+4 a^{2} b^{2} e^{2}+16 a^{2} b c d e -4 a \,b^{3} d e -4 d^{2} a \,b^{2} c +b^{4} d^{2}}}{2 a \left (4 c a -b^{2}\right ) h \ln \left (f \right )}\) | \(993\) |
[In]
[Out]
none
Time = 0.34 (sec) , antiderivative size = 330, normalized size of antiderivative = 3.20 \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=\left [\frac {2 \, {\left (b^{2} - 4 \, a c\right )} d h x \log \left (f\right ) - {\left (b^{2} - 4 \, a c\right )} d \log \left (c f^{2 \, h x + 2 \, g} + b f^{h x + g} + a\right ) - \sqrt {b^{2} - 4 \, a c} {\left (b d - 2 \, a e\right )} \log \left (\frac {2 \, c^{2} f^{2 \, h x + 2 \, g} + b^{2} - 2 \, a c + 2 \, {\left (b c - \sqrt {b^{2} - 4 \, a c} c\right )} f^{h x + g} - \sqrt {b^{2} - 4 \, a c} b}{c f^{2 \, h x + 2 \, g} + b f^{h x + g} + a}\right )}{2 \, {\left (a b^{2} - 4 \, a^{2} c\right )} h \log \left (f\right )}, \frac {2 \, {\left (b^{2} - 4 \, a c\right )} d h x \log \left (f\right ) - {\left (b^{2} - 4 \, a c\right )} d \log \left (c f^{2 \, h x + 2 \, g} + b f^{h x + g} + a\right ) + 2 \, \sqrt {-b^{2} + 4 \, a c} {\left (b d - 2 \, a e\right )} \arctan \left (-\frac {2 \, \sqrt {-b^{2} + 4 \, a c} c f^{h x + g} + \sqrt {-b^{2} + 4 \, a c} b}{b^{2} - 4 \, a c}\right )}{2 \, {\left (a b^{2} - 4 \, a^{2} c\right )} h \log \left (f\right )}\right ] \]
[In]
[Out]
Time = 0.63 (sec) , antiderivative size = 139, normalized size of antiderivative = 1.35 \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=\operatorname {RootSum} {\left (z^{2} \cdot \left (4 a^{2} c h^{2} \log {\left (f \right )}^{2} - a b^{2} h^{2} \log {\left (f \right )}^{2}\right ) + z \left (4 a c d h \log {\left (f \right )} - b^{2} d h \log {\left (f \right )}\right ) + a e^{2} - b d e + c d^{2}, \left ( i \mapsto i \log {\left (f^{g + h x} + \frac {4 i a^{2} c h \log {\left (f \right )} - i a b^{2} h \log {\left (f \right )} + a b e + 2 a c d - b^{2} d}{2 a c e - b c d} \right )} \right )\right )} + \frac {d x}{a} \]
[In]
[Out]
Exception generated. \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=\text {Exception raised: ValueError} \]
[In]
[Out]
none
Time = 0.30 (sec) , antiderivative size = 119, normalized size of antiderivative = 1.16 \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=-\frac {\frac {d \log \left (c f^{2 \, h x} f^{2 \, g} + b f^{h x} f^{g} + a\right )}{a \log \left (f\right )} - \frac {2 \, d \log \left ({\left | f \right |}^{h x} {\left | f \right |}^{g}\right )}{a \log \left (f\right )} + \frac {2 \, {\left (b d - 2 \, a e\right )} \arctan \left (\frac {2 \, c f^{h x} f^{g} + b}{\sqrt {-b^{2} + 4 \, a c}}\right )}{\sqrt {-b^{2} + 4 \, a c} a \log \left (f\right )}}{2 \, h} \]
[In]
[Out]
Time = 0.46 (sec) , antiderivative size = 105, normalized size of antiderivative = 1.02 \[ \int \frac {d+e f^{g+h x}}{a+b f^{g+h x}+c f^{2 g+2 h x}} \, dx=\frac {d\,x}{a}-\frac {d\,\ln \left (a+c\,f^{2\,h\,x}\,f^{2\,g}+b\,f^{h\,x}\,f^g\right )}{2\,a\,h\,\ln \left (f\right )}+\frac {\mathrm {atan}\left (\frac {b+2\,c\,f^{h\,x}\,f^g}{\sqrt {4\,a\,c-b^2}}\right )\,\left (2\,a\,e-b\,d\right )}{a\,h\,\ln \left (f\right )\,\sqrt {4\,a\,c-b^2}} \]
[In]
[Out]