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

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

Optimal result

Integrand size = 19, antiderivative size = 271 \[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=\frac {\cosh \left (a-\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}\right ) \text {Chi}\left (\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}}-\frac {\cosh \left (a-\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{2 e}\right ) \text {Chi}\left (\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}}+\frac {\sinh \left (a-\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}\right ) \text {Shi}\left (\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}}-\frac {\sinh \left (a-\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{2 e}\right ) \text {Shi}\left (\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}} \] Output:

cosh(a-1/2*b*(d-(-4*c*e+d^2)^(1/2))/e)*Chi(1/2*b*(d-(-4*c*e+d^2)^(1/2))/e+ 
b*x)/(-4*c*e+d^2)^(1/2)-cosh(a-1/2*b*(d+(-4*c*e+d^2)^(1/2))/e)*Chi(1/2*b*( 
d+(-4*c*e+d^2)^(1/2))/e+b*x)/(-4*c*e+d^2)^(1/2)+sinh(a-1/2*b*(d-(-4*c*e+d^ 
2)^(1/2))/e)*Shi(1/2*b*(d-(-4*c*e+d^2)^(1/2))/e+b*x)/(-4*c*e+d^2)^(1/2)-si 
nh(a-1/2*b*(d+(-4*c*e+d^2)^(1/2))/e)*Shi(1/2*b*(d+(-4*c*e+d^2)^(1/2))/e+b* 
x)/(-4*c*e+d^2)^(1/2)
 

Mathematica [A] (verified)

Time = 0.56 (sec) , antiderivative size = 220, normalized size of antiderivative = 0.81 \[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=\frac {e^{-a-\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{2 e}} \left (e^{\frac {b d}{e}} \operatorname {ExpIntegralEi}\left (-\frac {b \left (d-\sqrt {d^2-4 c e}+2 e x\right )}{2 e}\right )+e^{2 a+\frac {b \sqrt {d^2-4 c e}}{e}} \operatorname {ExpIntegralEi}\left (\frac {b \left (d-\sqrt {d^2-4 c e}+2 e x\right )}{2 e}\right )-e^{\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{e}} \operatorname {ExpIntegralEi}\left (-\frac {b \left (d+\sqrt {d^2-4 c e}+2 e x\right )}{2 e}\right )-e^{2 a} \operatorname {ExpIntegralEi}\left (\frac {b \left (d+\sqrt {d^2-4 c e}+2 e x\right )}{2 e}\right )\right )}{2 \sqrt {d^2-4 c e}} \] Input:

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

Output:

(E^(-a - (b*(d + Sqrt[d^2 - 4*c*e]))/(2*e))*(E^((b*d)/e)*ExpIntegralEi[-1/ 
2*(b*(d - Sqrt[d^2 - 4*c*e] + 2*e*x))/e] + E^(2*a + (b*Sqrt[d^2 - 4*c*e])/ 
e)*ExpIntegralEi[(b*(d - Sqrt[d^2 - 4*c*e] + 2*e*x))/(2*e)] - E^((b*(d + S 
qrt[d^2 - 4*c*e]))/e)*ExpIntegralEi[-1/2*(b*(d + Sqrt[d^2 - 4*c*e] + 2*e*x 
))/e] - E^(2*a)*ExpIntegralEi[(b*(d + Sqrt[d^2 - 4*c*e] + 2*e*x))/(2*e)])) 
/(2*Sqrt[d^2 - 4*c*e])
 

Rubi [A] (verified)

Time = 1.05 (sec) , antiderivative size = 271, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.105, Rules used = {7279, 2009}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx\)

\(\Big \downarrow \) 7279

