3.467 \(\int \frac {e^{d+e x}}{x^2 (a+b x+c x^2)} \, dx\)

Optimal. Leaf size=212 \[ \frac {\left (\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}+b\right ) e^{d-\frac {e \left (b-\sqrt {b^2-4 a c}\right )}{2 c}} \text {Ei}\left (\frac {e \left (b+2 c x-\sqrt {b^2-4 a c}\right )}{2 c}\right )}{2 a^2}+\frac {\left (b-\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}\right ) e^{d-\frac {e \left (\sqrt {b^2-4 a c}+b\right )}{2 c}} \text {Ei}\left (\frac {e \left (b+2 c x+\sqrt {b^2-4 a c}\right )}{2 c}\right )}{2 a^2}-\frac {b e^d \text {Ei}(e x)}{a^2}+\frac {e^d e \text {Ei}(e x)}{a}-\frac {e^{d+e x}}{a x} \]

[Out]

-exp(e*x+d)/a/x-b*exp(d)*Ei(e*x)/a^2+e*exp(d)*Ei(e*x)/a+1/2*exp(d-1/2*e*(b+(-4*a*c+b^2)^(1/2))/c)*Ei(1/2*e*(b+
2*c*x+(-4*a*c+b^2)^(1/2))/c)*(b+(2*a*c-b^2)/(-4*a*c+b^2)^(1/2))/a^2+1/2*exp(d-1/2*e*(b-(-4*a*c+b^2)^(1/2))/c)*
Ei(1/2*e*(b+2*c*x-(-4*a*c+b^2)^(1/2))/c)*(b+(-2*a*c+b^2)/(-4*a*c+b^2)^(1/2))/a^2

________________________________________________________________________________________

Rubi [A]  time = 0.62, antiderivative size = 212, normalized size of antiderivative = 1.00, number of steps used = 9, number of rules used = 3, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.130, Rules used = {2270, 2177, 2178} \[ \frac {\left (\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}+b\right ) e^{d-\frac {e \left (b-\sqrt {b^2-4 a c}\right )}{2 c}} \text {Ei}\left (\frac {e \left (b+2 c x-\sqrt {b^2-4 a c}\right )}{2 c}\right )}{2 a^2}+\frac {\left (b-\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}\right ) e^{d-\frac {e \left (\sqrt {b^2-4 a c}+b\right )}{2 c}} \text {Ei}\left (\frac {e \left (b+2 c x+\sqrt {b^2-4 a c}\right )}{2 c}\right )}{2 a^2}-\frac {b e^d \text {Ei}(e x)}{a^2}+\frac {e^d e \text {Ei}(e x)}{a}-\frac {e^{d+e x}}{a x} \]

Antiderivative was successfully verified.

[In]

Int[E^(d + e*x)/(x^2*(a + b*x + c*x^2)),x]

[Out]

-(E^(d + e*x)/(a*x)) - (b*E^d*ExpIntegralEi[e*x])/a^2 + (e*E^d*ExpIntegralEi[e*x])/a + ((b + (b^2 - 2*a*c)/Sqr
t[b^2 - 4*a*c])*E^(d - ((b - Sqrt[b^2 - 4*a*c])*e)/(2*c))*ExpIntegralEi[(e*(b - Sqrt[b^2 - 4*a*c] + 2*c*x))/(2
*c)])/(2*a^2) + ((b - (b^2 - 2*a*c)/Sqrt[b^2 - 4*a*c])*E^(d - ((b + Sqrt[b^2 - 4*a*c])*e)/(2*c))*ExpIntegralEi
[(e*(b + Sqrt[b^2 - 4*a*c] + 2*c*x))/(2*c)])/(2*a^2)

Rule 2177

