3.2.96 \(\int f^{c (a+b x)^2} x^2 \, dx\) [196]

Optimal. Leaf size=140 \[ -\frac {\sqrt {\pi } \text {erfi}\left (\sqrt {c} (a+b x) \sqrt {\log (f)}\right )}{4 b^3 c^{3/2} \log ^{\frac {3}{2}}(f)}-\frac {a f^{c (a+b x)^2}}{b^3 c \log (f)}+\frac {f^{c (a+b x)^2} (a+b x)}{2 b^3 c \log (f)}+\frac {a^2 \sqrt {\pi } \text {erfi}\left (\sqrt {c} (a+b x) \sqrt {\log (f)}\right )}{2 b^3 \sqrt {c} \sqrt {\log (f)}} \]

[Out]

-a*f^(c*(b*x+a)^2)/b^3/c/ln(f)+1/2*f^(c*(b*x+a)^2)*(b*x+a)/b^3/c/ln(f)-1/4*erfi((b*x+a)*c^(1/2)*ln(f)^(1/2))*P
i^(1/2)/b^3/c^(3/2)/ln(f)^(3/2)+1/2*a^2*erfi((b*x+a)*c^(1/2)*ln(f)^(1/2))*Pi^(1/2)/b^3/c^(1/2)/ln(f)^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.09, antiderivative size = 140, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 4, integrand size = 15, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.267, Rules used = {2258, 2235, 2240, 2243} \begin {gather*} \frac {\sqrt {\pi } a^2 \text {Erfi}\left (\sqrt {c} \sqrt {\log (f)} (a+b x)\right )}{2 b^3 \sqrt {c} \sqrt {\log (f)}}-\frac {\sqrt {\pi } \text {Erfi}\left (\sqrt {c} \sqrt {\log (f)} (a+b x)\right )}{4 b^3 c^{3/2} \log ^{\frac {3}{2}}(f)}+\frac {(a+b x) f^{c (a+b x)^2}}{2 b^3 c \log (f)}-\frac {a f^{c (a+b x)^2}}{b^3 c \log (f)} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[f^(c*(a + b*x)^2)*x^2,x]

[Out]

-1/4*(Sqrt[Pi]*Erfi[Sqrt[c]*(a + b*x)*Sqrt[Log[f]]])/(b^3*c^(3/2)*Log[f]^(3/2)) - (a*f^(c*(a + b*x)^2))/(b^3*c
*Log[f]) + (f^(c*(a + b*x)^2)*(a + b*x))/(2*b^3*c*Log[f]) + (a^2*Sqrt[Pi]*Erfi[Sqrt[c]*(a + b*x)*Sqrt[Log[f]]]
)/(2*b^3*Sqrt[c]*Sqrt[Log[f]])

Rule 2235

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^2), x_Symbol] :> Simp[F^a*Sqrt[Pi]*(Erfi[(c + d*x)*Rt[b*Log[F], 2
]]/(2*d*Rt[b*Log[F], 2])), x] /; FreeQ[{F, a, b, c, d}, x] && PosQ[b]

Rule 2240

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

Rule 2243

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^(n_))*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[(c + d*x)^(m
- n + 1)*(F^(a + b*(c + d*x)^n)/(b*d*n*Log[F])), x] - Dist[(m - n + 1)/(b*n*Log[F]), Int[(c + d*x)^(m - n)*F^(
a + b*(c + d*x)^n), x], x] /; FreeQ[{F, a, b, c, d}, x] && IntegerQ[2*((m + 1)/n)] && LtQ[0, (m + 1)/n, 5] &&
IntegerQ[n] && (LtQ[0, n, m + 1] || LtQ[m, n, 0])

Rule 2258

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^(n_))*(u_), x_Symbol] :> Int[ExpandLinearProduct[F^(a + b*(c + d*
x)^n), u, c, d, x], x] /; FreeQ[{F, a, b, c, d, n}, x] && PolynomialQ[u, x]

Rubi steps

