3.339 \(\int e^{x^2} \sinh (a+b x) \, dx\)

Optimal. Leaf size=65 \[ \frac{1}{4} \sqrt{\pi } e^{a-\frac{b^2}{4}} \text{Erfi}\left (\frac{1}{2} (b+2 x)\right )-\frac{1}{4} \sqrt{\pi } e^{-a-\frac{b^2}{4}} \text{Erfi}\left (\frac{1}{2} (2 x-b)\right ) \]

[Out]

-(E^(-a - b^2/4)*Sqrt[Pi]*Erfi[(-b + 2*x)/2])/4 + (E^(a - b^2/4)*Sqrt[Pi]*Erfi[(b + 2*x)/2])/4

________________________________________________________________________________________

Rubi [A]  time = 0.0649381, antiderivative size = 65, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 3, integrand size = 12, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.25, Rules used = {5512, 2234, 2204} \[ \frac{1}{4} \sqrt{\pi } e^{a-\frac{b^2}{4}} \text{Erfi}\left (\frac{1}{2} (b+2 x)\right )-\frac{1}{4} \sqrt{\pi } e^{-a-\frac{b^2}{4}} \text{Erfi}\left (\frac{1}{2} (2 x-b)\right ) \]

Antiderivative was successfully verified.

[In]

Int[E^x^2*Sinh[a + b*x],x]

[Out]

-(E^(-a - b^2/4)*Sqrt[Pi]*Erfi[(-b + 2*x)/2])/4 + (E^(a - b^2/4)*Sqrt[Pi]*Erfi[(b + 2*x)/2])/4

Rule 5512

Int[(F_)^(u_)*Sinh[v_]^(n_.), x_Symbol] :> Int[ExpandTrigToExp[F^u, Sinh[v]^n, x], x] /; FreeQ[F, x] && (Linea
rQ[u, x] || PolyQ[u, x, 2]) && (LinearQ[v, x] || PolyQ[v, x, 2]) && IGtQ[n, 0]

Rule 2234

Int[(F_)^((a_.) + (b_.)*(x_) + (c_.)*(x_)^2), x_Symbol] :> Dist[F^(a - b^2/(4*c)), Int[F^((b + 2*c*x)^2/(4*c))
, x], x] /; FreeQ[{F, a, b, c}, x]

Rule 2204

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^2), x_Symbol] :> Simp[(F^a*Sqrt[Pi]*Erfi[(c + d*x)*Rt[b*Log[F], 2
]])/(2*d*Rt[b*Log[F], 2]), x] /; FreeQ[{F, a, b, c, d}, x] && PosQ[b]

Rubi steps

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

Mathematica [A]  time = 0.0662858, size = 51, normalized size = 0.78 \[ \frac{1}{4} \sqrt{\pi } e^{-\frac{b^2}{4}} \left ((\cosh (a)-\sinh (a)) \text{Erfi}\left (\frac{b}{2}-x\right )+(\sinh (a)+\cosh (a)) \text{Erfi}\left (\frac{b}{2}+x\right )\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[E^x^2*Sinh[a + b*x],x]

[Out]

(Sqrt[Pi]*(Erfi[b/2 - x]*(Cosh[a] - Sinh[a]) + Erfi[b/2 + x]*(Cosh[a] + Sinh[a])))/(4*E^(b^2/4))

________________________________________________________________________________________

Maple [C]  time = 0.073, size = 52, normalized size = 0.8 \begin{align*} -{\frac{i}{4}}\sqrt{\pi }{{\rm e}^{-a-{\frac{{b}^{2}}{4}}}}{\it Erf} \left ( -ix+{\frac{i}{2}}b \right ) -{\frac{i}{4}}\sqrt{\pi }{{\rm e}^{a-{\frac{{b}^{2}}{4}}}}{\it Erf} \left ( ix+{\frac{i}{2}}b \right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(x^2)*sinh(b*x+a),x)

[Out]

-1/4*I*Pi^(1/2)*exp(-a-1/4*b^2)*erf(-I*x+1/2*I*b)-1/4*I*Pi^(1/2)*exp(a-1/4*b^2)*erf(I*x+1/2*I*b)

________________________________________________________________________________________

Maxima [C]  time = 1.06116, size = 61, normalized size = 0.94 \begin{align*} -\frac{1}{4} i \, \sqrt{\pi } \operatorname{erf}\left (\frac{1}{2} i \, b + i \, x\right ) e^{\left (-\frac{1}{4} \, b^{2} + a\right )} + \frac{1}{4} i \, \sqrt{\pi } \operatorname{erf}\left (-\frac{1}{2} i \, b + i \, x\right ) e^{\left (-\frac{1}{4} \, b^{2} - a\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/4*I*sqrt(pi)*erf(1/2*I*b + I*x)*e^(-1/4*b^2 + a) + 1/4*I*sqrt(pi)*erf(-1/2*I*b + I*x)*e^(-1/4*b^2 - a)

________________________________________________________________________________________

Fricas [A]  time = 1.88877, size = 130, normalized size = 2. \begin{align*} \frac{1}{4} \, \sqrt{\pi }{\left (\operatorname{erfi}\left (\frac{1}{2} \, b + x\right ) e^{\left (\frac{1}{4} \, b^{2} + a\right )} - \operatorname{erfi}\left (-\frac{1}{2} \, b + x\right ) e^{\left (\frac{1}{4} \, b^{2} - a\right )}\right )} e^{\left (-\frac{1}{2} \, b^{2}\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*sqrt(pi)*(erfi(1/2*b + x)*e^(1/4*b^2 + a) - erfi(-1/2*b + x)*e^(1/4*b^2 - a))*e^(-1/2*b^2)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int e^{x^{2}} \sinh{\left (a + b x \right )}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(x**2)*sinh(b*x+a),x)

[Out]

Integral(exp(x**2)*sinh(a + b*x), x)

________________________________________________________________________________________

Giac [C]  time = 1.13084, size = 61, normalized size = 0.94 \begin{align*} \frac{1}{4} i \, \sqrt{\pi } \operatorname{erf}\left (-\frac{1}{2} i \, b - i \, x\right ) e^{\left (-\frac{1}{4} \, b^{2} + a\right )} - \frac{1}{4} i \, \sqrt{\pi } \operatorname{erf}\left (\frac{1}{2} i \, b - i \, x\right ) e^{\left (-\frac{1}{4} \, b^{2} - a\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*I*sqrt(pi)*erf(-1/2*I*b - I*x)*e^(-1/4*b^2 + a) - 1/4*I*sqrt(pi)*erf(1/2*I*b - I*x)*e^(-1/4*b^2 - a)