\(\int \frac {(1-c^2 x^2) (1+4 c^2 x^2)}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx\) [159]

Optimal result
Mathematica [A] (warning: unable to verify)
Rubi [A] (verified)
Maple [C] (verified)
Fricas [A] (verification not implemented)
Sympy [F(-1)]
Maxima [A] (verification not implemented)
Giac [A] (verification not implemented)
Mupad [B] (verification not implemented)
Reduce [B] (verification not implemented)

Optimal result

Integrand size = 39, antiderivative size = 51 \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx=-x \sqrt {-1+c x} \sqrt {1+c x}-x (-1+c x)^{3/2} (1+c x)^{3/2}+\frac {\text {arccosh}(c x)}{c} \] Output:

-x*(c*x-1)^(1/2)*(c*x+1)^(1/2)-x*(c*x-1)^(3/2)*(c*x+1)^(3/2)+arccosh(c*x)/ 
c
 

Mathematica [A] (warning: unable to verify)

Time = 0.18 (sec) , antiderivative size = 50, normalized size of antiderivative = 0.98 \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx=-c^2 x^3 \sqrt {-1+c x} \sqrt {1+c x}+\frac {2 \text {arctanh}\left (\sqrt {\frac {-1+c x}{1+c x}}\right )}{c} \] Input:

Integrate[((1 - c^2*x^2)*(1 + 4*c^2*x^2))/(Sqrt[-1 + c*x]*Sqrt[1 + c*x]),x 
]
 

Output:

-(c^2*x^3*Sqrt[-1 + c*x]*Sqrt[1 + c*x]) + (2*ArcTanh[Sqrt[(-1 + c*x)/(1 + 
c*x)]])/c
 

Rubi [A] (verified)

Time = 0.32 (sec) , antiderivative size = 59, normalized size of antiderivative = 1.16, number of steps used = 5, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.128, Rules used = {2003, 35, 646, 40, 43}

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 {\left (1-c^2 x^2\right ) \left (4 c^2 x^2+1\right )}{\sqrt {c x-1} \sqrt {c x+1}} \, dx\)

\(\Big \downarrow \) 2003

\(\displaystyle \int \frac {(-c x-1) \sqrt {c x-1} \left (4 c^2 x^2+1\right )}{\sqrt {c x+1}}dx\)

\(\Big \downarrow \) 35

\(\displaystyle -\int \sqrt {c x-1} \sqrt {c x+1} \left (4 c^2 x^2+1\right )dx\)

\(\Big \downarrow \) 646

\(\displaystyle -2 \int \sqrt {c x-1} \sqrt {c x+1}dx-x (c x-1)^{3/2} (c x+1)^{3/2}\)

\(\Big \downarrow \) 40

\(\displaystyle -2 \left (\frac {1}{2} x \sqrt {c x-1} \sqrt {c x+1}-\frac {1}{2} \int \frac {1}{\sqrt {c x-1} \sqrt {c x+1}}dx\right )-x (c x-1)^{3/2} (c x+1)^{3/2}\)

\(\Big \downarrow \) 43

\(\displaystyle -2 \left (\frac {1}{2} x \sqrt {c x-1} \sqrt {c x+1}-\frac {\text {arccosh}(c x)}{2 c}\right )-x (c x-1)^{3/2} (c x+1)^{3/2}\)

Input:

Int[((1 - c^2*x^2)*(1 + 4*c^2*x^2))/(Sqrt[-1 + c*x]*Sqrt[1 + c*x]),x]
 

Output:

-(x*(-1 + c*x)^(3/2)*(1 + c*x)^(3/2)) - 2*((x*Sqrt[-1 + c*x]*Sqrt[1 + c*x] 
)/2 - ArcCosh[c*x]/(2*c))
 

Defintions of rubi rules used

rule 35
Int[(u_.)*((a_) + (b_.)*(x_))^(m_.)*((c_) + (d_.)*(x_))^(n_.), x_Symbol] :> 
 Simp[(b/d)^m   Int[u*(c + d*x)^(m + n), x], x] /; FreeQ[{a, b, c, d, m, n} 
, x] && EqQ[b*c - a*d, 0] && IntegerQ[m] &&  !(IntegerQ[n] && SimplerQ[a + 
b*x, c + d*x])
 

