\(\int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx\) [67]

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

Optimal result

Integrand size = 23, antiderivative size = 82 \[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=\frac {(a-b) \text {arctanh}\left (\frac {\sqrt {b} \cosh (e+f x)}{\sqrt {a-b+b \cosh ^2(e+f x)}}\right )}{2 \sqrt {b} f}+\frac {\cosh (e+f x) \sqrt {a-b+b \cosh ^2(e+f x)}}{2 f} \]

[Out]

1/2*(a-b)*arctanh(cosh(f*x+e)*b^(1/2)/(a-b+b*cosh(f*x+e)^2)^(1/2))/f/b^(1/2)+1/2*cosh(f*x+e)*(a-b+b*cosh(f*x+e
)^2)^(1/2)/f

Rubi [A] (verified)

Time = 0.05 (sec) , antiderivative size = 82, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {3265, 201, 223, 212} \[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=\frac {(a-b) \text {arctanh}\left (\frac {\sqrt {b} \cosh (e+f x)}{\sqrt {a+b \cosh ^2(e+f x)-b}}\right )}{2 \sqrt {b} f}+\frac {\cosh (e+f x) \sqrt {a+b \cosh ^2(e+f x)-b}}{2 f} \]

[In]

Int[Sinh[e + f*x]*Sqrt[a + b*Sinh[e + f*x]^2],x]

[Out]

((a - b)*ArcTanh[(Sqrt[b]*Cosh[e + f*x])/Sqrt[a - b + b*Cosh[e + f*x]^2]])/(2*Sqrt[b]*f) + (Cosh[e + f*x]*Sqrt
[a - b + b*Cosh[e + f*x]^2])/(2*f)

Rule 201

Int[((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[x*((a + b*x^n)^p/(n*p + 1)), x] + Dist[a*n*(p/(n*p + 1)),
 Int[(a + b*x^n)^(p - 1), x], x] /; FreeQ[{a, b}, x] && IGtQ[n, 0] && GtQ[p, 0] && (IntegerQ[2*p] || (EqQ[n, 2
] && IntegerQ[4*p]) || (EqQ[n, 2] && IntegerQ[3*p]) || LtQ[Denominator[p + 1/n], Denominator[p]])

Rule 212

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))*ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 223

Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Subst[Int[1/(1 - b*x^2), x], x, x/Sqrt[a + b*x^2]] /; FreeQ[{a,
b}, x] &&  !GtQ[a, 0]

Rule 3265

Int[sin[(e_.) + (f_.)*(x_)]^(m_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]^2)^(p_.), x_Symbol] :> With[{ff = Free
Factors[Cos[e + f*x], x]}, Dist[-ff/f, Subst[Int[(1 - ff^2*x^2)^((m - 1)/2)*(a + b - b*ff^2*x^2)^p, x], x, Cos
[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f, p}, x] && IntegerQ[(m - 1)/2]

Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int \sqrt {a-b+b x^2} \, dx,x,\cosh (e+f x)\right )}{f} \\ & = \frac {\cosh (e+f x) \sqrt {a-b+b \cosh ^2(e+f x)}}{2 f}+\frac {(a-b) \text {Subst}\left (\int \frac {1}{\sqrt {a-b+b x^2}} \, dx,x,\cosh (e+f x)\right )}{2 f} \\ & = \frac {\cosh (e+f x) \sqrt {a-b+b \cosh ^2(e+f x)}}{2 f}+\frac {(a-b) \text {Subst}\left (\int \frac {1}{1-b x^2} \, dx,x,\frac {\cosh (e+f x)}{\sqrt {a-b+b \cosh ^2(e+f x)}}\right )}{2 f} \\ & = \frac {(a-b) \text {arctanh}\left (\frac {\sqrt {b} \cosh (e+f x)}{\sqrt {a-b+b \cosh ^2(e+f x)}}\right )}{2 \sqrt {b} f}+\frac {\cosh (e+f x) \sqrt {a-b+b \cosh ^2(e+f x)}}{2 f} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.23 (sec) , antiderivative size = 97, normalized size of antiderivative = 1.18 \[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=\frac {\cosh (e+f x) \sqrt {2 a-b+b \cosh (2 (e+f x))}}{2 \sqrt {2} f}+\frac {(a-b) \log \left (\sqrt {2} \sqrt {b} \cosh (e+f x)+\sqrt {2 a-b+b \cosh (2 (e+f x))}\right )}{2 \sqrt {b} f} \]

