Optimal. Leaf size=143 \[ \frac {\cos \left (b^2 \pi x^2\right )}{4 b^2 \pi ^2}+\frac {x \cos \left (\frac {1}{2} b^2 \pi x^2\right ) S(b x)}{b \pi }-\frac {\text {FresnelC}(b x) S(b x)}{2 b^2 \pi }+\frac {1}{2} x^2 S(b x)^2+\frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;-\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi }-\frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi } \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.06, antiderivative size = 143, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 5, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.625, Rules used = {6565, 6589,
6581, 3460, 2718} \begin {gather*} \frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;-\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi }-\frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi }-\frac {\text {FresnelC}(b x) S(b x)}{2 \pi b^2}+\frac {x S(b x) \cos \left (\frac {1}{2} \pi b^2 x^2\right )}{\pi b}+\frac {\cos \left (\pi b^2 x^2\right )}{4 \pi ^2 b^2}+\frac {1}{2} x^2 S(b x)^2 \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2718
Rule 3460
Rule 6565
Rule 6581
Rule 6589
Rubi steps
\begin {align*} \int x S(b x)^2 \, dx &=\frac {1}{2} x^2 S(b x)^2-b \int x^2 S(b x) \sin \left (\frac {1}{2} b^2 \pi x^2\right ) \, dx\\ &=\frac {x \cos \left (\frac {1}{2} b^2 \pi x^2\right ) S(b x)}{b \pi }+\frac {1}{2} x^2 S(b x)^2-\frac {\int x \sin \left (b^2 \pi x^2\right ) \, dx}{2 \pi }-\frac {\int \cos \left (\frac {1}{2} b^2 \pi x^2\right ) S(b x) \, dx}{b \pi }\\ &=\frac {x \cos \left (\frac {1}{2} b^2 \pi x^2\right ) S(b x)}{b \pi }-\frac {C(b x) S(b x)}{2 b^2 \pi }+\frac {1}{2} x^2 S(b x)^2+\frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;-\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi }-\frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi }-\frac {\text {Subst}\left (\int \sin \left (b^2 \pi x\right ) \, dx,x,x^2\right )}{4 \pi }\\ &=\frac {\cos \left (b^2 \pi x^2\right )}{4 b^2 \pi ^2}+\frac {x \cos \left (\frac {1}{2} b^2 \pi x^2\right ) S(b x)}{b \pi }-\frac {C(b x) S(b x)}{2 b^2 \pi }+\frac {1}{2} x^2 S(b x)^2+\frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;-\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi }-\frac {i x^2 \, _2F_2\left (1,1;\frac {3}{2},2;\frac {1}{2} i b^2 \pi x^2\right )}{8 \pi }\\ \end {align*}
________________________________________________________________________________________
Mathematica [F]
time = 0.13, size = 0, normalized size = 0.00 \begin {gather*} \int x S(b x)^2 \, dx \end {gather*}
Verification is not applicable to the result.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.14, size = 0, normalized size = 0.00 \[\int x \mathrm {S}\left (b x \right )^{2}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int x S^{2}\left (b x\right )\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int x\,{\mathrm {FresnelS}\left (b\,x\right )}^2 \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________