\begin {align*} \int f^{c (a+b x)^2} x^2 \, dx &=\int \left (\frac {a^2 f^{c (a+b x)^2}}{b^2}-\frac {2 a f^{c (a+b x)^2} (a+b x)}{b^2}+\frac {f^{c (a+b x)^2} (a+b x)^2}{b^2}\right ) \, dx\\ &=\frac {\int f^{c (a+b x)^2} (a+b x)^2 \, dx}{b^2}-\frac {(2 a) \int f^{c (a+b x)^2} (a+b x) \, dx}{b^2}+\frac {a^2 \int f^{c (a+b x)^2} \, dx}{b^2}\\ &=-\frac {a f^{c (a+b x)^2}}{b^3 c \log (f)}+\frac {f^{c (a+b x)^2} (a+b x)}{2 b^3 c \log (f)}+\frac {a^2 \sqrt {\pi } \text {erfi}\left (\sqrt {c} (a+b x) \sqrt {\log (f)}\right )}{2 b^3 \sqrt {c} \sqrt {\log (f)}}-\frac {\int f^{c (a+b x)^2} \, dx}{2 b^2 c \log (f)}\\ &=-\frac {\sqrt {\pi } \text {erfi}\left (\sqrt {c} (a+b x) \sqrt {\log (f)}\right )}{4 b^3 c^{3/2} \log ^{\frac {3}{2}}(f)}-\frac {a f^{c (a+b x)^2}}{b^3 c \log (f)}+\frac {f^{c (a+b x)^2} (a+b x)}{2 b^3 c \log (f)}+\frac {a^2 \sqrt {\pi } \text {erfi}\left (\sqrt {c} (a+b x) \sqrt {\log (f)}\right )}{2 b^3 \sqrt {c} \sqrt {\log (f)}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.15, size = 83, normalized size = 0.59 \begin {gather*} \frac {-2 \sqrt {c} f^{c (a+b x)^2} (a-b x) \sqrt {\log (f)}+\sqrt {\pi } \text {erfi}\left (\sqrt {c} (a+b x) \sqrt {\log (f)}\right ) \left (-1+2 a^2 c \log (f)\right )}{4 b^3 c^{3/2} \log ^{\frac {3}{2}}(f)} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[f^(c*(a + b*x)^2)*x^2,x]

[Out]

(-2*Sqrt[c]*f^(c*(a + b*x)^2)*(a - b*x)*Sqrt[Log[f]] + Sqrt[Pi]*Erfi[Sqrt[c]*(a + b*x)*Sqrt[Log[f]]]*(-1 + 2*a
^2*c*Log[f]))/(4*b^3*c^(3/2)*Log[f]^(3/2))

________________________________________________________________________________________

Maple [A]
time = 0.03, size = 168, normalized size = 1.20

method result size
risch \(\frac {x \,f^{b^{2} c \,x^{2}} f^{2 a b c x} f^{a^{2} c}}{2 c \,b^{2} \ln \left (f \right )}-\frac {a \,f^{b^{2} c \,x^{2}} f^{2 a b c x} f^{a^{2} c}}{2 b^{3} c \ln \left (f \right )}-\frac {a^{2} \sqrt {\pi }\, \erf \left (-b \sqrt {-c \ln \left (f \right )}\, x +\frac {c a \ln \left (f \right )}{\sqrt {-c \ln \left (f \right )}}\right )}{2 b^{3} \sqrt {-c \ln \left (f \right )}}+\frac {\sqrt {\pi }\, \erf \left (-b \sqrt {-c \ln \left (f \right )}\, x +\frac {c a \ln \left (f \right )}{\sqrt {-c \ln \left (f \right )}}\right )}{4 c \,b^{3} \ln \left (f \right ) \sqrt {-c \ln \left (f \right )}}\) \(168\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(f^(c*(b*x+a)^2)*x^2,x,method=_RETURNVERBOSE)

[Out]

1/2/c/b^2/ln(f)*x*f^(b^2*c*x^2)*f^(2*a*b*c*x)*f^(a^2*c)-1/2*a/b^3/c/ln(f)*f^(b^2*c*x^2)*f^(2*a*b*c*x)*f^(a^2*c
)-1/2*a^2/b^3*Pi^(1/2)/(-c*ln(f))^(1/2)*erf(-b*(-c*ln(f))^(1/2)*x+c*a*ln(f)/(-c*ln(f))^(1/2))+1/4/c/b^3/ln(f)*
Pi^(1/2)/(-c*ln(f))^(1/2)*erf(-b*(-c*ln(f))^(1/2)*x+c*a*ln(f)/(-c*ln(f))^(1/2))

________________________________________________________________________________________

Maxima [A]
time = 0.38, size = 218, normalized size = 1.56 \begin {gather*} \frac {\frac {\sqrt {\pi } {\left (b^{2} c x + a b c\right )} a^{2} c^{2} {\left (\operatorname {erf}\left (\sqrt {-\frac {{\left (b^{2} c x + a b c\right )}^{2} \log \left (f\right )}{b^{2} c}}\right ) - 1\right )} \log \left (f\right )^{3}}{\left (c \log \left (f\right )\right )^{\frac {5}{2}} b^{3} \sqrt {-\frac {{\left (b^{2} c x + a b c\right )}^{2} \log \left (f\right )}{b^{2} c}}} - \frac {2 \, a c^{2} f^{\frac {{\left (b^{2} c x + a b c\right )}^{2}}{b^{2} c}} \log \left (f\right )^{2}}{\left (c \log \left (f\right )\right )^{\frac {5}{2}} b^{2}} - \frac {{\left (b^{2} c x + a b c\right )}^{3} \Gamma \left (\frac {3}{2}, -\frac {{\left (b^{2} c x + a b c\right )}^{2} \log \left (f\right )}{b^{2} c}\right ) \log \left (f\right )^{3}}{\left (c \log \left (f\right )\right )^{\frac {5}{2}} b^{5} \left (-\frac {{\left (b^{2} c x + a b c\right )}^{2} \log \left (f\right )}{b^{2} c}\right )^{\frac {3}{2}}}}{2 \, \sqrt {c \log \left (f\right )} b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f^(c*(b*x+a)^2)*x^2,x, algorithm="maxima")

[Out]

1/2*(sqrt(pi)*(b^2*c*x + a*b*c)*a^2*c^2*(erf(sqrt(-(b^2*c*x + a*b*c)^2*log(f)/(b^2*c))) - 1)*log(f)^3/((c*log(
f))^(5/2)*b^3*sqrt(-(b^2*c*x + a*b*c)^2*log(f)/(b^2*c))) - 2*a*c^2*f^((b^2*c*x + a*b*c)^2/(b^2*c))*log(f)^2/((
c*log(f))^(5/2)*b^2) - (b^2*c*x + a*b*c)^3*gamma(3/2, -(b^2*c*x + a*b*c)^2*log(f)/(b^2*c))*log(f)^3/((c*log(f)
)^(5/2)*b^5*(-(b^2*c*x + a*b*c)^2*log(f)/(b^2*c))^(3/2)))/(sqrt(c*log(f))*b)

________________________________________________________________________________________

Fricas [A]
time = 0.37, size = 95, normalized size = 0.68 \begin {gather*} -\frac {\sqrt {\pi } {\left (2 \, a^{2} c \log \left (f\right ) - 1\right )} \sqrt {-b^{2} c \log \left (f\right )} \operatorname {erf}\left (\frac {\sqrt {-b^{2} c \log \left (f\right )} {\left (b x + a\right )}}{b}\right ) - 2 \, {\left (b^{2} c x - a b c\right )} f^{b^{2} c x^{2} + 2 \, a b c x + a^{2} c} \log \left (f\right )}{4 \, b^{4} c^{2} \log \left (f\right )^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f^(c*(b*x+a)^2)*x^2,x, algorithm="fricas")

[Out]

-1/4*(sqrt(pi)*(2*a^2*c*log(f) - 1)*sqrt(-b^2*c*log(f))*erf(sqrt(-b^2*c*log(f))*(b*x + a)/b) - 2*(b^2*c*x - a*
b*c)*f^(b^2*c*x^2 + 2*a*b*c*x + a^2*c)*log(f))/(b^4*c^2*log(f)^2)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int f^{c \left (a + b x\right )^{2}} x^{2}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f**(c*(b*x+a)**2)*x**2,x)

[Out]

Integral(f**(c*(a + b*x)**2)*x**2, x)

________________________________________________________________________________________

Giac [A]
time = 2.15, size = 107, normalized size = 0.76 \begin {gather*} -\frac {\frac {\sqrt {\pi } {\left (2 \, a^{2} c \log \left (f\right ) - 1\right )} \operatorname {erf}\left (-\sqrt {-c \log \left (f\right )} b {\left (x + \frac {a}{b}\right )}\right )}{\sqrt {-c \log \left (f\right )} b c \log \left (f\right )} - \frac {2 \, {\left (b {\left (x + \frac {a}{b}\right )} - 2 \, a\right )} e^{\left (b^{2} c x^{2} \log \left (f\right ) + 2 \, a b c x \log \left (f\right ) + a^{2} c \log \left (f\right )\right )}}{b c \log \left (f\right )}}{4 \, b^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(f^(c*(b*x+a)^2)*x^2,x, algorithm="giac")

[Out]

-1/4*(sqrt(pi)*(2*a^2*c*log(f) - 1)*erf(-sqrt(-c*log(f))*b*(x + a/b))/(sqrt(-c*log(f))*b*c*log(f)) - 2*(b*(x +
 a/b) - 2*a)*e^(b^2*c*x^2*log(f) + 2*a*b*c*x*log(f) + a^2*c*log(f))/(b*c*log(f)))/b^2

________________________________________________________________________________________

Mupad [B]
time = 3.61, size = 121, normalized size = 0.86 \begin {gather*} \frac {\sqrt {\pi }\,\mathrm {erfi}\left (\sqrt {c\,\ln \left (f\right )}\,\left (a+b\,x\right )\right )\,\left (\frac {a^2}{b^3}-\frac {1}{2\,b^3\,c\,\ln \left (f\right )}\right )}{2\,\sqrt {c\,\ln \left (f\right )}}-\frac {a\,f^{b^2\,c\,x^2}\,f^{a^2\,c}\,f^{2\,a\,b\,c\,x}}{2\,b^3\,c\,\ln \left (f\right )}+\frac {f^{b^2\,c\,x^2}\,f^{a^2\,c}\,f^{2\,a\,b\,c\,x}\,x}{2\,b^2\,c\,\ln \left (f\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(f^(c*(a + b*x)^2)*x^2,x)

[Out]

(pi^(1/2)*erfi((c*log(f))^(1/2)*(a + b*x))*(a^2/b^3 - 1/(2*b^3*c*log(f))))/(2*(c*log(f))^(1/2)) - (a*f^(b^2*c*
x^2)*f^(a^2*c)*f^(2*a*b*c*x))/(2*b^3*c*log(f)) + (f^(b^2*c*x^2)*f^(a^2*c)*f^(2*a*b*c*x)*x)/(2*b^2*c*log(f))

________________________________________________________________________________________