[In]

Integrate[Sinh[e + f*x]*Sqrt[a + b*Sinh[e + f*x]^2],x]

[Out]

(Cosh[e + f*x]*Sqrt[2*a - b + b*Cosh[2*(e + f*x)]])/(2*Sqrt[2]*f) + ((a - b)*Log[Sqrt[2]*Sqrt[b]*Cosh[e + f*x]
 + Sqrt[2*a - b + b*Cosh[2*(e + f*x)]]])/(2*Sqrt[b]*f)

Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(199\) vs. \(2(70)=140\).

Time = 0.06 (sec) , antiderivative size = 200, normalized size of antiderivative = 2.44

method result size
default \(\frac {\sqrt {\left (a +b \sinh \left (f x +e \right )^{2}\right ) \cosh \left (f x +e \right )^{2}}\, \left (\ln \left (\frac {2 b \cosh \left (f x +e \right )^{2}+2 \sqrt {b \cosh \left (f x +e \right )^{4}+\left (a -b \right ) \cosh \left (f x +e \right )^{2}}\, \sqrt {b}+a -b}{2 \sqrt {b}}\right ) a -b \ln \left (\frac {2 b \cosh \left (f x +e \right )^{2}+2 \sqrt {b \cosh \left (f x +e \right )^{4}+\left (a -b \right ) \cosh \left (f x +e \right )^{2}}\, \sqrt {b}+a -b}{2 \sqrt {b}}\right )+2 \sqrt {b \cosh \left (f x +e \right )^{4}+\left (a -b \right ) \cosh \left (f x +e \right )^{2}}\, \sqrt {b}\right )}{4 \sqrt {b}\, \cosh \left (f x +e \right ) \sqrt {a +b \sinh \left (f x +e \right )^{2}}\, f}\) \(200\)

[In]

int(sinh(f*x+e)*(a+b*sinh(f*x+e)^2)^(1/2),x,method=_RETURNVERBOSE)

[Out]

1/4*((a+b*sinh(f*x+e)^2)*cosh(f*x+e)^2)^(1/2)*(ln(1/2*(2*b*cosh(f*x+e)^2+2*(b*cosh(f*x+e)^4+(a-b)*cosh(f*x+e)^
2)^(1/2)*b^(1/2)+a-b)/b^(1/2))*a-b*ln(1/2*(2*b*cosh(f*x+e)^2+2*(b*cosh(f*x+e)^4+(a-b)*cosh(f*x+e)^2)^(1/2)*b^(
1/2)+a-b)/b^(1/2))+2*(b*cosh(f*x+e)^4+(a-b)*cosh(f*x+e)^2)^(1/2)*b^(1/2))/b^(1/2)/cosh(f*x+e)/(a+b*sinh(f*x+e)
^2)^(1/2)/f

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 727 vs. \(2 (70) = 140\).

Time = 0.33 (sec) , antiderivative size = 2130, normalized size of antiderivative = 25.98 \[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=\text {Too large to display} \]

[In]

integrate(sinh(f*x+e)*(a+b*sinh(f*x+e)^2)^(1/2),x, algorithm="fricas")

[Out]