Int[((b_.)*(F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_), x_Symbol] :> Simp[((c + d*x)^(m
 + 1)*(b*F^(g*(e + f*x)))^n)/(d*(m + 1)), x] - Dist[(f*g*n*Log[F])/(d*(m + 1)), Int[(c + d*x)^(m + 1)*(b*F^(g*
(e + f*x)))^n, x], x] /; FreeQ[{F, b, c, d, e, f, g, n}, x] && LtQ[m, -1] && IntegerQ[2*m] &&  !$UseGamma ===
True

Rule 2178

Int[(F_)^((g_.)*((e_.) + (f_.)*(x_)))/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[(F^(g*(e - (c*f)/d))*ExpIntegral
Ei[(f*g*(c + d*x)*Log[F])/d])/d, x] /; FreeQ[{F, c, d, e, f, g}, x] &&  !$UseGamma === True

Rule 2270

Int[((F_)^((g_.)*((d_.) + (e_.)*(x_))^(n_.))*(u_)^(m_.))/((a_.) + (b_.)*(x_) + (c_)*(x_)^2), x_Symbol] :> Int[
ExpandIntegrand[F^(g*(d + e*x)^n), u^m/(a + b*x + c*x^2), x], x] /; FreeQ[{F, a, b, c, d, e, g, n}, x] && Poly
nomialQ[u, x] && IntegerQ[m]

Rubi steps

\begin {align*} \int \frac {e^{d+e x}}{x^2 \left (a+b x+c x^2\right )} \, dx &=\int \left (\frac {e^{d+e x}}{a x^2}-\frac {b e^{d+e x}}{a^2 x}+\frac {e^{d+e x} \left (b^2-a c+b c x\right )}{a^2 \left (a+b x+c x^2\right )}\right ) \, dx\\ &=\frac {\int \frac {e^{d+e x} \left (b^2-a c+b c x\right )}{a+b x+c x^2} \, dx}{a^2}+\frac {\int \frac {e^{d+e x}}{x^2} \, dx}{a}-\frac {b \int \frac {e^{d+e x}}{x} \, dx}{a^2}\\ &=-\frac {e^{d+e x}}{a x}-\frac {b e^d \text {Ei}(e x)}{a^2}+\frac {\int \left (\frac {\left (b c+\frac {c \left (b^2-2 a c\right )}{\sqrt {b^2-4 a c}}\right ) e^{d+e x}}{b-\sqrt {b^2-4 a c}+2 c x}+\frac {\left (b c-\frac {c \left (b^2-2 a c\right )}{\sqrt {b^2-4 a c}}\right ) e^{d+e x}}{b+\sqrt {b^2-4 a c}+2 c x}\right ) \, dx}{a^2}+\frac {e \int \frac {e^{d+e x}}{x} \, dx}{a}\\ &=-\frac {e^{d+e x}}{a x}-\frac {b e^d \text {Ei}(e x)}{a^2}+\frac {e e^d \text {Ei}(e x)}{a}+\frac {\left (c \left (b-\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}\right )\right ) \int \frac {e^{d+e x}}{b+\sqrt {b^2-4 a c}+2 c x} \, dx}{a^2}+\frac {\left (c \left (b+\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}\right )\right ) \int \frac {e^{d+e x}}{b-\sqrt {b^2-4 a c}+2 c x} \, dx}{a^2}\\ &=-\frac {e^{d+e x}}{a x}-\frac {b e^d \text {Ei}(e x)}{a^2}+\frac {e e^d \text {Ei}(e x)}{a}+\frac {\left (b+\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}\right ) e^{d-\frac {\left (b-\sqrt {b^2-4 a c}\right ) e}{2 c}} \text {Ei}\left (\frac {e \left (b-\sqrt {b^2-4 a c}+2 c x\right )}{2 c}\right )}{2 a^2}+\frac {\left (b-\frac {b^2-2 a c}{\sqrt {b^2-4 a c}}\right ) e^{d-\frac {\left (b+\sqrt {b^2-4 a c}\right ) e}{2 c}} \text {Ei}\left (\frac {e \left (b+\sqrt {b^2-4 a c}+2 c x\right )}{2 c}\right )}{2 a^2}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 1.14, size = 232, normalized size = 1.09 \[ \frac {e^d \left (\frac {e^{-\frac {e \left (\sqrt {b^2-4 a c}+b\right )}{2 c}} \left (x \left (b \sqrt {b^2-4 a c}-2 a c+b^2\right ) e^{\frac {e \sqrt {b^2-4 a c}}{c}} \text {Ei}\left (\frac {e \left (b+2 c x-\sqrt {b^2-4 a c}\right )}{2 c}\right )+x \left (b \sqrt {b^2-4 a c}+2 a c-b^2\right ) \text {Ei}\left (\frac {e \left (b+2 c x+\sqrt {b^2-4 a c}\right )}{2 c}\right )-2 a \sqrt {b^2-4 a c} e^{\frac {e \left (\sqrt {b^2-4 a c}+b+2 c x\right )}{2 c}}\right )}{x \sqrt {b^2-4 a c}}-2 (b-a e) \text {Ei}(e x)\right )}{2 a^2} \]