\(\displaystyle \int \left (\frac {2 e \cosh (a+b x)}{\sqrt {d^2-4 c e} \left (-\sqrt {d^2-4 c e}+d+2 e x\right )}-\frac {2 e \cosh (a+b x)}{\sqrt {d^2-4 c e} \left (\sqrt {d^2-4 c e}+d+2 e x\right )}\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\cosh \left (a-\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}\right ) \text {Chi}\left (\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}}-\frac {\cosh \left (a-\frac {b \left (\sqrt {d^2-4 c e}+d\right )}{2 e}\right ) \text {Chi}\left (\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}}+\frac {\sinh \left (a-\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}\right ) \text {Shi}\left (\frac {b \left (d-\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}}-\frac {\sinh \left (a-\frac {b \left (\sqrt {d^2-4 c e}+d\right )}{2 e}\right ) \text {Shi}\left (\frac {b \left (d+\sqrt {d^2-4 c e}\right )}{2 e}+b x\right )}{\sqrt {d^2-4 c e}}\)

Input:

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

Output:

(Cosh[a - (b*(d - Sqrt[d^2 - 4*c*e]))/(2*e)]*CoshIntegral[(b*(d - Sqrt[d^2 
 - 4*c*e]))/(2*e) + b*x])/Sqrt[d^2 - 4*c*e] - (Cosh[a - (b*(d + Sqrt[d^2 - 
 4*c*e]))/(2*e)]*CoshIntegral[(b*(d + Sqrt[d^2 - 4*c*e]))/(2*e) + b*x])/Sq 
rt[d^2 - 4*c*e] + (Sinh[a - (b*(d - Sqrt[d^2 - 4*c*e]))/(2*e)]*SinhIntegra 
l[(b*(d - Sqrt[d^2 - 4*c*e]))/(2*e) + b*x])/Sqrt[d^2 - 4*c*e] - (Sinh[a - 
(b*(d + Sqrt[d^2 - 4*c*e]))/(2*e)]*SinhIntegral[(b*(d + Sqrt[d^2 - 4*c*e]) 
)/(2*e) + b*x])/Sqrt[d^2 - 4*c*e]
 

Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 7279
Int[(u_)/((a_.) + (b_.)*(x_)^(n_.) + (c_.)*(x_)^(n2_.)), x_Symbol] :> With[ 
{v = RationalFunctionExpand[u/(a + b*x^n + c*x^(2*n)), x]}, Int[v, x] /; Su 
mQ[v]] /; FreeQ[{a, b, c}, x] && EqQ[n2, 2*n] && IGtQ[n, 0]
 
Maple [A] (verified)

Time = 0.83 (sec) , antiderivative size = 376, normalized size of antiderivative = 1.39

method result size
risch \(-\frac {b \,{\mathrm e}^{\frac {2 e a -b d +\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}} \operatorname {expIntegral}_{1}\left (\frac {-2 e \left (b x +a \right )+2 e a -b d +\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}\right )}{2 \sqrt {-4 b^{2} c e +b^{2} d^{2}}}-\frac {b \,{\mathrm e}^{-\frac {2 e a -b d +\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}} \operatorname {expIntegral}_{1}\left (-\frac {-2 e \left (b x +a \right )+2 e a -b d +\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}\right )}{2 \sqrt {-4 b^{2} c e +b^{2} d^{2}}}+\frac {b \,{\mathrm e}^{-\frac {2 e a -b d -\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}} \operatorname {expIntegral}_{1}\left (\frac {2 e \left (b x +a \right )-2 e a +b d +\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}\right )}{2 \sqrt {-4 b^{2} c e +b^{2} d^{2}}}+\frac {b \,{\mathrm e}^{\frac {2 e a -b d -\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}} \operatorname {expIntegral}_{1}\left (-\frac {2 e \left (b x +a \right )-2 e a +b d +\sqrt {-4 b^{2} c e +b^{2} d^{2}}}{2 e}\right )}{2 \sqrt {-4 b^{2} c e +b^{2} d^{2}}}\) \(376\)

Input:

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

Output:

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

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 671 vs. \(2 (231) = 462\).