[-1/8*(((a - b)*cosh(f*x + e)^2 + 2*(a - b)*cosh(f*x + e)*sinh(f*x + e) + (a - b)*sinh(f*x + e)^2)*sqrt(b)*log
((a^2*b*cosh(f*x + e)^8 + 8*a^2*b*cosh(f*x + e)*sinh(f*x + e)^7 + a^2*b*sinh(f*x + e)^8 + 2*(a^3 + a^2*b)*cosh
(f*x + e)^6 + 2*(14*a^2*b*cosh(f*x + e)^2 + a^3 + a^2*b)*sinh(f*x + e)^6 + 4*(14*a^2*b*cosh(f*x + e)^3 + 3*(a^
3 + a^2*b)*cosh(f*x + e))*sinh(f*x + e)^5 + (9*a^2*b - 4*a*b^2 + b^3)*cosh(f*x + e)^4 + (70*a^2*b*cosh(f*x + e
)^4 + 9*a^2*b - 4*a*b^2 + b^3 + 30*(a^3 + a^2*b)*cosh(f*x + e)^2)*sinh(f*x + e)^4 + 4*(14*a^2*b*cosh(f*x + e)^
5 + 10*(a^3 + a^2*b)*cosh(f*x + e)^3 + (9*a^2*b - 4*a*b^2 + b^3)*cosh(f*x + e))*sinh(f*x + e)^3 + b^3 + 2*(3*a
*b^2 - b^3)*cosh(f*x + e)^2 + 2*(14*a^2*b*cosh(f*x + e)^6 + 15*(a^3 + a^2*b)*cosh(f*x + e)^4 + 3*a*b^2 - b^3 +
 3*(9*a^2*b - 4*a*b^2 + b^3)*cosh(f*x + e)^2)*sinh(f*x + e)^2 - sqrt(2)*(a^2*cosh(f*x + e)^6 + 6*a^2*cosh(f*x
+ e)*sinh(f*x + e)^5 + a^2*sinh(f*x + e)^6 + 3*a^2*cosh(f*x + e)^4 + 3*(5*a^2*cosh(f*x + e)^2 + a^2)*sinh(f*x
+ e)^4 + 4*(5*a^2*cosh(f*x + e)^3 + 3*a^2*cosh(f*x + e))*sinh(f*x + e)^3 + (4*a*b - b^2)*cosh(f*x + e)^2 + (15
*a^2*cosh(f*x + e)^4 + 18*a^2*cosh(f*x + e)^2 + 4*a*b - b^2)*sinh(f*x + e)^2 + b^2 + 2*(3*a^2*cosh(f*x + e)^5
+ 6*a^2*cosh(f*x + e)^3 + (4*a*b - b^2)*cosh(f*x + e))*sinh(f*x + e))*sqrt(b)*sqrt((b*cosh(f*x + e)^2 + b*sinh
(f*x + e)^2 + 2*a - b)/(cosh(f*x + e)^2 - 2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2)) + 4*(2*a^2*b*cosh(
f*x + e)^7 + 3*(a^3 + a^2*b)*cosh(f*x + e)^5 + (9*a^2*b - 4*a*b^2 + b^3)*cosh(f*x + e)^3 + (3*a*b^2 - b^3)*cos
h(f*x + e))*sinh(f*x + e))/(cosh(f*x + e)^6 + 6*cosh(f*x + e)^5*sinh(f*x + e) + 15*cosh(f*x + e)^4*sinh(f*x +
e)^2 + 20*cosh(f*x + e)^3*sinh(f*x + e)^3 + 15*cosh(f*x + e)^2*sinh(f*x + e)^4 + 6*cosh(f*x + e)*sinh(f*x + e)
^5 + sinh(f*x + e)^6)) + ((a - b)*cosh(f*x + e)^2 + 2*(a - b)*cosh(f*x + e)*sinh(f*x + e) + (a - b)*sinh(f*x +
 e)^2)*sqrt(b)*log(-(b*cosh(f*x + e)^4 + 4*b*cosh(f*x + e)*sinh(f*x + e)^3 + b*sinh(f*x + e)^4 + 2*(a - b)*cos
h(f*x + e)^2 + 2*(3*b*cosh(f*x + e)^2 + a - b)*sinh(f*x + e)^2 - sqrt(2)*(cosh(f*x + e)^2 + 2*cosh(f*x + e)*si
nh(f*x + e) + sinh(f*x + e)^2 - 1)*sqrt(b)*sqrt((b*cosh(f*x + e)^2 + b*sinh(f*x + e)^2 + 2*a - b)/(cosh(f*x +
e)^2 - 2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2)) + 4*(b*cosh(f*x + e)^3 + (a - b)*cosh(f*x + e))*sinh(
f*x + e) + b)/(cosh(f*x + e)^2 + 2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2)) - sqrt(2)*(b*cosh(f*x + e)^
2 + 2*b*cosh(f*x + e)*sinh(f*x + e) + b*sinh(f*x + e)^2 + b)*sqrt((b*cosh(f*x + e)^2 + b*sinh(f*x + e)^2 + 2*a
 - b)/(cosh(f*x + e)^2 - 2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2)))/(b*f*cosh(f*x + e)^2 + 2*b*f*cosh(
f*x + e)*sinh(f*x + e) + b*f*sinh(f*x + e)^2), -1/8*(2*((a - b)*cosh(f*x + e)^2 + 2*(a - b)*cosh(f*x + e)*sinh
(f*x + e) + (a - b)*sinh(f*x + e)^2)*sqrt(-b)*arctan(sqrt(2)*(a*cosh(f*x + e)^2 + 2*a*cosh(f*x + e)*sinh(f*x +
 e) + a*sinh(f*x + e)^2 + b)*sqrt(-b)*sqrt((b*cosh(f*x + e)^2 + b*sinh(f*x + e)^2 + 2*a - b)/(cosh(f*x + e)^2
- 2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2))/(a*b*cosh(f*x + e)^4 + 4*a*b*cosh(f*x + e)*sinh(f*x + e)^3
 + a*b*sinh(f*x + e)^4 + (3*a*b - b^2)*cosh(f*x + e)^2 + (6*a*b*cosh(f*x + e)^2 + 3*a*b - b^2)*sinh(f*x + e)^2
 + b^2 + 2*(2*a*b*cosh(f*x + e)^3 + (3*a*b - b^2)*cosh(f*x + e))*sinh(f*x + e))) + 2*((a - b)*cosh(f*x + e)^2
+ 2*(a - b)*cosh(f*x + e)*sinh(f*x + e) + (a - b)*sinh(f*x + e)^2)*sqrt(-b)*arctan(sqrt(2)*(cosh(f*x + e)^2 +
2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2 - 1)*sqrt(-b)*sqrt((b*cosh(f*x + e)^2 + b*sinh(f*x + e)^2 + 2*
a - b)/(cosh(f*x + e)^2 - 2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2))/(b*cosh(f*x + e)^4 + 4*b*cosh(f*x
+ e)*sinh(f*x + e)^3 + b*sinh(f*x + e)^4 + 2*(2*a - b)*cosh(f*x + e)^2 + 2*(3*b*cosh(f*x + e)^2 + 2*a - b)*sin
h(f*x + e)^2 + 4*(b*cosh(f*x + e)^3 + (2*a - b)*cosh(f*x + e))*sinh(f*x + e) + b)) - sqrt(2)*(b*cosh(f*x + e)^
2 + 2*b*cosh(f*x + e)*sinh(f*x + e) + b*sinh(f*x + e)^2 + b)*sqrt((b*cosh(f*x + e)^2 + b*sinh(f*x + e)^2 + 2*a
 - b)/(cosh(f*x + e)^2 - 2*cosh(f*x + e)*sinh(f*x + e) + sinh(f*x + e)^2)))/(b*f*cosh(f*x + e)^2 + 2*b*f*cosh(
f*x + e)*sinh(f*x + e) + b*f*sinh(f*x + e)^2)]