rule 40
Int[((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(m_), x_Symbol] :> Simp[x* 
(a + b*x)^m*((c + d*x)^m/(2*m + 1)), x] + Simp[2*a*c*(m/(2*m + 1))   Int[(a 
 + b*x)^(m - 1)*(c + d*x)^(m - 1), x], x] /; FreeQ[{a, b, c, d}, x] && EqQ[ 
b*c + a*d, 0] && IGtQ[m + 1/2, 0]
 

rule 43
Int[1/(Sqrt[(a_) + (b_.)*(x_)]*Sqrt[(c_) + (d_.)*(x_)]), x_Symbol] :> Simp[ 
ArcCosh[b*(x/a)]/(b*Sqrt[d/b]), x] /; FreeQ[{a, b, c, d}, x] && EqQ[b*c + a 
*d, 0] && GtQ[a, 0] && GtQ[d/b, 0]
 

rule 646
Int[((c_) + (d_.)*(x_))^(m_.)*((e_) + (f_.)*(x_))^(n_.)*((a_.) + (b_.)*(x_) 
^2), x_Symbol] :> Simp[b*x*(c + d*x)^(m + 1)*((e + f*x)^(n + 1)/(d*f*(2*m + 
 3))), x] - Simp[(b*c*e - a*d*f*(2*m + 3))/(d*f*(2*m + 3))   Int[(c + d*x)^ 
m*(e + f*x)^n, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && EqQ[m, n] && 
 EqQ[d*e + c*f, 0] &&  !LtQ[m, -1]
 

rule 2003
Int[(u_)*((c_) + (d_.)*(x_))^(n_.)*((a_) + (b_.)*(x_)^2)^(p_.), x_Symbol] : 
> Int[u*(c + d*x)^(n + p)*(a/c + (b/d)*x)^p, x] /; FreeQ[{a, b, c, d, n, p} 
, x] && EqQ[b*c^2 + a*d^2, 0] && (IntegerQ[p] || (GtQ[a, 0] && GtQ[c, 0] && 
  !IntegerQ[n]))
 
Maple [C] (verified)

Result contains higher order function than in optimal. Order 9 vs. order 3.

Time = 0.06 (sec) , antiderivative size = 78, normalized size of antiderivative = 1.53

method result size
default \(-\frac {\sqrt {c x -1}\, \sqrt {c x +1}\, \left (\operatorname {csgn}\left (c \right ) c^{3} x^{3} \sqrt {c^{2} x^{2}-1}-\ln \left (\left (\sqrt {c^{2} x^{2}-1}\, \operatorname {csgn}\left (c \right )+c x \right ) \operatorname {csgn}\left (c \right )\right )\right ) \operatorname {csgn}\left (c \right )}{\sqrt {c^{2} x^{2}-1}\, c}\) \(78\)
risch \(-c^{2} x^{3} \sqrt {c x -1}\, \sqrt {c x +1}+\frac {\ln \left (\frac {c^{2} x}{\sqrt {c^{2}}}+\sqrt {c^{2} x^{2}-1}\right ) \sqrt {\left (c x -1\right ) \left (c x +1\right )}}{\sqrt {c^{2}}\, \sqrt {c x -1}\, \sqrt {c x +1}}\) \(80\)

Input:

int((-c^2*x^2+1)*(4*c^2*x^2+1)/(c*x-1)^(1/2)/(c*x+1)^(1/2),x,method=_RETUR 
NVERBOSE)
 

Output:

-(c*x-1)^(1/2)*(c*x+1)^(1/2)*(csgn(c)*c^3*x^3*(c^2*x^2-1)^(1/2)-ln(((c^2*x 
^2-1)^(1/2)*csgn(c)+c*x)*csgn(c)))*csgn(c)/(c^2*x^2-1)^(1/2)/c
 

Fricas [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 48, normalized size of antiderivative = 0.94 \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx=-\frac {\sqrt {c x + 1} \sqrt {c x - 1} c^{3} x^{3} + \log \left (-c x + \sqrt {c x + 1} \sqrt {c x - 1}\right )}{c} \] Input:

integrate((-c^2*x^2+1)*(4*c^2*x^2+1)/(c*x-1)^(1/2)/(c*x+1)^(1/2),x, algori 
thm="fricas")
 

Output:

-(sqrt(c*x + 1)*sqrt(c*x - 1)*c^3*x^3 + log(-c*x + sqrt(c*x + 1)*sqrt(c*x 
- 1)))/c
 

Sympy [F(-1)]

Timed out. \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx=\text {Timed out} \] Input:

integrate((-c**2*x**2+1)*(4*c**2*x**2+1)/(c*x-1)**(1/2)/(c*x+1)**(1/2),x)
 

Output:

Timed out
 

Maxima [A] (verification not implemented)

Time = 0.03 (sec) , antiderivative size = 55, normalized size of antiderivative = 1.08 \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx=-{\left (c^{2} x^{2} - 1\right )}^{\frac {3}{2}} x - \sqrt {c^{2} x^{2} - 1} x + \frac {\log \left (2 \, c^{2} x + 2 \, \sqrt {c^{2} x^{2} - 1} c\right )}{c} \] Input:

integrate((-c^2*x^2+1)*(4*c^2*x^2+1)/(c*x-1)^(1/2)/(c*x+1)^(1/2),x, algori 
thm="maxima")
 

Output:

-(c^2*x^2 - 1)^(3/2)*x - sqrt(c^2*x^2 - 1)*x + log(2*c^2*x + 2*sqrt(c^2*x^ 
2 - 1)*c)/c
 

Giac [A] (verification not implemented)

Time = 0.13 (sec) , antiderivative size = 62, normalized size of antiderivative = 1.22 \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx=-\frac {{\left ({\left ({\left (c x + 1\right )} {\left (c x - 2\right )} + 3\right )} {\left (c x + 1\right )} - 1\right )} \sqrt {c x + 1} \sqrt {c x - 1} + 2 \, \log \left (\sqrt {c x + 1} - \sqrt {c x - 1}\right )}{c} \] Input:

integrate((-c^2*x^2+1)*(4*c^2*x^2+1)/(c*x-1)^(1/2)/(c*x+1)^(1/2),x, algori 
thm="giac")
 

Output:

-((((c*x + 1)*(c*x - 2) + 3)*(c*x + 1) - 1)*sqrt(c*x + 1)*sqrt(c*x - 1) + 
2*log(sqrt(c*x + 1) - sqrt(c*x - 1)))/c
 

Mupad [B] (verification not implemented)

Time = 68.10 (sec) , antiderivative size = 868, normalized size of antiderivative = 17.02 \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx =\text {Too large to display} \] Input:

