3.7.3 \(\int \frac {e^{m x}}{\cosh (x)+\sinh (x)} \, dx\) [603]

Optimal. Leaf size=13 \[ \frac {e^{(-1+m) x}}{-1+m} \]

[Out]

exp((-1+m)*x)/(-1+m)

________________________________________________________________________________________

Rubi [A]
time = 0.02, antiderivative size = 19, normalized size of antiderivative = 1.46, number of steps used = 3, number of rules used = 3, integrand size = 13, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.231, Rules used = {5767, 2259, 2225} \begin {gather*} -\frac {e^{-((1-m) x)}}{1-m} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[E^(m*x)/(Cosh[x] + Sinh[x]),x]

[Out]

-(1/(E^((1 - m)*x)*(1 - m)))

Rule 2225

Int[((F_)^((c_.)*((a_.) + (b_.)*(x_))))^(n_.), x_Symbol] :> Simp[(F^(c*(a + b*x)))^n/(b*c*n*Log[F]), x] /; Fre
eQ[{F, a, b, c, n}, x]

Rule 2259

Int[(u_.)*(F_)^((a_.) + (b_.)*(v_)), x_Symbol] :> Int[u*F^(a + b*NormalizePowerOfLinear[v, x]), x] /; FreeQ[{F
, a, b}, x] && PolynomialQ[u, x] && PowerOfLinearQ[v, x] &&  !PowerOfLinearMatchQ[v, x]

Rule 5767

Int[(u_.)*(Cosh[v_]*(a_.) + (b_.)*Sinh[v_])^(n_.), x_Symbol] :> Int[u*(a*E^((a/b)*v))^n, x] /; FreeQ[{a, b, n}
, x] && EqQ[a^2 - b^2, 0]

Rubi steps

\begin {align*} \int \frac {e^{m x}}{\cosh (x)+\sinh (x)} \, dx &=\int e^{-x+m x} \, dx\\ &=\int e^{-(1-m) x} \, dx\\ &=-\frac {e^{-(1-m) x}}{1-m}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.02, size = 18, normalized size = 1.38 \begin {gather*} \frac {e^{m x} (\cosh (x)-\sinh (x))}{-1+m} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[E^(m*x)/(Cosh[x] + Sinh[x]),x]

[Out]

(E^(m*x)*(Cosh[x] - Sinh[x]))/(-1 + m)

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(25\) vs. \(2(12)=24\).
time = 0.09, size = 26, normalized size = 2.00

method result size
risch \(\frac {{\mathrm e}^{\left (-1+m \right ) x}}{-1+m}\) \(13\)
gosper \(\frac {{\mathrm e}^{m x}}{\left (-1+m \right ) \left (\cosh \left (x \right )+\sinh \left (x \right )\right )}\) \(18\)
default \(\frac {\sinh \left (\left (-1+m \right ) x \right )}{-1+m}+\frac {\cosh \left (\left (-1+m \right ) x \right )}{-1+m}\) \(26\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(m*x)/(cosh(x)+sinh(x)),x,method=_RETURNVERBOSE)

[Out]

1/(-1+m)*sinh((-1+m)*x)+cosh((-1+m)*x)/(-1+m)

________________________________________________________________________________________

Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: ValueError} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(m*x)/(cosh(x)+sinh(x)),x, algorithm="maxima")

[Out]

Exception raised: ValueError >> Computation failed since Maxima requested additional constraints; using the 'a
ssume' command before evaluation *may* help (example of legal syntax is 'assume(-m>0)', see `assume?` for more
 details)Is

________________________________________________________________________________________

Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 25 vs. \(2 (12) = 24\).
time = 0.62, size = 25, normalized size = 1.92 \begin {gather*} \frac {\cosh \left (m x\right ) + \sinh \left (m x\right )}{{\left (m - 1\right )} \cosh \left (x\right ) + {\left (m - 1\right )} \sinh \left (x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(m*x)/(cosh(x)+sinh(x)),x, algorithm="fricas")

[Out]

(cosh(m*x) + sinh(m*x))/((m - 1)*cosh(x) + (m - 1)*sinh(x))

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 32 vs. \(2 (8) = 16\).
time = 0.21, size = 32, normalized size = 2.46 \begin {gather*} \begin {cases} \frac {e^{m x}}{m \sinh {\left (x \right )} + m \cosh {\left (x \right )} - \sinh {\left (x \right )} - \cosh {\left (x \right )}} & \text {for}\: m \neq 1 \\\frac {x e^{x}}{\sinh {\left (x \right )} + \cosh {\left (x \right )}} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(m*x)/(cosh(x)+sinh(x)),x)

[Out]

Piecewise((exp(m*x)/(m*sinh(x) + m*cosh(x) - sinh(x) - cosh(x)), Ne(m, 1)), (x*exp(x)/(sinh(x) + cosh(x)), Tru
e))

________________________________________________________________________________________

Giac [A]
time = 0.70, size = 16, normalized size = 1.23 \begin {gather*} \frac {e^{\left (m x\right )}}{m e^{x} - e^{x}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(m*x)/(cosh(x)+sinh(x)),x, algorithm="giac")

[Out]

e^(m*x)/(m*e^x - e^x)

________________________________________________________________________________________

Mupad [B]
time = 0.11, size = 14, normalized size = 1.08 \begin {gather*} \frac {{\mathrm {e}}^{m\,x-x}}{m-1} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(m*x)/(cosh(x) + sinh(x)),x)

[Out]

exp(m*x - x)/(m - 1)

________________________________________________________________________________________