Sympy [F]

\[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=\int \sqrt {a + b \sinh ^{2}{\left (e + f x \right )}} \sinh {\left (e + f x \right )}\, dx \]

[In]

integrate(sinh(f*x+e)*(a+b*sinh(f*x+e)**2)**(1/2),x)

[Out]

Integral(sqrt(a + b*sinh(e + f*x)**2)*sinh(e + f*x), x)

Maxima [F]

\[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=\int { \sqrt {b \sinh \left (f x + e\right )^{2} + a} \sinh \left (f x + e\right ) \,d x } \]

[In]

integrate(sinh(f*x+e)*(a+b*sinh(f*x+e)^2)^(1/2),x, algorithm="maxima")

[Out]

integrate(sqrt(b*sinh(f*x + e)^2 + a)*sinh(f*x + e), x)

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 424 vs. \(2 (70) = 140\).

Time = 0.46 (sec) , antiderivative size = 424, normalized size of antiderivative = 5.17 \[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=-\frac {{\left (\frac {4 \, {\left (a e^{\left (2 \, e\right )} - b e^{\left (2 \, e\right )}\right )} \arctan \left (-\frac {\sqrt {b} e^{\left (2 \, f x + 2 \, e\right )} - \sqrt {b e^{\left (4 \, f x + 4 \, e\right )} + 4 \, a e^{\left (2 \, f x + 2 \, e\right )} - 2 \, b e^{\left (2 \, f x + 2 \, e\right )} + b}}{\sqrt {-b}}\right )}{\sqrt {-b}} - \sqrt {b e^{\left (4 \, f x + 4 \, e\right )} + 4 \, a e^{\left (2 \, f x + 2 \, e\right )} - 2 \, b e^{\left (2 \, f x + 2 \, e\right )} + b} e^{\left (2 \, e\right )} + \frac {2 \, {\left (a e^{\left (2 \, e\right )} - b e^{\left (2 \, e\right )}\right )} \log \left ({\left | {\left (\sqrt {b} e^{\left (2 \, f x + 2 \, e\right )} - \sqrt {b e^{\left (4 \, f x + 4 \, e\right )} + 4 \, a e^{\left (2 \, f x + 2 \, e\right )} - 2 \, b e^{\left (2 \, f x + 2 \, e\right )} + b}\right )} \sqrt {b} + 2 \, a - b \right |}\right )}{\sqrt {b}} + \frac {2 \, {\left (2 \, {\left (\sqrt {b} e^{\left (2 \, f x + 2 \, e\right )} - \sqrt {b e^{\left (4 \, f x + 4 \, e\right )} + 4 \, a e^{\left (2 \, f x + 2 \, e\right )} - 2 \, b e^{\left (2 \, f x + 2 \, e\right )} + b}\right )} a e^{\left (2 \, e\right )} - {\left (\sqrt {b} e^{\left (2 \, f x + 2 \, e\right )} - \sqrt {b e^{\left (4 \, f x + 4 \, e\right )} + 4 \, a e^{\left (2 \, f x + 2 \, e\right )} - 2 \, b e^{\left (2 \, f x + 2 \, e\right )} + b}\right )} b e^{\left (2 \, e\right )} + b^{\frac {3}{2}} e^{\left (2 \, e\right )}\right )}}{{\left (\sqrt {b} e^{\left (2 \, f x + 2 \, e\right )} - \sqrt {b e^{\left (4 \, f x + 4 \, e\right )} + 4 \, a e^{\left (2 \, f x + 2 \, e\right )} - 2 \, b e^{\left (2 \, f x + 2 \, e\right )} + b}\right )}^{2} - b}\right )} e^{\left (-2 \, e\right )}}{8 \, f} \]

