Optimal. Leaf size=229 \[ -\frac {a^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi }+\frac {3 a^2 (a+b x) \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{2 b^4 \pi }-\frac {a (a+b x)^2 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi }+\frac {(a+b x)^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi }-\frac {3 a^2 \text {FresnelC}(a+b x)}{2 b^4 \pi }-\frac {a^4 S(a+b x)}{4 b^4}+\frac {3 S(a+b x)}{4 b^4 \pi ^2}+\frac {1}{4} x^4 S(a+b x)+\frac {2 a \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi ^2}-\frac {3 (a+b x) \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi ^2} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.13, antiderivative size = 229, normalized size of antiderivative = 1.00, number of steps
used = 14, number of rules used = 10, integrand size = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 1.000, Rules used = {6563, 3514,
3432, 3460, 2718, 3466, 3433, 3377, 2717, 3467} \begin {gather*} -\frac {a^4 S(a+b x)}{4 b^4}-\frac {a^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{\pi b^4}-\frac {3 a^2 \text {FresnelC}(a+b x)}{2 \pi b^4}+\frac {3 a^2 (a+b x) \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{2 \pi b^4}+\frac {3 S(a+b x)}{4 \pi ^2 b^4}+\frac {2 a \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{\pi ^2 b^4}-\frac {3 (a+b x) \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 \pi ^2 b^4}-\frac {a (a+b x)^2 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{\pi b^4}+\frac {(a+b x)^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 \pi b^4}+\frac {1}{4} x^4 S(a+b x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2717
Rule 2718
Rule 3377
Rule 3432
Rule 3433
Rule 3460
Rule 3466
Rule 3467
Rule 3514
Rule 6563
Rubi steps
\begin {align*} \int x^3 S(a+b x) \, dx &=\frac {1}{4} x^4 S(a+b x)-\frac {1}{4} b \int x^4 \sin \left (\frac {1}{2} \pi (a+b x)^2\right ) \, dx\\ &=\frac {1}{4} x^4 S(a+b x)-\frac {\text {Subst}\left (\int \left (a^4 \sin \left (\frac {\pi x^2}{2}\right )-4 a^3 x \sin \left (\frac {\pi x^2}{2}\right )+6 a^2 x^2 \sin \left (\frac {\pi x^2}{2}\right )-4 a x^3 \sin \left (\frac {\pi x^2}{2}\right )+x^4 \sin \left (\frac {\pi x^2}{2}\right )\right ) \, dx,x,a+b x\right )}{4 b^4}\\ &=\frac {1}{4} x^4 S(a+b x)-\frac {\text {Subst}\left (\int x^4 \sin \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{4 b^4}+\frac {a \text {Subst}\left (\int x^3 \sin \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{b^4}-\frac {\left (3 a^2\right ) \text {Subst}\left (\int x^2 \sin \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{2 b^4}+\frac {a^3 \text {Subst}\left (\int x \sin \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{b^4}-\frac {a^4 \text {Subst}\left (\int \sin \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{4 b^4}\\ &=\frac {3 a^2 (a+b x) \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{2 b^4 \pi }+\frac {(a+b x)^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi }-\frac {a^4 S(a+b x)}{4 b^4}+\frac {1}{4} x^4 S(a+b x)+\frac {a \text {Subst}\left (\int x \sin \left (\frac {\pi x}{2}\right ) \, dx,x,(a+b x)^2\right )}{2 b^4}+\frac {a^3 \text {Subst}\left (\int \sin \left (\frac {\pi x}{2}\right ) \, dx,x,(a+b x)^2\right )}{2 b^4}-\frac {3 \text {Subst}\left (\int x^2 \cos \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{4 b^4 \pi }-\frac {\left (3 a^2\right ) \text {Subst}\left (\int \cos \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{2 b^4 \pi }\\ &=-\frac {a^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi }+\frac {3 a^2 (a+b x) \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{2 b^4 \pi }-\frac {a (a+b x)^2 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi }+\frac {(a+b x)^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi }-\frac {3 a^2 C(a+b x)}{2 b^4 \pi }-\frac {a^4 S(a+b x)}{4 b^4}+\frac {1}{4} x^4 S(a+b x)-\frac {3 (a+b x) \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi ^2}+\frac {3 \text {Subst}\left (\int \sin \left (\frac {\pi x^2}{2}\right ) \, dx,x,a+b x\right )}{4 b^4 \pi ^2}+\frac {a \text {Subst}\left (\int \cos \left (\frac {\pi x}{2}\right ) \, dx,x,(a+b x)^2\right )}{b^4 \pi }\\ &=-\frac {a^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi }+\frac {3 a^2 (a+b x) \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{2 b^4 \pi }-\frac {a (a+b x)^2 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi }+\frac {(a+b x)^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi }-\frac {3 a^2 C(a+b x)}{2 b^4 \pi }-\frac {a^4 S(a+b x)}{4 b^4}+\frac {3 S(a+b x)}{4 b^4 \pi ^2}+\frac {1}{4} x^4 S(a+b x)+\frac {2 a \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{b^4 \pi ^2}-\frac {3 (a+b x) \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi ^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.24, size = 166, normalized size = 0.72 \begin {gather*} \frac {-a^3 \pi \cos \left (\frac {1}{2} \pi (a+b x)^2\right )+a^2 b \pi x \cos \left (\frac {1}{2} \pi (a+b x)^2\right )-a b^2 \pi x^2 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )+b^3 \pi x^3 \cos \left (\frac {1}{2} \pi (a+b x)^2\right )-6 a^2 \pi \text {FresnelC}(a+b x)+\left (3-a^4 \pi ^2+b^4 \pi ^2 x^4\right ) S(a+b x)+5 a \sin \left (\frac {1}{2} \pi (a+b x)^2\right )-3 b x \sin \left (\frac {1}{2} \pi (a+b x)^2\right )}{4 b^4 \pi ^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.40, size = 189, normalized size = 0.83
method | result | size |
derivativedivides | \(\frac {\frac {\mathrm {S}\left (b x +a \right ) b^{4} x^{4}}{4}-\frac {a^{4} \mathrm {S}\left (b x +a \right )}{4}-\frac {a^{3} \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi }+\frac {3 a^{2} \left (b x +a \right ) \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{2 \pi }-\frac {3 a^{2} \FresnelC \left (b x +a \right )}{2 \pi }-\frac {a \left (b x +a \right )^{2} \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi }+\frac {2 a \sin \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi ^{2}}+\frac {\left (b x +a \right )^{3} \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{4 \pi }-\frac {3 \left (\frac {\left (b x +a \right ) \sin \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi }-\frac {\mathrm {S}\left (b x +a \right )}{\pi }\right )}{4 \pi }}{b^{4}}\) | \(189\) |
default | \(\frac {\frac {\mathrm {S}\left (b x +a \right ) b^{4} x^{4}}{4}-\frac {a^{4} \mathrm {S}\left (b x +a \right )}{4}-\frac {a^{3} \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi }+\frac {3 a^{2} \left (b x +a \right ) \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{2 \pi }-\frac {3 a^{2} \FresnelC \left (b x +a \right )}{2 \pi }-\frac {a \left (b x +a \right )^{2} \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi }+\frac {2 a \sin \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi ^{2}}+\frac {\left (b x +a \right )^{3} \cos \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{4 \pi }-\frac {3 \left (\frac {\left (b x +a \right ) \sin \left (\frac {\pi \left (b x +a \right )^{2}}{2}\right )}{\pi }-\frac {\mathrm {S}\left (b x +a \right )}{\pi }\right )}{4 \pi }}{b^{4}}\) | \(189\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [C] Result contains complex when optimal does not.
time = 1.16, size = 503, normalized size = 2.20 \begin {gather*} \frac {1}{4} \, x^{4} \operatorname {S}\left (b x + a\right ) - \frac {{\left (16 \, {\left (\pi ^{2} e^{\left (\frac {1}{2} i \, \pi b^{2} x^{2} + i \, \pi a b x + \frac {1}{2} i \, \pi a^{2}\right )} + \pi ^{2} e^{\left (-\frac {1}{2} i \, \pi b^{2} x^{2} - i \, \pi a b x - \frac {1}{2} i \, \pi a^{2}\right )}\right )} a^{4} + 32 \, {\left (-i \, \pi \Gamma \left (2, \frac {1}{2} i \, \pi b^{2} x^{2} + i \, \pi a b x + \frac {1}{2} i \, \pi a^{2}\right ) + i \, \pi \Gamma \left (2, -\frac {1}{2} i \, \pi b^{2} x^{2} - i \, \pi a b x - \frac {1}{2} i \, \pi a^{2}\right )\right )} a^{2} + 16 \, {\left ({\left (\pi ^{2} e^{\left (\frac {1}{2} i \, \pi b^{2} x^{2} + i \, \pi a b x + \frac {1}{2} i \, \pi a^{2}\right )} + \pi ^{2} e^{\left (-\frac {1}{2} i \, \pi b^{2} x^{2} - i \, \pi a b x - \frac {1}{2} i \, \pi a^{2}\right )}\right )} a^{3} + 2 \, {\left (-i \, \pi \Gamma \left (2, \frac {1}{2} i \, \pi b^{2} x^{2} + i \, \pi a b x + \frac {1}{2} i \, \pi a^{2}\right ) + i \, \pi \Gamma \left (2, -\frac {1}{2} i \, \pi b^{2} x^{2} - i \, \pi a b x - \frac {1}{2} i \, \pi a^{2}\right )\right )} a\right )} b x - {\left ({\left (-\left (i + 1\right ) \, \sqrt {2} \pi ^{\frac {5}{2}} {\left (\operatorname {erf}\left (\sqrt {\frac {1}{2} i \, \pi b^{2} x^{2} + i \, \pi a b x + \frac {1}{2} i \, \pi a^{2}}\right ) - 1\right )} + \left (i - 1\right ) \, \sqrt {2} \pi ^{\frac {5}{2}} {\left (\operatorname {erf}\left (\sqrt {-\frac {1}{2} i \, \pi b^{2} x^{2} - i \, \pi a b x - \frac {1}{2} i \, \pi a^{2}}\right ) - 1\right )}\right )} a^{4} - 12 \, {\left (\left (i - 1\right ) \, \sqrt {2} \pi \Gamma \left (\frac {3}{2}, \frac {1}{2} i \, \pi b^{2} x^{2} + i \, \pi a b x + \frac {1}{2} i \, \pi a^{2}\right ) - \left (i + 1\right ) \, \sqrt {2} \pi \Gamma \left (\frac {3}{2}, -\frac {1}{2} i \, \pi b^{2} x^{2} - i \, \pi a b x - \frac {1}{2} i \, \pi a^{2}\right )\right )} a^{2} - \left (4 i + 4\right ) \, \sqrt {2} \Gamma \left (\frac {5}{2}, \frac {1}{2} i \, \pi b^{2} x^{2} + i \, \pi a b x + \frac {1}{2} i \, \pi a^{2}\right ) + \left (4 i - 4\right ) \, \sqrt {2} \Gamma \left (\frac {5}{2}, -\frac {1}{2} i \, \pi b^{2} x^{2} - i \, \pi a b x - \frac {1}{2} i \, \pi a^{2}\right )\right )} \sqrt {2 \, \pi b^{2} x^{2} + 4 \, \pi a b x + 2 \, \pi a^{2}}\right )} b}{32 \, {\left (\pi ^{3} b^{6} x + \pi ^{3} a b^{5}\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.37, size = 175, normalized size = 0.76 \begin {gather*} \frac {\pi ^{2} b^{5} x^{4} \operatorname {S}\left (b x + a\right ) - 6 \, \pi a^{2} \sqrt {b^{2}} \operatorname {C}\left (\frac {\sqrt {b^{2}} {\left (b x + a\right )}}{b}\right ) - {\left (\pi ^{2} a^{4} - 3\right )} \sqrt {b^{2}} \operatorname {S}\left (\frac {\sqrt {b^{2}} {\left (b x + a\right )}}{b}\right ) + {\left (\pi b^{4} x^{3} - \pi a b^{3} x^{2} + \pi a^{2} b^{2} x - \pi a^{3} b\right )} \cos \left (\frac {1}{2} \, \pi b^{2} x^{2} + \pi a b x + \frac {1}{2} \, \pi a^{2}\right ) - {\left (3 \, b^{2} x - 5 \, a b\right )} \sin \left (\frac {1}{2} \, \pi b^{2} x^{2} + \pi a b x + \frac {1}{2} \, \pi a^{2}\right )}{4 \, \pi ^{2} b^{5}} \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^{3} S\left (a + 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.00 \begin {gather*} \int x^3\,\mathrm {FresnelS}\left (a+b\,x\right ) \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________