Integrand size = 45, antiderivative size = 119 \[ \int \frac {\left (-q+p x^2\right ) \sqrt {q^2+p^2 x^4} \left (b x^3+a \left (q+p x^2\right )^3\right )}{x^6} \, dx=\frac {\sqrt {q^2+p^2 x^4} \left (6 a q^4+20 a p q^3 x^2+15 b q x^3+12 a p^2 q^2 x^4+15 b p x^5+20 a p^3 q x^6+6 a p^4 x^8\right )}{30 x^5}+b p q \log (x)-b p q \log \left (q+p x^2+\sqrt {q^2+p^2 x^4}\right ) \]
1/30*(p^2*x^4+q^2)^(1/2)*(6*a*p^4*x^8+20*a*p^3*q*x^6+12*a*p^2*q^2*x^4+20*a *p*q^3*x^2+15*b*p*x^5+6*a*q^4+15*b*q*x^3)/x^5+b*p*q*ln(x)-b*p*q*ln(q+p*x^2 +(p^2*x^4+q^2)^(1/2))
Time = 2.35 (sec) , antiderivative size = 119, normalized size of antiderivative = 1.00 \[ \int \frac {\left (-q+p x^2\right ) \sqrt {q^2+p^2 x^4} \left (b x^3+a \left (q+p x^2\right )^3\right )}{x^6} \, dx=\frac {\sqrt {q^2+p^2 x^4} \left (6 a q^4+20 a p q^3 x^2+15 b q x^3+12 a p^2 q^2 x^4+15 b p x^5+20 a p^3 q x^6+6 a p^4 x^8\right )}{30 x^5}+b p q \log (x)-b p q \log \left (q+p x^2+\sqrt {q^2+p^2 x^4}\right ) \]
(Sqrt[q^2 + p^2*x^4]*(6*a*q^4 + 20*a*p*q^3*x^2 + 15*b*q*x^3 + 12*a*p^2*q^2 *x^4 + 15*b*p*x^5 + 20*a*p^3*q*x^6 + 6*a*p^4*x^8))/(30*x^5) + b*p*q*Log[x] - b*p*q*Log[q + p*x^2 + Sqrt[q^2 + p^2*x^4]]
Time = 1.28 (sec) , antiderivative size = 214, normalized size of antiderivative = 1.80, number of steps used = 15, number of rules used = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.311, Rules used = {2241, 25, 27, 1579, 536, 538, 224, 219, 243, 73, 221, 2069, 2249, 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 {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a \left (p x^2+q\right )^3+b x^3\right )}{x^6} \, dx\) |
\(\Big \downarrow \) 2241 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx+\int -\frac {b \left (q-p x^2\right ) \sqrt {p^2 x^4+q^2}}{x^3}dx\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\int \frac {b \left (q-p x^2\right ) \sqrt {p^2 x^4+q^2}}{x^3}dx\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-b \int \frac {\left (q-p x^2\right ) \sqrt {p^2 x^4+q^2}}{x^3}dx\) |
\(\Big \downarrow \) 1579 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \int \frac {\left (q-p x^2\right ) \sqrt {p^2 x^4+q^2}}{x^4}dx^2\) |
\(\Big \downarrow \) 536 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \left (\int \frac {p^2 q x^2-p q^2}{x^2 \sqrt {p^2 x^4+q^2}}dx^2-\frac {\left (p x^2+q\right ) \sqrt {p^2 x^4+q^2}}{x^2}\right )\) |
\(\Big \downarrow \) 538 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \left (p^2 q \int \frac {1}{\sqrt {p^2 x^4+q^2}}dx^2-p q^2 \int \frac {1}{x^2 \sqrt {p^2 x^4+q^2}}dx^2-\frac {\left (p x^2+q\right ) \sqrt {p^2 x^4+q^2}}{x^2}\right )\) |
\(\Big \downarrow \) 224 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \left (p^2 q \int \frac {1}{1-p^2 x^4}d\frac {x^2}{\sqrt {p^2 x^4+q^2}}-p q^2 \int \frac {1}{x^2 \sqrt {p^2 x^4+q^2}}dx^2-\frac {\left (p x^2+q\right ) \sqrt {p^2 x^4+q^2}}{x^2}\right )\) |
\(\Big \downarrow \) 219 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \left (-p q^2 \int \frac {1}{x^2 \sqrt {p^2 x^4+q^2}}dx^2+p q \text {arctanh}\left (\frac {p x^2}{\sqrt {p^2 x^4+q^2}}\right )-\frac {\left (p x^2+q\right ) \sqrt {p^2 x^4+q^2}}{x^2}\right )\) |
\(\Big \downarrow \) 243 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \left (-\frac {1}{2} p q^2 \int \frac {1}{x^2 \sqrt {p^2 x^4+q^2}}dx^4+p q \text {arctanh}\left (\frac {p x^2}{\sqrt {p^2 x^4+q^2}}\right )-\frac {\left (p x^2+q\right ) \sqrt {p^2 x^4+q^2}}{x^2}\right )\) |
\(\Big \downarrow \) 73 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \left (-\frac {q^2 \int \frac {1}{\frac {\sqrt {p^2 x^4+q^2}}{p^2}-\frac {q^2}{p^2}}d\sqrt {p^2 x^4+q^2}}{p}+p q \text {arctanh}\left (\frac {p x^2}{\sqrt {p^2 x^4+q^2}}\right )-\frac {\left (p x^2+q\right ) \sqrt {p^2 x^4+q^2}}{x^2}\right )\) |
\(\Big \downarrow \) 221 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \sqrt {p^2 x^4+q^2} \left (a p^3 x^6+3 a p^2 q x^4+3 a p q^2 x^2+a q^3\right )}{x^6}dx-\frac {1}{2} b \left (p q \text {arctanh}\left (\frac {\sqrt {p^2 x^4+q^2}}{q}\right )+p q \text {arctanh}\left (\frac {p x^2}{\sqrt {p^2 x^4+q^2}}\right )-\frac {\sqrt {p^2 x^4+q^2} \left (p x^2+q\right )}{x^2}\right )\) |
\(\Big \downarrow \) 2069 |
\(\displaystyle \int \frac {\left (p x^2-q\right ) \left (\sqrt [3]{a} p x^2+\sqrt [3]{a} q\right )^3 \sqrt {p^2 x^4+q^2}}{x^6}dx-\frac {1}{2} b \left (p q \text {arctanh}\left (\frac {\sqrt {p^2 x^4+q^2}}{q}\right )+p q \text {arctanh}\left (\frac {p x^2}{\sqrt {p^2 x^4+q^2}}\right )-\frac {\sqrt {p^2 x^4+q^2} \left (p x^2+q\right )}{x^2}\right )\) |
\(\Big \downarrow \) 2249 |
\(\displaystyle \int \left (-\frac {a q^6}{x^6 \sqrt {p^2 x^4+q^2}}-\frac {2 a p q^5}{x^4 \sqrt {p^2 x^4+q^2}}-\frac {a p^2 q^4}{x^2 \sqrt {p^2 x^4+q^2}}+\frac {a p^4 x^2 q^2}{\sqrt {p^2 x^4+q^2}}+\frac {2 a p^5 x^4 q}{\sqrt {p^2 x^4+q^2}}+\frac {a p^6 x^6}{\sqrt {p^2 x^4+q^2}}\right )dx-\frac {1}{2} b \left (p q \text {arctanh}\left (\frac {\sqrt {p^2 x^4+q^2}}{q}\right )+p q \text {arctanh}\left (\frac {p x^2}{\sqrt {p^2 x^4+q^2}}\right )-\frac {\sqrt {p^2 x^4+q^2} \left (p x^2+q\right )}{x^2}\right )\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {2 a p^2 q^2 \sqrt {p^2 x^4+q^2}}{5 x}+\frac {a q^4 \sqrt {p^2 x^4+q^2}}{5 x^5}+\frac {2 a p q^3 \sqrt {p^2 x^4+q^2}}{3 x^3}+\frac {1}{5} a p^4 x^3 \sqrt {p^2 x^4+q^2}+\frac {2}{3} a p^3 q x \sqrt {p^2 x^4+q^2}-\frac {1}{2} b \left (p q \text {arctanh}\left (\frac {\sqrt {p^2 x^4+q^2}}{q}\right )+p q \text {arctanh}\left (\frac {p x^2}{\sqrt {p^2 x^4+q^2}}\right )-\frac {\sqrt {p^2 x^4+q^2} \left (p x^2+q\right )}{x^2}\right )\) |
(a*q^4*Sqrt[q^2 + p^2*x^4])/(5*x^5) + (2*a*p*q^3*Sqrt[q^2 + p^2*x^4])/(3*x ^3) + (2*a*p^2*q^2*Sqrt[q^2 + p^2*x^4])/(5*x) + (2*a*p^3*q*x*Sqrt[q^2 + p^ 2*x^4])/3 + (a*p^4*x^3*Sqrt[q^2 + p^2*x^4])/5 - (b*(-(((q + p*x^2)*Sqrt[q^ 2 + p^2*x^4])/x^2) + p*q*ArcTanh[(p*x^2)/Sqrt[q^2 + p^2*x^4]] + p*q*ArcTan h[Sqrt[q^2 + p^2*x^4]/q]))/2
3.18.75.3.1 Defintions of rubi rules used
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
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[(1/(Rt[a, 2]*Rt[-b, 2]))* ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt Q[a, 0] || LtQ[b, 0])
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], x_Symbol] :> Subst[Int[1/(1 - b*x^2), x], x, x/Sqrt[a + b*x^2]] /; FreeQ[{a, b}, x] && !GtQ[a, 0]
Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> Simp[1/2 Subst[In t[x^((m - 1)/2)*(a + b*x)^p, x], x, x^2], x] /; FreeQ[{a, b, m, p}, x] && I ntegerQ[(m - 1)/2]
Int[(((c_) + (d_.)*(x_))*((a_) + (b_.)*(x_)^2)^(p_))/(x_)^2, x_Symbol] :> S imp[(-(2*c*p - d*x))*((a + b*x^2)^p/(2*p*x)), x] + Int[(a*d + 2*b*c*p*x)*(( a + b*x^2)^(p - 1)/x), x] /; FreeQ[{a, b, c, d}, x] && GtQ[p, 0] && Integer Q[2*p]
Int[((c_) + (d_.)*(x_))/((x_)*Sqrt[(a_) + (b_.)*(x_)^2]), x_Symbol] :> Simp [c Int[1/(x*Sqrt[a + b*x^2]), x], x] + Simp[d Int[1/Sqrt[a + b*x^2], x] , x] /; FreeQ[{a, b, c, d}, x]
Int[(x_)^(m_.)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (c_.)*(x_)^4)^(p_.), x_S ymbol] :> Simp[1/2 Subst[Int[x^((m - 1)/2)*(d + e*x)^q*(a + c*x^2)^p, x], x, x^2], x] /; FreeQ[{a, c, d, e, p, q}, x] && IntegerQ[(m + 1)/2]
Int[(u_.)*(Px_), x_Symbol] :> With[{a = Rt[Coeff[Px, x^2, 0], Expon[Px, x^2 ]], b = Rt[Coeff[Px, x^2, Expon[Px, x^2]], Expon[Px, x^2]]}, Int[u*(a + b*x ^2)^Expon[Px, x^2], x] /; EqQ[Px, (a + b*x^2)^Expon[Px, x^2]]] /; PolyQ[Px, x^2] && GtQ[Expon[Px, x^2], 1] && NeQ[Coeff[Px, x^2, 0], 0] && !MatchQ[Px , (a_.)*(v_)^Expon[Px, x^2] /; FreeQ[a, x] && BinomialQ[v, x, 2]]
Int[(Pr_)*((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (c_.)*(x_) ^4)^(p_), x_Symbol] :> Module[{r = Expon[Pr, x], k}, Int[Sum[Coeff[Pr, x, 2 *k]*x^(2*k), {k, 0, r/2 + 1}]*(f*x)^m*(d + e*x^2)^q*(a + c*x^4)^p, x] + Sim p[1/f Int[Sum[Coeff[Pr, x, 2*k + 1]*x^(2*k), {k, 0, (r + 1)/2}]*(f*x)^(m + 1)*(d + e*x^2)^q*(a + c*x^4)^p, x], x]] /; FreeQ[{a, c, d, e, f, m, p, q} , x] && PolyQ[Pr, x] && !PolyQ[Pr, x^2]
Int[(Px_)*((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (c_.)*(x_) ^4)^(p_), x_Symbol] :> Int[ExpandIntegrand[1/Sqrt[a + c*x^4], Px*(f*x)^m*(d + e*x^2)^q*(a + c*x^4)^(p + 1/2), x], x] /; FreeQ[{a, c, d, e, f, m}, x] & & PolyQ[Px, x] && IntegerQ[p + 1/2] && IntegerQ[q]
Result contains higher order function than in optimal. Order 9 vs. order 3.
Time = 3.86 (sec) , antiderivative size = 120, normalized size of antiderivative = 1.01
method | result | size |
pseudoelliptic | \(\frac {-5 b p q \ln \left (\frac {\sqrt {p^{2} x^{4}+q^{2}}+\left (p \,x^{2}+q \right ) \operatorname {csgn}\left (p \right )}{x}\right ) \operatorname {csgn}\left (p \right ) x^{5}+\sqrt {p^{2} x^{4}+q^{2}}\, \left (a \,p^{4} x^{8}+\frac {10}{3} a \,p^{3} q \,x^{6}+2 a \,p^{2} q^{2} x^{4}+\frac {10}{3} a p \,q^{3} x^{2}+\frac {5}{2} b p \,x^{5}+a \,q^{4}+\frac {5}{2} b q \,x^{3}\right )}{5 x^{5}}\) | \(120\) |
elliptic | \(\frac {b \left (p \sqrt {p^{2} x^{4}+q^{2}}-\frac {p^{2} q \ln \left (\frac {p^{2} x^{2}}{\sqrt {p^{2}}}+\sqrt {p^{2} x^{4}+q^{2}}\right )}{\sqrt {p^{2}}}+\frac {q \sqrt {p^{2} x^{4}+q^{2}}}{x^{2}}-\frac {p \,q^{2} \ln \left (\frac {2 q^{2}+2 \sqrt {q^{2}}\, \sqrt {p^{2} x^{4}+q^{2}}}{x^{2}}\right )}{\sqrt {q^{2}}}\right )}{2}+4 a \left (\frac {p q \left (p^{2} x^{4}+q^{2}\right )^{\frac {3}{2}} \sqrt {2}}{12 x^{3}}+\frac {\left (p^{2} x^{4}+q^{2}\right )^{\frac {5}{2}} \sqrt {2}}{40 x^{5}}\right ) \sqrt {2}\) | \(170\) |
risch | \(\frac {q \sqrt {p^{2} x^{4}+q^{2}}\, \left (12 a \,p^{2} q \,x^{4}+20 a p \,q^{2} x^{2}+6 a \,q^{3}+15 b \,x^{3}\right )}{30 x^{5}}+\frac {a \,p^{4} x^{3} \sqrt {p^{2} x^{4}+q^{2}}}{5}+\frac {p b \sqrt {p^{2} x^{4}+q^{2}}}{2}-\frac {p b \,q^{2} \ln \left (\frac {2 q^{2}+2 \sqrt {q^{2}}\, \sqrt {p^{2} x^{4}+q^{2}}}{x^{2}}\right )}{2 \sqrt {q^{2}}}+\frac {2 a \,p^{3} q x \sqrt {p^{2} x^{4}+q^{2}}}{3}-\frac {q b \,p^{2} \ln \left (\frac {p^{2} x^{2}}{\sqrt {p^{2}}}+\sqrt {p^{2} x^{4}+q^{2}}\right )}{2 \sqrt {p^{2}}}\) | \(196\) |
default | \(a \,p^{4} \left (\frac {x^{3} \sqrt {p^{2} x^{4}+q^{2}}}{5}+\frac {2 i q^{3} \sqrt {1-\frac {i p \,x^{2}}{q}}\, \sqrt {1+\frac {i p \,x^{2}}{q}}\, \left (\operatorname {EllipticF}\left (x \sqrt {\frac {i p}{q}}, i\right )-\operatorname {EllipticE}\left (x \sqrt {\frac {i p}{q}}, i\right )\right )}{5 \sqrt {\frac {i p}{q}}\, \sqrt {p^{2} x^{4}+q^{2}}\, p}\right )+p b \left (\frac {\sqrt {p^{2} x^{4}+q^{2}}}{2}-\frac {q^{2} \ln \left (\frac {2 q^{2}+2 \sqrt {q^{2}}\, \sqrt {p^{2} x^{4}+q^{2}}}{x^{2}}\right )}{2 \sqrt {q^{2}}}\right )+2 q a \,p^{3} \left (\frac {x \sqrt {p^{2} x^{4}+q^{2}}}{3}+\frac {2 q^{2} \sqrt {1-\frac {i p \,x^{2}}{q}}\, \sqrt {1+\frac {i p \,x^{2}}{q}}\, \operatorname {EllipticF}\left (x \sqrt {\frac {i p}{q}}, i\right )}{3 \sqrt {\frac {i p}{q}}\, \sqrt {p^{2} x^{4}+q^{2}}}\right )-q b \left (-\frac {\left (p^{2} x^{4}+q^{2}\right )^{\frac {3}{2}}}{2 q^{2} x^{2}}+\frac {p^{2} x^{2} \sqrt {p^{2} x^{4}+q^{2}}}{2 q^{2}}+\frac {p^{2} \ln \left (\frac {p^{2} x^{2}}{\sqrt {p^{2}}}+\sqrt {p^{2} x^{4}+q^{2}}\right )}{2 \sqrt {p^{2}}}\right )-a \,q^{4} \left (-\frac {\sqrt {p^{2} x^{4}+q^{2}}}{5 x^{5}}-\frac {2 p^{2} \sqrt {p^{2} x^{4}+q^{2}}}{5 q^{2} x}+\frac {2 i p^{3} \sqrt {1-\frac {i p \,x^{2}}{q}}\, \sqrt {1+\frac {i p \,x^{2}}{q}}\, \left (\operatorname {EllipticF}\left (x \sqrt {\frac {i p}{q}}, i\right )-\operatorname {EllipticE}\left (x \sqrt {\frac {i p}{q}}, i\right )\right )}{5 q \sqrt {\frac {i p}{q}}\, \sqrt {p^{2} x^{4}+q^{2}}}\right )-2 q^{3} a p \left (-\frac {\sqrt {p^{2} x^{4}+q^{2}}}{3 x^{3}}+\frac {2 p^{2} \sqrt {1-\frac {i p \,x^{2}}{q}}\, \sqrt {1+\frac {i p \,x^{2}}{q}}\, \operatorname {EllipticF}\left (x \sqrt {\frac {i p}{q}}, i\right )}{3 \sqrt {\frac {i p}{q}}\, \sqrt {p^{2} x^{4}+q^{2}}}\right )\) | \(590\) |
1/5*(-5*b*p*q*ln(((p^2*x^4+q^2)^(1/2)+(p*x^2+q)*csgn(p))/x)*csgn(p)*x^5+(p ^2*x^4+q^2)^(1/2)*(a*p^4*x^8+10/3*a*p^3*q*x^6+2*a*p^2*q^2*x^4+10/3*a*p*q^3 *x^2+5/2*b*p*x^5+a*q^4+5/2*b*q*x^3))/x^5
Time = 0.43 (sec) , antiderivative size = 117, normalized size of antiderivative = 0.98 \[ \int \frac {\left (-q+p x^2\right ) \sqrt {q^2+p^2 x^4} \left (b x^3+a \left (q+p x^2\right )^3\right )}{x^6} \, dx=\frac {30 \, b p q x^{5} \log \left (\frac {p x^{2} + q - \sqrt {p^{2} x^{4} + q^{2}}}{x}\right ) + {\left (6 \, a p^{4} x^{8} + 20 \, a p^{3} q x^{6} + 12 \, a p^{2} q^{2} x^{4} + 20 \, a p q^{3} x^{2} + 15 \, b p x^{5} + 6 \, a q^{4} + 15 \, b q x^{3}\right )} \sqrt {p^{2} x^{4} + q^{2}}}{30 \, x^{5}} \]
1/30*(30*b*p*q*x^5*log((p*x^2 + q - sqrt(p^2*x^4 + q^2))/x) + (6*a*p^4*x^8 + 20*a*p^3*q*x^6 + 12*a*p^2*q^2*x^4 + 20*a*p*q^3*x^2 + 15*b*p*x^5 + 6*a*q ^4 + 15*b*q*x^3)*sqrt(p^2*x^4 + q^2))/x^5
Result contains complex when optimal does not.
Time = 3.76 (sec) , antiderivative size = 323, normalized size of antiderivative = 2.71 \[ \int \frac {\left (-q+p x^2\right ) \sqrt {q^2+p^2 x^4} \left (b x^3+a \left (q+p x^2\right )^3\right )}{x^6} \, dx=\frac {a p^{4} q x^{3} \Gamma \left (\frac {3}{4}\right ) {{}_{2}F_{1}\left (\begin {matrix} - \frac {1}{2}, \frac {3}{4} \\ \frac {7}{4} \end {matrix}\middle | {\frac {p^{2} x^{4} e^{i \pi }}{q^{2}}} \right )}}{4 \Gamma \left (\frac {7}{4}\right )} + \frac {a p^{3} q^{2} x \Gamma \left (\frac {1}{4}\right ) {{}_{2}F_{1}\left (\begin {matrix} - \frac {1}{2}, \frac {1}{4} \\ \frac {5}{4} \end {matrix}\middle | {\frac {p^{2} x^{4} e^{i \pi }}{q^{2}}} \right )}}{2 \Gamma \left (\frac {5}{4}\right )} - \frac {a p q^{4} \Gamma \left (- \frac {3}{4}\right ) {{}_{2}F_{1}\left (\begin {matrix} - \frac {3}{4}, - \frac {1}{2} \\ \frac {1}{4} \end {matrix}\middle | {\frac {p^{2} x^{4} e^{i \pi }}{q^{2}}} \right )}}{2 x^{3} \Gamma \left (\frac {1}{4}\right )} - \frac {a q^{5} \Gamma \left (- \frac {5}{4}\right ) {{}_{2}F_{1}\left (\begin {matrix} - \frac {5}{4}, - \frac {1}{2} \\ - \frac {1}{4} \end {matrix}\middle | {\frac {p^{2} x^{4} e^{i \pi }}{q^{2}}} \right )}}{4 x^{5} \Gamma \left (- \frac {1}{4}\right )} + \frac {b p^{2} x^{2}}{2 \sqrt {\frac {p^{2} x^{4}}{q^{2}} + 1}} + \frac {b p^{2} x^{2}}{2 \sqrt {1 + \frac {q^{2}}{p^{2} x^{4}}}} - \frac {b p q \operatorname {asinh}{\left (\frac {q}{p x^{2}} \right )}}{2} - \frac {b p q \operatorname {asinh}{\left (\frac {p x^{2}}{q} \right )}}{2} + \frac {b q^{2}}{2 x^{2} \sqrt {\frac {p^{2} x^{4}}{q^{2}} + 1}} + \frac {b q^{2}}{2 x^{2} \sqrt {1 + \frac {q^{2}}{p^{2} x^{4}}}} \]
a*p**4*q*x**3*gamma(3/4)*hyper((-1/2, 3/4), (7/4,), p**2*x**4*exp_polar(I* pi)/q**2)/(4*gamma(7/4)) + a*p**3*q**2*x*gamma(1/4)*hyper((-1/2, 1/4), (5/ 4,), p**2*x**4*exp_polar(I*pi)/q**2)/(2*gamma(5/4)) - a*p*q**4*gamma(-3/4) *hyper((-3/4, -1/2), (1/4,), p**2*x**4*exp_polar(I*pi)/q**2)/(2*x**3*gamma (1/4)) - a*q**5*gamma(-5/4)*hyper((-5/4, -1/2), (-1/4,), p**2*x**4*exp_pol ar(I*pi)/q**2)/(4*x**5*gamma(-1/4)) + b*p**2*x**2/(2*sqrt(p**2*x**4/q**2 + 1)) + b*p**2*x**2/(2*sqrt(1 + q**2/(p**2*x**4))) - b*p*q*asinh(q/(p*x**2) )/2 - b*p*q*asinh(p*x**2/q)/2 + b*q**2/(2*x**2*sqrt(p**2*x**4/q**2 + 1)) + b*q**2/(2*x**2*sqrt(1 + q**2/(p**2*x**4)))
\[ \int \frac {\left (-q+p x^2\right ) \sqrt {q^2+p^2 x^4} \left (b x^3+a \left (q+p x^2\right )^3\right )}{x^6} \, dx=\int { \frac {\sqrt {p^{2} x^{4} + q^{2}} {\left ({\left (p x^{2} + q\right )}^{3} a + b x^{3}\right )} {\left (p x^{2} - q\right )}}{x^{6}} \,d x } \]
\[ \int \frac {\left (-q+p x^2\right ) \sqrt {q^2+p^2 x^4} \left (b x^3+a \left (q+p x^2\right )^3\right )}{x^6} \, dx=\int { \frac {\sqrt {p^{2} x^{4} + q^{2}} {\left ({\left (p x^{2} + q\right )}^{3} a + b x^{3}\right )} {\left (p x^{2} - q\right )}}{x^{6}} \,d x } \]
Timed out. \[ \int \frac {\left (-q+p x^2\right ) \sqrt {q^2+p^2 x^4} \left (b x^3+a \left (q+p x^2\right )^3\right )}{x^6} \, dx=-\int \frac {\sqrt {p^2\,x^4+q^2}\,\left (q-p\,x^2\right )\,\left (a\,{\left (p\,x^2+q\right )}^3+b\,x^3\right )}{x^6} \,d x \]