Time = 0.11 (sec) , antiderivative size = 671, normalized size of antiderivative = 2.48 \[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=-\frac {{\left (e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (\frac {2 \, b e x + b d + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right ) + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (-\frac {2 \, b e x + b d + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right )\right )} \cosh \left (\frac {b d - 2 \, a e + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right ) - {\left (e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (\frac {2 \, b e x + b d - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right ) + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (-\frac {2 \, b e x + b d - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right )\right )} \cosh \left (-\frac {b d - 2 \, a e - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right ) - {\left (e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (\frac {2 \, b e x + b d + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right ) - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (-\frac {2 \, b e x + b d + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right )\right )} \sinh \left (\frac {b d - 2 \, a e + e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right ) - {\left (e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (\frac {2 \, b e x + b d - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right ) - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}} {\rm Ei}\left (-\frac {2 \, b e x + b d - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right )\right )} \sinh \left (-\frac {b d - 2 \, a e - e \sqrt {\frac {b^{2} d^{2} - 4 \, b^{2} c e}{e^{2}}}}{2 \, e}\right )}{2 \, {\left (b d^{2} - 4 \, b c e\right )}} \] Input:

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

Output:

-1/2*((e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2)*Ei(1/2*(2*b*e*x + b*d + e*sqrt((b 
^2*d^2 - 4*b^2*c*e)/e^2))/e) + e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2)*Ei(-1/2*( 
2*b*e*x + b*d + e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2))/e))*cosh(1/2*(b*d - 2*a 
*e + e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2))/e) - (e*sqrt((b^2*d^2 - 4*b^2*c*e) 
/e^2)*Ei(1/2*(2*b*e*x + b*d - e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2))/e) + e*sq 
rt((b^2*d^2 - 4*b^2*c*e)/e^2)*Ei(-1/2*(2*b*e*x + b*d - e*sqrt((b^2*d^2 - 4 
*b^2*c*e)/e^2))/e))*cosh(-1/2*(b*d - 2*a*e - e*sqrt((b^2*d^2 - 4*b^2*c*e)/ 
e^2))/e) - (e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2)*Ei(1/2*(2*b*e*x + b*d + e*sq 
rt((b^2*d^2 - 4*b^2*c*e)/e^2))/e) - e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2)*Ei(- 
1/2*(2*b*e*x + b*d + e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2))/e))*sinh(1/2*(b*d 
- 2*a*e + e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2))/e) - (e*sqrt((b^2*d^2 - 4*b^2 
*c*e)/e^2)*Ei(1/2*(2*b*e*x + b*d - e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2))/e) - 
 e*sqrt((b^2*d^2 - 4*b^2*c*e)/e^2)*Ei(-1/2*(2*b*e*x + b*d - e*sqrt((b^2*d^ 
2 - 4*b^2*c*e)/e^2))/e))*sinh(-1/2*(b*d - 2*a*e - e*sqrt((b^2*d^2 - 4*b^2* 
c*e)/e^2))/e))/(b*d^2 - 4*b*c*e)
 

Sympy [F]

\[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=\int \frac {\cosh {\left (a + b x \right )}}{c + d x + e x^{2}}\, dx \] Input:

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

Output:

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

Maxima [F(-2)]

Exception generated. \[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=\text {Exception raised: ValueError} \] Input:

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

Output:

Exception raised: ValueError >> Computation failed since Maxima requested 
additional constraints; using the 'assume' command before evaluation *may* 
 help (example of legal syntax is 'assume(4*c*e-d^2>0)', see `assume?` for 
 more deta
 

Giac [F]

\[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=\int { \frac {\cosh \left (b x + a\right )}{e x^{2} + d x + c} \,d x } \] Input:

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

Output:

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

Mupad [F(-1)]

Timed out. \[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=\int \frac {\mathrm {cosh}\left (a+b\,x\right )}{e\,x^2+d\,x+c} \,d x \] Input:

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

Output:

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

Reduce [F]

\[ \int \frac {\cosh (a+b x)}{c+d x+e x^2} \, dx=\int \frac {\cosh \left (b x +a \right )}{e \,x^{2}+d x +c}d x \] Input:

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

Output:

int(cosh(a + b*x)/(c + d*x + e*x**2),x)