\(\int e^{a x} \sin (b x) \, dx\) [81]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [C] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 10, antiderivative size = 42 \[ \int e^{a x} \sin (b x) \, dx=-\frac {b e^{a x} \cos (b x)}{a^2+b^2}+\frac {a e^{a x} \sin (b x)}{a^2+b^2} \]

[Out]

-b*exp(a*x)*cos(b*x)/(a^2+b^2)+a*exp(a*x)*sin(b*x)/(a^2+b^2)

Rubi [A] (verified)

Time = 0.01 (sec) , antiderivative size = 42, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {4517} \[ \int e^{a x} \sin (b x) \, dx=\frac {a e^{a x} \sin (b x)}{a^2+b^2}-\frac {b e^{a x} \cos (b x)}{a^2+b^2} \]

[In]

Int[E^(a*x)*Sin[b*x],x]

[Out]

-((b*E^(a*x)*Cos[b*x])/(a^2 + b^2)) + (a*E^(a*x)*Sin[b*x])/(a^2 + b^2)

Rule 4517

Int[(F_)^((c_.)*((a_.) + (b_.)*(x_)))*Sin[(d_.) + (e_.)*(x_)], x_Symbol] :> Simp[b*c*Log[F]*F^(c*(a + b*x))*(S
in[d + e*x]/(e^2 + b^2*c^2*Log[F]^2)), x] - Simp[e*F^(c*(a + b*x))*(Cos[d + e*x]/(e^2 + b^2*c^2*Log[F]^2)), x]
 /; FreeQ[{F, a, b, c, d, e}, x] && NeQ[e^2 + b^2*c^2*Log[F]^2, 0]

Rubi steps \begin{align*} \text {integral}& = -\frac {b e^{a x} \cos (b x)}{a^2+b^2}+\frac {a e^{a x} \sin (b x)}{a^2+b^2} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.02 (sec) , antiderivative size = 29, normalized size of antiderivative = 0.69 \[ \int e^{a x} \sin (b x) \, dx=\frac {e^{a x} (-b \cos (b x)+a \sin (b x))}{a^2+b^2} \]

[In]

Integrate[E^(a*x)*Sin[b*x],x]

[Out]

(E^(a*x)*(-(b*Cos[b*x]) + a*Sin[b*x]))/(a^2 + b^2)

Maple [A] (verified)

Time = 0.07 (sec) , antiderivative size = 29, normalized size of antiderivative = 0.69

method result size
parallelrisch \(\frac {{\mathrm e}^{a x} \left (\sin \left (b x \right ) a -b \cos \left (b x \right )\right )}{a^{2}+b^{2}}\) \(29\)
default \(-\frac {b \,{\mathrm e}^{a x} \cos \left (b x \right )}{a^{2}+b^{2}}+\frac {a \,{\mathrm e}^{a x} \sin \left (b x \right )}{a^{2}+b^{2}}\) \(41\)
risch \(-\frac {i {\mathrm e}^{x \left (i b +a \right )}}{2 \left (i b +a \right )}+\frac {i {\mathrm e}^{x \left (-i b +a \right )}}{-2 i b +2 a}\) \(42\)
norman \(\frac {\frac {b \,{\mathrm e}^{a x} \left (\tan ^{2}\left (\frac {b x}{2}\right )\right )}{a^{2}+b^{2}}-\frac {b \,{\mathrm e}^{a x}}{a^{2}+b^{2}}+\frac {2 a \,{\mathrm e}^{a x} \tan \left (\frac {b x}{2}\right )}{a^{2}+b^{2}}}{1+\tan ^{2}\left (\frac {b x}{2}\right )}\) \(73\)

[In]

int(exp(a*x)*sin(b*x),x,method=_RETURNVERBOSE)

[Out]

1/(a^2+b^2)*exp(a*x)*(sin(b*x)*a-b*cos(b*x))