Antiderivative was successfully verified.

[In]

Integrate[E^(d + e*x)/(x^2*(a + b*x + c*x^2)),x]

[Out]

(E^d*(-2*(b - a*e)*ExpIntegralEi[e*x] + (-2*a*Sqrt[b^2 - 4*a*c]*E^((e*(b + Sqrt[b^2 - 4*a*c] + 2*c*x))/(2*c))
+ (b^2 - 2*a*c + b*Sqrt[b^2 - 4*a*c])*E^((Sqrt[b^2 - 4*a*c]*e)/c)*x*ExpIntegralEi[(e*(b - Sqrt[b^2 - 4*a*c] +
2*c*x))/(2*c)] + (-b^2 + 2*a*c + b*Sqrt[b^2 - 4*a*c])*x*ExpIntegralEi[(e*(b + Sqrt[b^2 - 4*a*c] + 2*c*x))/(2*c
)])/(Sqrt[b^2 - 4*a*c]*E^(((b + Sqrt[b^2 - 4*a*c])*e)/(2*c))*x)))/(2*a^2)

________________________________________________________________________________________

fricas [A]  time = 0.41, size = 313, normalized size = 1.48 \[ \frac {2 \, {\left ({\left (a b^{2} - 4 \, a^{2} c\right )} e^{2} - {\left (b^{3} - 4 \, a b c\right )} e\right )} x {\rm Ei}\left (e x\right ) e^{d} - 2 \, {\left (a b^{2} - 4 \, a^{2} c\right )} e e^{\left (e x + d\right )} + {\left ({\left (b^{3} - 4 \, a b c\right )} e x + {\left (b^{2} c - 2 \, a c^{2}\right )} \sqrt {\frac {{\left (b^{2} - 4 \, a c\right )} e^{2}}{c^{2}}} x\right )} {\rm Ei}\left (\frac {2 \, c e x + b e - c \sqrt {\frac {{\left (b^{2} - 4 \, a c\right )} e^{2}}{c^{2}}}}{2 \, c}\right ) e^{\left (\frac {2 \, c d - b e + c \sqrt {\frac {{\left (b^{2} - 4 \, a c\right )} e^{2}}{c^{2}}}}{2 \, c}\right )} + {\left ({\left (b^{3} - 4 \, a b c\right )} e x - {\left (b^{2} c - 2 \, a c^{2}\right )} \sqrt {\frac {{\left (b^{2} - 4 \, a c\right )} e^{2}}{c^{2}}} x\right )} {\rm Ei}\left (\frac {2 \, c e x + b e + c \sqrt {\frac {{\left (b^{2} - 4 \, a c\right )} e^{2}}{c^{2}}}}{2 \, c}\right ) e^{\left (\frac {2 \, c d - b e - c \sqrt {\frac {{\left (b^{2} - 4 \, a c\right )} e^{2}}{c^{2}}}}{2 \, c}\right )}}{2 \, {\left (a^{2} b^{2} - 4 \, a^{3} c\right )} e x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(e*x+d)/x^2/(c*x^2+b*x+a),x, algorithm="fricas")

[Out]

1/2*(2*((a*b^2 - 4*a^2*c)*e^2 - (b^3 - 4*a*b*c)*e)*x*Ei(e*x)*e^d - 2*(a*b^2 - 4*a^2*c)*e*e^(e*x + d) + ((b^3 -
 4*a*b*c)*e*x + (b^2*c - 2*a*c^2)*sqrt((b^2 - 4*a*c)*e^2/c^2)*x)*Ei(1/2*(2*c*e*x + b*e - c*sqrt((b^2 - 4*a*c)*
e^2/c^2))/c)*e^(1/2*(2*c*d - b*e + c*sqrt((b^2 - 4*a*c)*e^2/c^2))/c) + ((b^3 - 4*a*b*c)*e*x - (b^2*c - 2*a*c^2
)*sqrt((b^2 - 4*a*c)*e^2/c^2)*x)*Ei(1/2*(2*c*e*x + b*e + c*sqrt((b^2 - 4*a*c)*e^2/c^2))/c)*e^(1/2*(2*c*d - b*e
 - c*sqrt((b^2 - 4*a*c)*e^2/c^2))/c))/((a^2*b^2 - 4*a^3*c)*e*x)

________________________________________________________________________________________

giac [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {e^{\left (e x + d\right )}}{{\left (c x^{2} + b x + a\right )} x^{2}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(e*x+d)/x^2/(c*x^2+b*x+a),x, algorithm="giac")

[Out]

integrate(e^(e*x + d)/((c*x^2 + b*x + a)*x^2), x)

________________________________________________________________________________________

maple [B]  time = 0.03, size = 561, normalized size = 2.65 \[ \left (-\frac {\left (a e -b \right ) \Ei \left (1, -e x \right ) {\mathrm e}^{d}}{a^{2} e}-\frac {{\mathrm e}^{e x +d}}{a e x}-\frac {-2 a c e \Ei \left (1, \frac {-b e +2 c d -2 \left (e x +d \right ) c +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}\right ) {\mathrm e}^{\frac {-b e +2 c d +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}}+2 a c e \Ei \left (1, -\frac {b e -2 c d +2 \left (e x +d \right ) c +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}\right ) {\mathrm e}^{-\frac {b e -2 c d +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}}+b^{2} e \Ei \left (1, \frac {-b e +2 c d -2 \left (e x +d \right ) c +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}\right ) {\mathrm e}^{\frac {-b e +2 c d +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}}-b^{2} e \Ei \left (1, -\frac {b e -2 c d +2 \left (e x +d \right ) c +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}\right ) {\mathrm e}^{-\frac {b e -2 c d +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}}+\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}\, b \Ei \left (1, \frac {-b e +2 c d -2 \left (e x +d \right ) c +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}\right ) {\mathrm e}^{\frac {-b e +2 c d +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}}+\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}\, b \Ei \left (1, -\frac {b e -2 c d +2 \left (e x +d \right ) c +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}\right ) {\mathrm e}^{-\frac {b e -2 c d +\sqrt {-4 a c \,e^{2}+b^{2} e^{2}}}{2 c}}}{2 \sqrt {-4 a c \,e^{2}+b^{2} e^{2}}\, a^{2} e}\right ) e \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(e*x+d)/x^2/(c*x^2+b*x+a),x)

