3.5.65 \(\int \frac {e^{a+b x} x}{c+d x^2} \, dx\) [465]

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

[Out]

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

________________________________________________________________________________________

Rubi [A]
time = 0.09, antiderivative size = 100, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 2, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.111, Rules used = {2303, 2209} \begin {gather*} \frac {e^{a+\frac {b \sqrt {-c}}{\sqrt {d}}} \text {Ei}\left (-\frac {b \left (\sqrt {-c}-\sqrt {d} x\right )}{\sqrt {d}}\right )}{2 d}+\frac {e^{a-\frac {b \sqrt {-c}}{\sqrt {d}}} \text {Ei}\left (\frac {b \left (\sqrt {d} x+\sqrt {-c}\right )}{\sqrt {d}}\right )}{2 d} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 2209

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

Rule 2303

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

Rubi steps

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

________________________________________________________________________________________

Mathematica [C] Result contains complex when optimal does not.
time = 0.07, size = 83, normalized size = 0.83 \begin {gather*} \frac {e^{a-\frac {i b \sqrt {c}}{\sqrt {d}}} \left (e^{\frac {2 i b \sqrt {c}}{\sqrt {d}}} \text {Ei}\left (b \left (-\frac {i \sqrt {c}}{\sqrt {d}}+x\right )\right )+\text {Ei}\left (b \left (\frac {i \sqrt {c}}{\sqrt {d}}+x\right )\right )\right )}{2 d} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(322\) vs. \(2(74)=148\).
time = 0.08, size = 323, normalized size = 3.23

method result size
risch \(-\frac {{\mathrm e}^{\frac {b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, \frac {b \sqrt {-c d}+a d -\left (b x +a \right ) d}{d}\right )}{2 d}-\frac {{\mathrm e}^{\frac {-b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, -\frac {b \sqrt {-c d}-a d +\left (b x +a \right ) d}{d}\right )}{2 d}\) \(100\)
derivativedivides \(\frac {-\frac {b \left ({\mathrm e}^{\frac {b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, \frac {b \sqrt {-c d}+a d -\left (b x +a \right ) d}{d}\right ) \sqrt {-c d}\, b +{\mathrm e}^{\frac {b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, \frac {b \sqrt {-c d}+a d -\left (b x +a \right ) d}{d}\right ) a d +{\mathrm e}^{-\frac {b \sqrt {-c d}-a d}{d}} \expIntegral \left (1, -\frac {b \sqrt {-c d}-a d +\left (b x +a \right ) d}{d}\right ) \sqrt {-c d}\, b -{\mathrm e}^{-\frac {b \sqrt {-c d}-a d}{d}} \expIntegral \left (1, -\frac {b \sqrt {-c d}-a d +\left (b x +a \right ) d}{d}\right ) a d \right )}{2 d \sqrt {-c d}}+\frac {a b \left ({\mathrm e}^{\frac {b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, \frac {b \sqrt {-c d}+a d -\left (b x +a \right ) d}{d}\right )-{\mathrm e}^{-\frac {b \sqrt {-c d}-a d}{d}} \expIntegral \left (1, -\frac {b \sqrt {-c d}-a d +\left (b x +a \right ) d}{d}\right )\right )}{2 \sqrt {-c d}}}{b^{2}}\) \(323\)
default \(\frac {-\frac {b \left ({\mathrm e}^{\frac {b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, \frac {b \sqrt {-c d}+a d -\left (b x +a \right ) d}{d}\right ) \sqrt {-c d}\, b +{\mathrm e}^{\frac {b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, \frac {b \sqrt {-c d}+a d -\left (b x +a \right ) d}{d}\right ) a d +{\mathrm e}^{-\frac {b \sqrt {-c d}-a d}{d}} \expIntegral \left (1, -\frac {b \sqrt {-c d}-a d +\left (b x +a \right ) d}{d}\right ) \sqrt {-c d}\, b -{\mathrm e}^{-\frac {b \sqrt {-c d}-a d}{d}} \expIntegral \left (1, -\frac {b \sqrt {-c d}-a d +\left (b x +a \right ) d}{d}\right ) a d \right )}{2 d \sqrt {-c d}}+\frac {a b \left ({\mathrm e}^{\frac {b \sqrt {-c d}+a d}{d}} \expIntegral \left (1, \frac {b \sqrt {-c d}+a d -\left (b x +a \right ) d}{d}\right )-{\mathrm e}^{-\frac {b \sqrt {-c d}-a d}{d}} \expIntegral \left (1, -\frac {b \sqrt {-c d}-a d +\left (b x +a \right ) d}{d}\right )\right )}{2 \sqrt {-c d}}}{b^{2}}\) \(323\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(b*x+a)*x/(d*x^2+c),x,method=_RETURNVERBOSE)

[Out]

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

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [A]
time = 0.43, size = 72, normalized size = 0.72 \begin {gather*} \frac {{\rm Ei}\left (b x - \sqrt {-\frac {b^{2} c}{d}}\right ) e^{\left (a + \sqrt {-\frac {b^{2} c}{d}}\right )} + {\rm Ei}\left (b x + \sqrt {-\frac {b^{2} c}{d}}\right ) e^{\left (a - \sqrt {-\frac {b^{2} c}{d}}\right )}}{2 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} e^{a} \int \frac {x e^{b x}}{c + d x^{2}}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {x\,{\mathrm {e}}^{a+b\,x}}{d\,x^2+c} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________