Integrand size = 26, antiderivative size = 101 \[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx=\frac {A \arctan \left (\frac {\sqrt {c d-a f} x}{\sqrt {a} \sqrt {d+f x^2}}\right )}{\sqrt {a} \sqrt {c d-a f}}-\frac {B \text {arctanh}\left (\frac {\sqrt {c} \sqrt {d+f x^2}}{\sqrt {c d-a f}}\right )}{\sqrt {c} \sqrt {c d-a f}} \] Output:
A*arctan((-a*f+c*d)^(1/2)*x/a^(1/2)/(f*x^2+d)^(1/2))/a^(1/2)/(-a*f+c*d)^(1 /2)-B*arctanh(c^(1/2)*(f*x^2+d)^(1/2)/(-a*f+c*d)^(1/2))/c^(1/2)/(-a*f+c*d) ^(1/2)
Leaf count is larger than twice the leaf count of optimal. \(349\) vs. \(2(101)=202\).
Time = 2.35 (sec) , antiderivative size = 349, normalized size of antiderivative = 3.46 \[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx=\frac {\sqrt {a} B \left (\left (\sqrt {a} \sqrt {f}+\sqrt {-c d+a f}\right ) \sqrt {-c d+2 a f-2 \sqrt {a} \sqrt {f} \sqrt {-c d+a f}} \arctan \left (\frac {\sqrt {c} \left (\sqrt {f} x-\sqrt {d+f x^2}\right )}{\sqrt {-c d+2 a f-2 \sqrt {a} \sqrt {f} \sqrt {-c d+a f}}}\right )+\left (-\sqrt {a} \sqrt {f}+\sqrt {-c d+a f}\right ) \sqrt {-c d+2 a f+2 \sqrt {a} \sqrt {f} \sqrt {-c d+a f}} \arctan \left (\frac {\sqrt {c} \left (\sqrt {f} x-\sqrt {d+f x^2}\right )}{\sqrt {-c d+2 a f+2 \sqrt {a} \sqrt {f} \sqrt {-c d+a f}}}\right )\right )+A c^{3/2} d \text {arctanh}\left (\frac {a \sqrt {f}+c x \left (\sqrt {f} x-\sqrt {d+f x^2}\right )}{\sqrt {a} \sqrt {-c d+a f}}\right )}{\sqrt {a} c^{3/2} d \sqrt {-c d+a f}} \] Input:
Integrate[(A + B*x)/((a + c*x^2)*Sqrt[d + f*x^2]),x]
Output:
(Sqrt[a]*B*((Sqrt[a]*Sqrt[f] + Sqrt[-(c*d) + a*f])*Sqrt[-(c*d) + 2*a*f - 2 *Sqrt[a]*Sqrt[f]*Sqrt[-(c*d) + a*f]]*ArcTan[(Sqrt[c]*(Sqrt[f]*x - Sqrt[d + f*x^2]))/Sqrt[-(c*d) + 2*a*f - 2*Sqrt[a]*Sqrt[f]*Sqrt[-(c*d) + a*f]]] + ( -(Sqrt[a]*Sqrt[f]) + Sqrt[-(c*d) + a*f])*Sqrt[-(c*d) + 2*a*f + 2*Sqrt[a]*S qrt[f]*Sqrt[-(c*d) + a*f]]*ArcTan[(Sqrt[c]*(Sqrt[f]*x - Sqrt[d + f*x^2]))/ Sqrt[-(c*d) + 2*a*f + 2*Sqrt[a]*Sqrt[f]*Sqrt[-(c*d) + a*f]]]) + A*c^(3/2)* d*ArcTanh[(a*Sqrt[f] + c*x*(Sqrt[f]*x - Sqrt[d + f*x^2]))/(Sqrt[a]*Sqrt[-( c*d) + a*f])])/(Sqrt[a]*c^(3/2)*d*Sqrt[-(c*d) + a*f])
Time = 0.27 (sec) , antiderivative size = 101, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.231, Rules used = {1343, 291, 218, 353, 73, 221}
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}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx\) |
\(\Big \downarrow \) 1343 |
\(\displaystyle A \int \frac {1}{\left (c x^2+a\right ) \sqrt {f x^2+d}}dx+B \int \frac {x}{\left (c x^2+a\right ) \sqrt {f x^2+d}}dx\) |
\(\Big \downarrow \) 291 |
\(\displaystyle A \int \frac {1}{a-\frac {(a f-c d) x^2}{f x^2+d}}d\frac {x}{\sqrt {f x^2+d}}+B \int \frac {x}{\left (c x^2+a\right ) \sqrt {f x^2+d}}dx\) |
\(\Big \downarrow \) 218 |
\(\displaystyle B \int \frac {x}{\left (c x^2+a\right ) \sqrt {f x^2+d}}dx+\frac {A \arctan \left (\frac {x \sqrt {c d-a f}}{\sqrt {a} \sqrt {d+f x^2}}\right )}{\sqrt {a} \sqrt {c d-a f}}\) |
\(\Big \downarrow \) 353 |
\(\displaystyle \frac {1}{2} B \int \frac {1}{\left (c x^2+a\right ) \sqrt {f x^2+d}}dx^2+\frac {A \arctan \left (\frac {x \sqrt {c d-a f}}{\sqrt {a} \sqrt {d+f x^2}}\right )}{\sqrt {a} \sqrt {c d-a f}}\) |
\(\Big \downarrow \) 73 |
\(\displaystyle \frac {B \int \frac {1}{\frac {c x^4}{f}+a-\frac {c d}{f}}d\sqrt {f x^2+d}}{f}+\frac {A \arctan \left (\frac {x \sqrt {c d-a f}}{\sqrt {a} \sqrt {d+f x^2}}\right )}{\sqrt {a} \sqrt {c d-a f}}\) |
\(\Big \downarrow \) 221 |
\(\displaystyle \frac {A \arctan \left (\frac {x \sqrt {c d-a f}}{\sqrt {a} \sqrt {d+f x^2}}\right )}{\sqrt {a} \sqrt {c d-a f}}-\frac {B \text {arctanh}\left (\frac {\sqrt {c} \sqrt {d+f x^2}}{\sqrt {c d-a f}}\right )}{\sqrt {c} \sqrt {c d-a f}}\) |
Input:
Int[(A + B*x)/((a + c*x^2)*Sqrt[d + f*x^2]),x]
Output:
(A*ArcTan[(Sqrt[c*d - a*f]*x)/(Sqrt[a]*Sqrt[d + f*x^2])])/(Sqrt[a]*Sqrt[c* d - a*f]) - (B*ArcTanh[(Sqrt[c]*Sqrt[d + f*x^2])/Sqrt[c*d - a*f]])/(Sqrt[c ]*Sqrt[c*d - a*f])
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[ {p = Denominator[m]}, Simp[p/b Subst[Int[x^(p*(m + 1) - 1)*(c - a*(d/b) + d*(x^p/b))^n, x], x, (a + b*x)^(1/p)], x]] /; FreeQ[{a, b, c, d}, x] && Lt Q[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntL inearQ[a, b, c, d, m, n, x]
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/R t[a/b, 2]], x] /; FreeQ[{a, b}, x] && PosQ[a/b]
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[-a/b, 2]/a)*ArcTanh[x /Rt[-a/b, 2]], x] /; FreeQ[{a, b}, x] && NegQ[a/b]
Int[1/(Sqrt[(a_) + (b_.)*(x_)^2]*((c_) + (d_.)*(x_)^2)), x_Symbol] :> Subst [Int[1/(c - (b*c - a*d)*x^2), x], x, x/Sqrt[a + b*x^2]] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0]
Int[(x_)*((a_) + (b_.)*(x_)^2)^(p_.)*((c_) + (d_.)*(x_)^2)^(q_.), x_Symbol] :> Simp[1/2 Subst[Int[(a + b*x)^p*(c + d*x)^q, x], x, x^2], x] /; FreeQ[ {a, b, c, d, p, q}, x] && NeQ[b*c - a*d, 0]
Int[((g_) + (h_.)*(x_))*((a_) + (c_.)*(x_)^2)^(p_)*((d_) + (f_.)*(x_)^2)^(q _), x_Symbol] :> Simp[g Int[(a + c*x^2)^p*(d + f*x^2)^q, x], x] + Simp[h Int[x*(a + c*x^2)^p*(d + f*x^2)^q, x], x] /; FreeQ[{a, c, d, f, g, h, p, q}, x]
Leaf count of result is larger than twice the leaf count of optimal. \(336\) vs. \(2(81)=162\).
Time = 2.03 (sec) , antiderivative size = 337, normalized size of antiderivative = 3.34
method | result | size |
default | \(\frac {\left (A c -B \sqrt {-a c}\right ) \ln \left (\frac {-\frac {2 \left (a f -c d \right )}{c}-\frac {2 f \sqrt {-a c}\, \left (x +\frac {\sqrt {-a c}}{c}\right )}{c}+2 \sqrt {-\frac {a f -c d}{c}}\, \sqrt {f \left (x +\frac {\sqrt {-a c}}{c}\right )^{2}-\frac {2 f \sqrt {-a c}\, \left (x +\frac {\sqrt {-a c}}{c}\right )}{c}-\frac {a f -c d}{c}}}{x +\frac {\sqrt {-a c}}{c}}\right )}{2 \sqrt {-a c}\, c \sqrt {-\frac {a f -c d}{c}}}-\frac {\left (A c +B \sqrt {-a c}\right ) \ln \left (\frac {-\frac {2 \left (a f -c d \right )}{c}+\frac {2 f \sqrt {-a c}\, \left (x -\frac {\sqrt {-a c}}{c}\right )}{c}+2 \sqrt {-\frac {a f -c d}{c}}\, \sqrt {f \left (x -\frac {\sqrt {-a c}}{c}\right )^{2}+\frac {2 f \sqrt {-a c}\, \left (x -\frac {\sqrt {-a c}}{c}\right )}{c}-\frac {a f -c d}{c}}}{x -\frac {\sqrt {-a c}}{c}}\right )}{2 \sqrt {-a c}\, c \sqrt {-\frac {a f -c d}{c}}}\) | \(337\) |
Input:
int((B*x+A)/(c*x^2+a)/(f*x^2+d)^(1/2),x,method=_RETURNVERBOSE)
Output:
1/2*(A*c-B*(-a*c)^(1/2))/(-a*c)^(1/2)/c/(-(a*f-c*d)/c)^(1/2)*ln((-2*(a*f-c *d)/c-2*f*(-a*c)^(1/2)/c*(x+(-a*c)^(1/2)/c)+2*(-(a*f-c*d)/c)^(1/2)*(f*(x+( -a*c)^(1/2)/c)^2-2*f*(-a*c)^(1/2)/c*(x+(-a*c)^(1/2)/c)-(a*f-c*d)/c)^(1/2)) /(x+(-a*c)^(1/2)/c))-1/2*(A*c+B*(-a*c)^(1/2))/(-a*c)^(1/2)/c/(-(a*f-c*d)/c )^(1/2)*ln((-2*(a*f-c*d)/c+2*f*(-a*c)^(1/2)/c*(x-(-a*c)^(1/2)/c)+2*(-(a*f- c*d)/c)^(1/2)*(f*(x-(-a*c)^(1/2)/c)^2+2*f*(-a*c)^(1/2)/c*(x-(-a*c)^(1/2)/c )-(a*f-c*d)/c)^(1/2))/(x-(-a*c)^(1/2)/c))
Leaf count of result is larger than twice the leaf count of optimal. 1515 vs. \(2 (81) = 162\).
Time = 0.15 (sec) , antiderivative size = 1515, normalized size of antiderivative = 15.00 \[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx=\text {Too large to display} \] Input:
integrate((B*x+A)/(c*x^2+a)/(f*x^2+d)^(1/2),x, algorithm="fricas")
Output:
-1/4*sqrt((B^2*a - A^2*c + 2*(a*c^2*d - a^2*c*f)*sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2*d*f + a^3*c*f^2)))/(a*c^2*d - a^2*c*f))*log(((A*B^3*a + A^3*B* c)*f*x + (A^2*B*c^2*d - A^2*B*a*c*f + (B*a*c^3*d^2 - 2*B*a^2*c^2*d*f + B*a ^3*c*f^2)*sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2*d*f + a^3*c*f^2)))*sqrt(f*x ^2 + d)*sqrt((B^2*a - A^2*c + 2*(a*c^2*d - a^2*c*f)*sqrt(-A^2*B^2/(a*c^3*d ^2 - 2*a^2*c^2*d*f + a^3*c*f^2)))/(a*c^2*d - a^2*c*f)) + sqrt(-A^2*B^2/(a* c^3*d^2 - 2*a^2*c^2*d*f + a^3*c*f^2))*((B^2*a*c^2 + A^2*c^3)*d^2 - (B^2*a^ 2*c + A^2*a*c^2)*d*f))/x) + 1/4*sqrt((B^2*a - A^2*c + 2*(a*c^2*d - a^2*c*f )*sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2*d*f + a^3*c*f^2)))/(a*c^2*d - a^2*c *f))*log(((A*B^3*a + A^3*B*c)*f*x - (A^2*B*c^2*d - A^2*B*a*c*f + (B*a*c^3* d^2 - 2*B*a^2*c^2*d*f + B*a^3*c*f^2)*sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2* d*f + a^3*c*f^2)))*sqrt(f*x^2 + d)*sqrt((B^2*a - A^2*c + 2*(a*c^2*d - a^2* c*f)*sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2*d*f + a^3*c*f^2)))/(a*c^2*d - a^ 2*c*f)) + sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2*d*f + a^3*c*f^2))*((B^2*a*c ^2 + A^2*c^3)*d^2 - (B^2*a^2*c + A^2*a*c^2)*d*f))/x) - 1/4*sqrt((B^2*a - A ^2*c - 2*(a*c^2*d - a^2*c*f)*sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2*d*f + a^ 3*c*f^2)))/(a*c^2*d - a^2*c*f))*log(((A*B^3*a + A^3*B*c)*f*x + (A^2*B*c^2* d - A^2*B*a*c*f - (B*a*c^3*d^2 - 2*B*a^2*c^2*d*f + B*a^3*c*f^2)*sqrt(-A^2* B^2/(a*c^3*d^2 - 2*a^2*c^2*d*f + a^3*c*f^2)))*sqrt(f*x^2 + d)*sqrt((B^2*a - A^2*c - 2*(a*c^2*d - a^2*c*f)*sqrt(-A^2*B^2/(a*c^3*d^2 - 2*a^2*c^2*d*...
\[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx=\int \frac {A + B x}{\left (a + c x^{2}\right ) \sqrt {d + f x^{2}}}\, dx \] Input:
integrate((B*x+A)/(c*x**2+a)/(f*x**2+d)**(1/2),x)
Output:
Integral((A + B*x)/((a + c*x**2)*sqrt(d + f*x**2)), x)
\[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx=\int { \frac {B x + A}{{\left (c x^{2} + a\right )} \sqrt {f x^{2} + d}} \,d x } \] Input:
integrate((B*x+A)/(c*x^2+a)/(f*x^2+d)^(1/2),x, algorithm="maxima")
Output:
integrate((B*x + A)/((c*x^2 + a)*sqrt(f*x^2 + d)), x)
Timed out. \[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx=\text {Timed out} \] Input:
integrate((B*x+A)/(c*x^2+a)/(f*x^2+d)^(1/2),x, algorithm="giac")
Output:
Timed out
Timed out. \[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx=\left \{\begin {array}{cl} \frac {B\,\mathrm {atan}\left (\frac {c\,\sqrt {f\,x^2+d}}{\sqrt {a\,c\,f-c^2\,d}}\right )}{\sqrt {a\,c\,f-c^2\,d}}+\frac {A\,\mathrm {atan}\left (\frac {x\,\sqrt {c\,d-a\,f}}{\sqrt {a}\,\sqrt {f\,x^2+d}}\right )}{\sqrt {-a\,\left (a\,f-c\,d\right )}} & \text {\ if\ \ }0<c\,d-a\,f\\ \frac {A\,\ln \left (\frac {\sqrt {a\,\left (f\,x^2+d\right )}+x\,\sqrt {a\,f-c\,d}}{\sqrt {a\,\left (f\,x^2+d\right )}-x\,\sqrt {a\,f-c\,d}}\right )}{2\,\sqrt {a\,\left (a\,f-c\,d\right )}}+\frac {B\,\mathrm {atan}\left (\frac {c\,\sqrt {f\,x^2+d}}{\sqrt {a\,c\,f-c^2\,d}}\right )}{\sqrt {a\,c\,f-c^2\,d}} & \text {\ if\ \ }c\,d-a\,f<0\\ \int \frac {A+B\,x}{\left (c\,x^2+a\right )\,\sqrt {f\,x^2+d}} \,d x & \text {\ if\ \ }c\,d-a\,f\notin \mathbb {R}\vee a\,f=c\,d \end {array}\right . \] Input:
int((A + B*x)/((a + c*x^2)*(d + f*x^2)^(1/2)),x)
Output:
piecewise(0 < - a*f + c*d, (B*atan((c*(d + f*x^2)^(1/2))/(- c^2*d + a*c*f) ^(1/2)))/(- c^2*d + a*c*f)^(1/2) + (A*atan((x*(- a*f + c*d)^(1/2))/(a^(1/2 )*(d + f*x^2)^(1/2))))/(-a*(a*f - c*d))^(1/2), - a*f + c*d < 0, (A*log(((a *(d + f*x^2))^(1/2) + x*(a*f - c*d)^(1/2))/((a*(d + f*x^2))^(1/2) - x*(a*f - c*d)^(1/2))))/(2*(a*(a*f - c*d))^(1/2)) + (B*atan((c*(d + f*x^2)^(1/2)) /(- c^2*d + a*c*f)^(1/2)))/(- c^2*d + a*c*f)^(1/2), ~in(- a*f + c*d, 'real ') | a*f == c*d, int((A + B*x)/((a + c*x^2)*(d + f*x^2)^(1/2)), x))
Time = 0.17 (sec) , antiderivative size = 921, normalized size of antiderivative = 9.12 \[ \int \frac {A+B x}{\left (a+c x^2\right ) \sqrt {d+f x^2}} \, dx =\text {Too large to display} \] Input:
int((B*x+A)/(c*x^2+a)/(f*x^2+d)^(1/2),x)
Output:
(2*sqrt(f)*sqrt(c)*sqrt(a)*sqrt(2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) + 2*a*f - c*d)*sqrt(a*f - c*d)*atan((sqrt(d + f*x**2)*c + sqrt(f)*c*x)/(sqrt(c)*sq rt(2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) + 2*a*f - c*d)))*b - 2*sqrt(c)*sqrt(2 *sqrt(f)*sqrt(a)*sqrt(a*f - c*d) + 2*a*f - c*d)*atan((sqrt(d + f*x**2)*c + sqrt(f)*c*x)/(sqrt(c)*sqrt(2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) + 2*a*f - c* d)))*a*b*f + 2*sqrt(c)*sqrt(2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) + 2*a*f - c* d)*atan((sqrt(d + f*x**2)*c + sqrt(f)*c*x)/(sqrt(c)*sqrt(2*sqrt(f)*sqrt(a) *sqrt(a*f - c*d) + 2*a*f - c*d)))*b*c*d + sqrt(f)*sqrt(c)*sqrt(a)*sqrt(2*s qrt(f)*sqrt(a)*sqrt(a*f - c*d) - 2*a*f + c*d)*sqrt(a*f - c*d)*log( - sqrt( 2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) - 2*a*f + c*d) + sqrt(c)*sqrt(d + f*x**2 ) + sqrt(f)*sqrt(c)*x)*b - sqrt(f)*sqrt(c)*sqrt(a)*sqrt(2*sqrt(f)*sqrt(a)* sqrt(a*f - c*d) - 2*a*f + c*d)*sqrt(a*f - c*d)*log(sqrt(2*sqrt(f)*sqrt(a)* sqrt(a*f - c*d) - 2*a*f + c*d) + sqrt(c)*sqrt(d + f*x**2) + sqrt(f)*sqrt(c )*x)*b + sqrt(a)*sqrt(a*f - c*d)*log( - sqrt(2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) - 2*a*f + c*d) + sqrt(c)*sqrt(d + f*x**2) + sqrt(f)*sqrt(c)*x)*c**2*d + sqrt(a)*sqrt(a*f - c*d)*log(sqrt(2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) - 2* a*f + c*d) + sqrt(c)*sqrt(d + f*x**2) + sqrt(f)*sqrt(c)*x)*c**2*d - sqrt(a )*sqrt(a*f - c*d)*log(2*sqrt(f)*sqrt(a)*sqrt(a*f - c*d) + 2*sqrt(f)*sqrt(d + f*x**2)*c*x + 2*a*f + 2*c*f*x**2)*c**2*d + sqrt(c)*sqrt(2*sqrt(f)*sqrt( a)*sqrt(a*f - c*d) - 2*a*f + c*d)*log( - sqrt(2*sqrt(f)*sqrt(a)*sqrt(a*...