[Out]

e*(-exp(e*x+d)/a/x/e-1/2*(-2*exp(1/2/c*(-b*e+2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2)))*Ei(1,1/2*(-2*(e*x+d)*c-b*e+2*c
*d+(-4*a*c*e^2+b^2*e^2)^(1/2))/c)*a*c*e+exp(1/2/c*(-b*e+2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2)))*Ei(1,1/2*(-2*(e*x+d
)*c-b*e+2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2))/c)*b^2*e+2*exp(-1/2*(b*e-2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2))/c)*Ei(1,-
1/2*(2*(e*x+d)*c+b*e-2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2))/c)*a*c*e-exp(-1/2*(b*e-2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2)
)/c)*Ei(1,-1/2*(2*(e*x+d)*c+b*e-2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2))/c)*b^2*e+exp(1/2/c*(-b*e+2*c*d+(-4*a*c*e^2+b
^2*e^2)^(1/2)))*Ei(1,1/2*(-2*(e*x+d)*c-b*e+2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2))/c)*(-4*a*c*e^2+b^2*e^2)^(1/2)*b+e
xp(-1/2*(b*e-2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2))/c)*Ei(1,-1/2*(2*(e*x+d)*c+b*e-2*c*d+(-4*a*c*e^2+b^2*e^2)^(1/2))
/c)*(-4*a*c*e^2+b^2*e^2)^(1/2)*b)/a^2/e/(-4*a*c*e^2+b^2*e^2)^(1/2)-1/a^2/e*(a*e-b)*exp(d)*Ei(1,-e*x))

________________________________________________________________________________________

maxima [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {e^{\left (e x + d\right )}}{{\left (c x^{2} + b x + a\right )} x^{2}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(e*x+d)/x^2/(c*x^2+b*x+a),x, algorithm="maxima")

[Out]

integrate(e^(e*x + d)/((c*x^2 + b*x + a)*x^2), x)

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.00 \[ \int \frac {{\mathrm {e}}^{d+e\,x}}{x^2\,\left (c\,x^2+b\,x+a\right )} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(d + e*x)/(x^2*(a + b*x + c*x^2)),x)

[Out]

int(exp(d + e*x)/(x^2*(a + b*x + c*x^2)), x)

________________________________________________________________________________________

sympy [F(-1)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(e*x+d)/x**2/(c*x**2+b*x+a),x)

[Out]

Timed out

________________________________________________________________________________________