int(-((c^2*x^2 - 1)*(4*c^2*x^2 + 1))/((c*x - 1)^(1/2)*(c*x + 1)^(1/2)),x)
 

Output:

((2*((c*x - 1)^(1/2) - 1i))/((c*x + 1)^(1/2) - 1) + (14*((c*x - 1)^(1/2) - 
 1i)^3)/((c*x + 1)^(1/2) - 1)^3 + (14*((c*x - 1)^(1/2) - 1i)^5)/((c*x + 1) 
^(1/2) - 1)^5 + (2*((c*x - 1)^(1/2) - 1i)^7)/((c*x + 1)^(1/2) - 1)^7)/(c - 
 (4*c*((c*x - 1)^(1/2) - 1i)^2)/((c*x + 1)^(1/2) - 1)^2 + (6*c*((c*x - 1)^ 
(1/2) - 1i)^4)/((c*x + 1)^(1/2) - 1)^4 - (4*c*((c*x - 1)^(1/2) - 1i)^6)/(( 
c*x + 1)^(1/2) - 1)^6 + (c*((c*x - 1)^(1/2) - 1i)^8)/((c*x + 1)^(1/2) - 1) 
^8) - ((8*((c*x - 1)^(1/2) - 1i))/((c*x + 1)^(1/2) - 1) + (56*((c*x - 1)^( 
1/2) - 1i)^3)/((c*x + 1)^(1/2) - 1)^3 + (56*((c*x - 1)^(1/2) - 1i)^5)/((c* 
x + 1)^(1/2) - 1)^5 + (8*((c*x - 1)^(1/2) - 1i)^7)/((c*x + 1)^(1/2) - 1)^7 
)/(c - (4*c*((c*x - 1)^(1/2) - 1i)^2)/((c*x + 1)^(1/2) - 1)^2 + (6*c*((c*x 
 - 1)^(1/2) - 1i)^4)/((c*x + 1)^(1/2) - 1)^4 - (4*c*((c*x - 1)^(1/2) - 1i) 
^6)/((c*x + 1)^(1/2) - 1)^6 + (c*((c*x - 1)^(1/2) - 1i)^8)/((c*x + 1)^(1/2 
) - 1)^8) - ((46*((c*x - 1)^(1/2) - 1i)^3)/((c*x + 1)^(1/2) - 1)^3 - (6*(( 
c*x - 1)^(1/2) - 1i))/((c*x + 1)^(1/2) - 1) + (666*((c*x - 1)^(1/2) - 1i)^ 
5)/((c*x + 1)^(1/2) - 1)^5 + (1342*((c*x - 1)^(1/2) - 1i)^7)/((c*x + 1)^(1 
/2) - 1)^7 + (1342*((c*x - 1)^(1/2) - 1i)^9)/((c*x + 1)^(1/2) - 1)^9 + (66 
6*((c*x - 1)^(1/2) - 1i)^11)/((c*x + 1)^(1/2) - 1)^11 + (46*((c*x - 1)^(1/ 
2) - 1i)^13)/((c*x + 1)^(1/2) - 1)^13 - (6*((c*x - 1)^(1/2) - 1i)^15)/((c* 
x + 1)^(1/2) - 1)^15)/(c - (8*c*((c*x - 1)^(1/2) - 1i)^2)/((c*x + 1)^(1/2) 
 - 1)^2 + (28*c*((c*x - 1)^(1/2) - 1i)^4)/((c*x + 1)^(1/2) - 1)^4 - (56...
 

Reduce [B] (verification not implemented)

Time = 0.17 (sec) , antiderivative size = 46, normalized size of antiderivative = 0.90 \[ \int \frac {\left (1-c^2 x^2\right ) \left (1+4 c^2 x^2\right )}{\sqrt {-1+c x} \sqrt {1+c x}} \, dx=\frac {-\sqrt {c x +1}\, \sqrt {c x -1}\, c^{3} x^{3}+2 \,\mathrm {log}\left (\frac {\sqrt {c x -1}+\sqrt {c x +1}}{\sqrt {2}}\right )}{c} \] Input:

int((-c^2*x^2+1)*(4*c^2*x^2+1)/(c*x-1)^(1/2)/(c*x+1)^(1/2),x)
 

Output:

( - sqrt(c*x + 1)*sqrt(c*x - 1)*c**3*x**3 + 2*log((sqrt(c*x - 1) + sqrt(c* 
x + 1))/sqrt(2)))/c