Optimal. Leaf size=71 \[ -\frac{\sqrt{\frac{2}{\pi }} \text{Erf}\left (\sqrt{2} (a+b x)\right )}{b}+\frac{(a+b x) \text{Erfc}(a+b x)^2}{b}-\frac{2 e^{-(a+b x)^2} \text{Erfc}(a+b x)}{\sqrt{\pi } b} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.156236, antiderivative size = 71, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 8, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.375, Rules used = {6353, 6383, 2205} \[ -\frac{\sqrt{\frac{2}{\pi }} \text{Erf}\left (\sqrt{2} (a+b x)\right )}{b}+\frac{(a+b x) \text{Erfc}(a+b x)^2}{b}-\frac{2 e^{-(a+b x)^2} \text{Erfc}(a+b x)}{\sqrt{\pi } b} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 6353
Rule 6383
Rule 2205
Rubi steps
\begin{align*} \int \text{erfc}(a+b x)^2 \, dx &=\frac{(a+b x) \text{erfc}(a+b x)^2}{b}+\frac{4 \int e^{-(a+b x)^2} (a+b x) \text{erfc}(a+b x) \, dx}{\sqrt{\pi }}\\ &=\frac{(a+b x) \text{erfc}(a+b x)^2}{b}+\frac{4 \operatorname{Subst}\left (\int e^{-x^2} x \text{erfc}(x) \, dx,x,a+b x\right )}{b \sqrt{\pi }}\\ &=-\frac{2 e^{-(a+b x)^2} \text{erfc}(a+b x)}{b \sqrt{\pi }}+\frac{(a+b x) \text{erfc}(a+b x)^2}{b}-\frac{4 \operatorname{Subst}\left (\int e^{-2 x^2} \, dx,x,a+b x\right )}{b \pi }\\ &=-\frac{\sqrt{\frac{2}{\pi }} \text{erf}\left (\sqrt{2} (a+b x)\right )}{b}-\frac{2 e^{-(a+b x)^2} \text{erfc}(a+b x)}{b \sqrt{\pi }}+\frac{(a+b x) \text{erfc}(a+b x)^2}{b}\\ \end{align*}
Mathematica [A] time = 0.0796041, size = 66, normalized size = 0.93 \[ \frac{\text{Erfc}(a+b x) \left ((a+b x) \text{Erfc}(a+b x)-\frac{2 e^{-(a+b x)^2}}{\sqrt{\pi }}\right )-\sqrt{\frac{2}{\pi }} \text{Erf}\left (\sqrt{2} (a+b x)\right )}{b} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.046, size = 59, normalized size = 0.8 \begin{align*}{\frac{1}{b} \left ( \left ( bx+a \right ) \left ({\it Erf} \left ( bx+a \right ) \right ) ^{2}+2\,{\frac{{\it Erf} \left ( bx+a \right ){{\rm e}^{- \left ( bx+a \right ) ^{2}}}}{\sqrt{\pi }}}-{\frac{\sqrt{2}{\it Erf} \left ( \left ( bx+a \right ) \sqrt{2} \right ) }{\sqrt{\pi }}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \operatorname{erfc}\left (b x + a\right )^{2}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 2.11445, size = 348, normalized size = 4.9 \begin{align*} -\frac{2 \, \pi b^{2} x \operatorname{erf}\left (b x + a\right ) - \pi b^{2} x + 2 \, \pi a \sqrt{b^{2}} \operatorname{erf}\left (\frac{\sqrt{b^{2}}{\left (b x + a\right )}}{b}\right ) -{\left (\pi b^{2} x + \pi a b\right )} \operatorname{erf}\left (b x + a\right )^{2} + \sqrt{2} \sqrt{\pi } \sqrt{b^{2}} \operatorname{erf}\left (\frac{\sqrt{2} \sqrt{b^{2}}{\left (b x + a\right )}}{b}\right ) - 2 \, \sqrt{\pi }{\left (b \operatorname{erf}\left (b x + a\right ) - b\right )} e^{\left (-b^{2} x^{2} - 2 \, a b x - a^{2}\right )}}{\pi b^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \operatorname{erfc}^{2}{\left (a + b x \right )}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \operatorname{erfc}\left (b x + a\right )^{2}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]