[In]

integrate(sinh(f*x+e)*(a+b*sinh(f*x+e)^2)^(1/2),x, algorithm="giac")

[Out]

-1/8*(4*(a*e^(2*e) - b*e^(2*e))*arctan(-(sqrt(b)*e^(2*f*x + 2*e) - sqrt(b*e^(4*f*x + 4*e) + 4*a*e^(2*f*x + 2*e
) - 2*b*e^(2*f*x + 2*e) + b))/sqrt(-b))/sqrt(-b) - sqrt(b*e^(4*f*x + 4*e) + 4*a*e^(2*f*x + 2*e) - 2*b*e^(2*f*x
 + 2*e) + b)*e^(2*e) + 2*(a*e^(2*e) - b*e^(2*e))*log(abs((sqrt(b)*e^(2*f*x + 2*e) - sqrt(b*e^(4*f*x + 4*e) + 4
*a*e^(2*f*x + 2*e) - 2*b*e^(2*f*x + 2*e) + b))*sqrt(b) + 2*a - b))/sqrt(b) + 2*(2*(sqrt(b)*e^(2*f*x + 2*e) - s
qrt(b*e^(4*f*x + 4*e) + 4*a*e^(2*f*x + 2*e) - 2*b*e^(2*f*x + 2*e) + b))*a*e^(2*e) - (sqrt(b)*e^(2*f*x + 2*e) -
 sqrt(b*e^(4*f*x + 4*e) + 4*a*e^(2*f*x + 2*e) - 2*b*e^(2*f*x + 2*e) + b))*b*e^(2*e) + b^(3/2)*e^(2*e))/((sqrt(
b)*e^(2*f*x + 2*e) - sqrt(b*e^(4*f*x + 4*e) + 4*a*e^(2*f*x + 2*e) - 2*b*e^(2*f*x + 2*e) + b))^2 - b))*e^(-2*e)
/f

Mupad [F(-1)]

Timed out. \[ \int \sinh (e+f x) \sqrt {a+b \sinh ^2(e+f x)} \, dx=\int \mathrm {sinh}\left (e+f\,x\right )\,\sqrt {b\,{\mathrm {sinh}\left (e+f\,x\right )}^2+a} \,d x \]

[In]

int(sinh(e + f*x)*(a + b*sinh(e + f*x)^2)^(1/2),x)

[Out]

int(sinh(e + f*x)*(a + b*sinh(e + f*x)^2)^(1/2), x)