Fricas [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 33, normalized size of antiderivative = 0.79 \[ \int e^{a x} \sin (b x) \, dx=-\frac {b \cos \left (b x\right ) e^{\left (a x\right )} - a e^{\left (a x\right )} \sin \left (b x\right )}{a^{2} + b^{2}} \]

[In]

integrate(exp(a*x)*sin(b*x),x, algorithm="fricas")

[Out]

-(b*cos(b*x)*e^(a*x) - a*e^(a*x)*sin(b*x))/(a^2 + b^2)

Sympy [C] (verification not implemented)

Result contains complex when optimal does not.

Time = 0.28 (sec) , antiderivative size = 136, normalized size of antiderivative = 3.24 \[ \int e^{a x} \sin (b x) \, dx=\begin {cases} 0 & \text {for}\: a = 0 \wedge b = 0 \\\frac {x e^{- i b x} \sin {\left (b x \right )}}{2} - \frac {i x e^{- i b x} \cos {\left (b x \right )}}{2} - \frac {e^{- i b x} \cos {\left (b x \right )}}{2 b} & \text {for}\: a = - i b \\\frac {x e^{i b x} \sin {\left (b x \right )}}{2} + \frac {i x e^{i b x} \cos {\left (b x \right )}}{2} - \frac {e^{i b x} \cos {\left (b x \right )}}{2 b} & \text {for}\: a = i b \\\frac {a e^{a x} \sin {\left (b x \right )}}{a^{2} + b^{2}} - \frac {b e^{a x} \cos {\left (b x \right )}}{a^{2} + b^{2}} & \text {otherwise} \end {cases} \]

[In]

integrate(exp(a*x)*sin(b*x),x)

[Out]

Piecewise((0, Eq(a, 0) & Eq(b, 0)), (x*exp(-I*b*x)*sin(b*x)/2 - I*x*exp(-I*b*x)*cos(b*x)/2 - exp(-I*b*x)*cos(b
*x)/(2*b), Eq(a, -I*b)), (x*exp(I*b*x)*sin(b*x)/2 + I*x*exp(I*b*x)*cos(b*x)/2 - exp(I*b*x)*cos(b*x)/(2*b), Eq(
a, I*b)), (a*exp(a*x)*sin(b*x)/(a**2 + b**2) - b*exp(a*x)*cos(b*x)/(a**2 + b**2), True))

Maxima [A] (verification not implemented)

none

Time = 0.20 (sec) , antiderivative size = 29, normalized size of antiderivative = 0.69 \[ \int e^{a x} \sin (b x) \, dx=-\frac {{\left (b \cos \left (b x\right ) - a \sin \left (b x\right )\right )} e^{\left (a x\right )}}{a^{2} + b^{2}} \]

[In]

integrate(exp(a*x)*sin(b*x),x, algorithm="maxima")

[Out]

-(b*cos(b*x) - a*sin(b*x))*e^(a*x)/(a^2 + b^2)

Giac [A] (verification not implemented)

none

Time = 0.28 (sec) , antiderivative size = 38, normalized size of antiderivative = 0.90 \[ \int e^{a x} \sin (b x) \, dx=-{\left (\frac {b \cos \left (b x\right )}{a^{2} + b^{2}} - \frac {a \sin \left (b x\right )}{a^{2} + b^{2}}\right )} e^{\left (a x\right )} \]

[In]

integrate(exp(a*x)*sin(b*x),x, algorithm="giac")

[Out]

-(b*cos(b*x)/(a^2 + b^2) - a*sin(b*x)/(a^2 + b^2))*e^(a*x)

Mupad [B] (verification not implemented)

Time = 0.02 (sec) , antiderivative size = 29, normalized size of antiderivative = 0.69 \[ \int e^{a x} \sin (b x) \, dx=-\frac {{\mathrm {e}}^{a\,x}\,\left (b\,\cos \left (b\,x\right )-a\,\sin \left (b\,x\right )\right )}{a^2+b^2} \]

[In]

int(exp(a*x)*sin(b*x),x)

[Out]

-(exp(a*x)*(b*cos(b*x) - a*sin(b*x)))/(a^2 + b^2)