Integrand size = 30, antiderivative size = 63 \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=-\frac {B \sqrt {1-d^2 x^2}}{d^2}-\frac {C x \sqrt {1-d^2 x^2}}{2 d^2}+\frac {\left (C+2 A d^2\right ) \arcsin (d x)}{2 d^3} \] Output:
-B*(-d^2*x^2+1)^(1/2)/d^2-1/2*C*x*(-d^2*x^2+1)^(1/2)/d^2+1/2*(2*A*d^2+C)*a rcsin(d*x)/d^3
Time = 0.24 (sec) , antiderivative size = 64, normalized size of antiderivative = 1.02 \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=\frac {(-2 B-C x) \sqrt {1-d^2 x^2}}{2 d^2}+\frac {\left (C+2 A d^2\right ) \arctan \left (\frac {d x}{-1+\sqrt {1-d^2 x^2}}\right )}{d^3} \] Input:
Integrate[(A + B*x + C*x^2)/(Sqrt[1 - d*x]*Sqrt[1 + d*x]),x]
Output:
((-2*B - C*x)*Sqrt[1 - d^2*x^2])/(2*d^2) + ((C + 2*A*d^2)*ArcTan[(d*x)/(-1 + Sqrt[1 - d^2*x^2])])/d^3
Time = 0.25 (sec) , antiderivative size = 65, normalized size of antiderivative = 1.03, number of steps used = 5, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {1188, 2346, 25, 455, 223}
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 {A+B x+C x^2}{\sqrt {1-d x} \sqrt {d x+1}} \, dx\) |
\(\Big \downarrow \) 1188 |
\(\displaystyle \int \frac {A+B x+C x^2}{\sqrt {1-d^2 x^2}}dx\) |
\(\Big \downarrow \) 2346 |
\(\displaystyle -\frac {\int -\frac {2 A d^2+2 B x d^2+C}{\sqrt {1-d^2 x^2}}dx}{2 d^2}-\frac {C x \sqrt {1-d^2 x^2}}{2 d^2}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \frac {\int \frac {2 A d^2+2 B x d^2+C}{\sqrt {1-d^2 x^2}}dx}{2 d^2}-\frac {C x \sqrt {1-d^2 x^2}}{2 d^2}\) |
\(\Big \downarrow \) 455 |
\(\displaystyle \frac {\left (2 A d^2+C\right ) \int \frac {1}{\sqrt {1-d^2 x^2}}dx-2 B \sqrt {1-d^2 x^2}}{2 d^2}-\frac {C x \sqrt {1-d^2 x^2}}{2 d^2}\) |
\(\Big \downarrow \) 223 |
\(\displaystyle \frac {\frac {\left (2 A d^2+C\right ) \arcsin (d x)}{d}-2 B \sqrt {1-d^2 x^2}}{2 d^2}-\frac {C x \sqrt {1-d^2 x^2}}{2 d^2}\) |
Input:
Int[(A + B*x + C*x^2)/(Sqrt[1 - d*x]*Sqrt[1 + d*x]),x]
Output:
-1/2*(C*x*Sqrt[1 - d^2*x^2])/d^2 + (-2*B*Sqrt[1 - d^2*x^2] + ((C + 2*A*d^2 )*ArcSin[d*x])/d)/(2*d^2)
Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Simp[ArcSin[Rt[-b, 2]*(x/Sqrt [a])]/Rt[-b, 2], x] /; FreeQ[{a, b}, x] && GtQ[a, 0] && NegQ[b]
Int[((c_) + (d_.)*(x_))*((a_) + (b_.)*(x_)^2)^(p_.), x_Symbol] :> Simp[d*(( a + b*x^2)^(p + 1)/(2*b*(p + 1))), x] + Simp[c Int[(a + b*x^2)^p, x], x] /; FreeQ[{a, b, c, d, p}, x] && !LeQ[p, -1]
Int[((d_) + (e_.)*(x_))^(m_.)*((f_) + (g_.)*(x_))^(n_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[(d*f + e*g*x^2)^m*(a + b*x + c*x^2 )^p, x] /; FreeQ[{a, b, c, d, e, f, g, m, n, p}, x] && EqQ[m, n] && EqQ[e*f + d*g, 0] && (IntegerQ[m] || (GtQ[d, 0] && GtQ[f, 0]))
Int[(Pq_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> With[{q = Expon[Pq, x], e = Coeff[Pq, x, Expon[Pq, x]]}, Simp[e*x^(q - 1)*((a + b*x^2)^(p + 1)/(b*( q + 2*p + 1))), x] + Simp[1/(b*(q + 2*p + 1)) Int[(a + b*x^2)^p*ExpandToS um[b*(q + 2*p + 1)*Pq - a*e*(q - 1)*x^(q - 2) - b*e*(q + 2*p + 1)*x^q, x], x], x]] /; FreeQ[{a, b, p}, x] && PolyQ[Pq, x] && !LeQ[p, -1]
Result contains higher order function than in optimal. Order 9 vs. order 3.
Time = 0.70 (sec) , antiderivative size = 117, normalized size of antiderivative = 1.86
method | result | size |
default | \(\frac {\sqrt {-x d +1}\, \sqrt {x d +1}\, \left (2 A \arctan \left (\frac {\operatorname {csgn}\left (d \right ) d x}{\sqrt {-d^{2} x^{2}+1}}\right ) d^{2}-C \sqrt {-d^{2} x^{2}+1}\, \operatorname {csgn}\left (d \right ) d x -2 B \sqrt {-d^{2} x^{2}+1}\, \operatorname {csgn}\left (d \right ) d +C \arctan \left (\frac {\operatorname {csgn}\left (d \right ) d x}{\sqrt {-d^{2} x^{2}+1}}\right )\right ) \operatorname {csgn}\left (d \right )}{2 d^{3} \sqrt {-d^{2} x^{2}+1}}\) | \(117\) |
risch | \(\frac {\left (C x +2 B \right ) \sqrt {x d +1}\, \left (x d -1\right ) \sqrt {\left (-x d +1\right ) \left (x d +1\right )}}{2 d^{2} \sqrt {-\left (x d +1\right ) \left (x d -1\right )}\, \sqrt {-x d +1}}+\frac {\left (2 d^{2} A +C \right ) \arctan \left (\frac {\sqrt {d^{2}}\, x}{\sqrt {-d^{2} x^{2}+1}}\right ) \sqrt {\left (-x d +1\right ) \left (x d +1\right )}}{2 d^{2} \sqrt {d^{2}}\, \sqrt {-x d +1}\, \sqrt {x d +1}}\) | \(129\) |
Input:
int((C*x^2+B*x+A)/(-d*x+1)^(1/2)/(d*x+1)^(1/2),x,method=_RETURNVERBOSE)
Output:
1/2*(-d*x+1)^(1/2)*(d*x+1)^(1/2)/d^3*(2*A*arctan(csgn(d)*d*x/(-d^2*x^2+1)^ (1/2))*d^2-C*(-d^2*x^2+1)^(1/2)*csgn(d)*d*x-2*B*(-d^2*x^2+1)^(1/2)*csgn(d) *d+C*arctan(csgn(d)*d*x/(-d^2*x^2+1)^(1/2)))/(-d^2*x^2+1)^(1/2)*csgn(d)
Time = 0.08 (sec) , antiderivative size = 67, normalized size of antiderivative = 1.06 \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=-\frac {{\left (C d x + 2 \, B d\right )} \sqrt {d x + 1} \sqrt {-d x + 1} + 2 \, {\left (2 \, A d^{2} + C\right )} \arctan \left (\frac {\sqrt {d x + 1} \sqrt {-d x + 1} - 1}{d x}\right )}{2 \, d^{3}} \] Input:
integrate((C*x^2+B*x+A)/(-d*x+1)^(1/2)/(d*x+1)^(1/2),x, algorithm="fricas" )
Output:
-1/2*((C*d*x + 2*B*d)*sqrt(d*x + 1)*sqrt(-d*x + 1) + 2*(2*A*d^2 + C)*arcta n((sqrt(d*x + 1)*sqrt(-d*x + 1) - 1)/(d*x)))/d^3
Timed out. \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=\text {Timed out} \] Input:
integrate((C*x**2+B*x+A)/(-d*x+1)**(1/2)/(d*x+1)**(1/2),x)
Output:
Timed out
Time = 0.11 (sec) , antiderivative size = 57, normalized size of antiderivative = 0.90 \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=\frac {A \arcsin \left (d x\right )}{d} - \frac {\sqrt {-d^{2} x^{2} + 1} C x}{2 \, d^{2}} - \frac {\sqrt {-d^{2} x^{2} + 1} B}{d^{2}} + \frac {C \arcsin \left (d x\right )}{2 \, d^{3}} \] Input:
integrate((C*x^2+B*x+A)/(-d*x+1)^(1/2)/(d*x+1)^(1/2),x, algorithm="maxima" )
Output:
A*arcsin(d*x)/d - 1/2*sqrt(-d^2*x^2 + 1)*C*x/d^2 - sqrt(-d^2*x^2 + 1)*B/d^ 2 + 1/2*C*arcsin(d*x)/d^3
Time = 0.13 (sec) , antiderivative size = 60, normalized size of antiderivative = 0.95 \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=-\frac {{\left ({\left (d x + 1\right )} C + 2 \, B d - C\right )} \sqrt {d x + 1} \sqrt {-d x + 1} - 2 \, {\left (2 \, A d^{2} + C\right )} \arcsin \left (\frac {1}{2} \, \sqrt {2} \sqrt {d x + 1}\right )}{2 \, d^{3}} \] Input:
integrate((C*x^2+B*x+A)/(-d*x+1)^(1/2)/(d*x+1)^(1/2),x, algorithm="giac")
Output:
-1/2*(((d*x + 1)*C + 2*B*d - C)*sqrt(d*x + 1)*sqrt(-d*x + 1) - 2*(2*A*d^2 + C)*arcsin(1/2*sqrt(2)*sqrt(d*x + 1)))/d^3
Time = 7.10 (sec) , antiderivative size = 232, normalized size of antiderivative = 3.68 \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=-\frac {\frac {14\,C\,{\left (\sqrt {1-d\,x}-1\right )}^3}{{\left (\sqrt {d\,x+1}-1\right )}^3}-\frac {14\,C\,{\left (\sqrt {1-d\,x}-1\right )}^5}{{\left (\sqrt {d\,x+1}-1\right )}^5}+\frac {2\,C\,{\left (\sqrt {1-d\,x}-1\right )}^7}{{\left (\sqrt {d\,x+1}-1\right )}^7}-\frac {2\,C\,\left (\sqrt {1-d\,x}-1\right )}{\sqrt {d\,x+1}-1}}{d^3\,{\left (\frac {{\left (\sqrt {1-d\,x}-1\right )}^2}{{\left (\sqrt {d\,x+1}-1\right )}^2}+1\right )}^4}-\frac {4\,A\,\mathrm {atan}\left (\frac {d\,\left (\sqrt {1-d\,x}-1\right )}{\left (\sqrt {d\,x+1}-1\right )\,\sqrt {d^2}}\right )}{\sqrt {d^2}}-\frac {2\,C\,\mathrm {atan}\left (\frac {\sqrt {1-d\,x}-1}{\sqrt {d\,x+1}-1}\right )}{d^3}-\frac {\sqrt {1-d\,x}\,\left (\frac {B}{d^2}+\frac {B\,x}{d}\right )}{\sqrt {d\,x+1}} \] Input:
int((A + B*x + C*x^2)/((1 - d*x)^(1/2)*(d*x + 1)^(1/2)),x)
Output:
- ((14*C*((1 - d*x)^(1/2) - 1)^3)/((d*x + 1)^(1/2) - 1)^3 - (14*C*((1 - d* x)^(1/2) - 1)^5)/((d*x + 1)^(1/2) - 1)^5 + (2*C*((1 - d*x)^(1/2) - 1)^7)/( (d*x + 1)^(1/2) - 1)^7 - (2*C*((1 - d*x)^(1/2) - 1))/((d*x + 1)^(1/2) - 1) )/(d^3*(((1 - d*x)^(1/2) - 1)^2/((d*x + 1)^(1/2) - 1)^2 + 1)^4) - (4*A*ata n((d*((1 - d*x)^(1/2) - 1))/(((d*x + 1)^(1/2) - 1)*(d^2)^(1/2))))/(d^2)^(1 /2) - (2*C*atan(((1 - d*x)^(1/2) - 1)/((d*x + 1)^(1/2) - 1)))/d^3 - ((1 - d*x)^(1/2)*(B/d^2 + (B*x)/d))/(d*x + 1)^(1/2)
Time = 0.15 (sec) , antiderivative size = 76, normalized size of antiderivative = 1.21 \[ \int \frac {A+B x+C x^2}{\sqrt {1-d x} \sqrt {1+d x}} \, dx=\frac {-4 \mathit {asin} \left (\frac {\sqrt {-d x +1}}{\sqrt {2}}\right ) a \,d^{2}-2 \mathit {asin} \left (\frac {\sqrt {-d x +1}}{\sqrt {2}}\right ) c -2 \sqrt {d x +1}\, \sqrt {-d x +1}\, b d -\sqrt {d x +1}\, \sqrt {-d x +1}\, c d x}{2 d^{3}} \] Input:
int((C*x^2+B*x+A)/(-d*x+1)^(1/2)/(d*x+1)^(1/2),x)
Output:
( - 4*asin(sqrt( - d*x + 1)/sqrt(2))*a*d**2 - 2*asin(sqrt( - d*x + 1)/sqrt (2))*c - 2*sqrt(d*x + 1)*sqrt( - d*x + 1)*b*d - sqrt(d*x + 1)*sqrt( - d*x + 1)*c*d*x)/(2*d**3)