Optimal. Leaf size=96 \[ -\frac{\text{CosIntegral}(2 a+2 b x)}{2 b^2}+\frac{\text{CosIntegral}(a+b x) \cos (a+b x)}{b^2}+\frac{a \text{Si}(2 a+2 b x)}{2 b^2}-\frac{\log (a+b x)}{2 b^2}+\frac{\cos (2 a+2 b x)}{4 b^2}+\frac{x \text{CosIntegral}(a+b x) \sin (a+b x)}{b} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.251984, antiderivative size = 96, normalized size of antiderivative = 1., number of steps used = 11, number of rules used = 9, integrand size = 14, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.643, Rules used = {6514, 4573, 6741, 6742, 2638, 3299, 6518, 3312, 3302} \[ -\frac{\text{CosIntegral}(2 a+2 b x)}{2 b^2}+\frac{\text{CosIntegral}(a+b x) \cos (a+b x)}{b^2}+\frac{a \text{Si}(2 a+2 b x)}{2 b^2}-\frac{\log (a+b x)}{2 b^2}+\frac{\cos (2 a+2 b x)}{4 b^2}+\frac{x \text{CosIntegral}(a+b x) \sin (a+b x)}{b} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 6514
Rule 4573
Rule 6741
Rule 6742
Rule 2638
Rule 3299
Rule 6518
Rule 3312
Rule 3302
Rubi steps
\begin{align*} \int x \cos (a+b x) \text{Ci}(a+b x) \, dx &=\frac{x \text{Ci}(a+b x) \sin (a+b x)}{b}-\frac{\int \text{Ci}(a+b x) \sin (a+b x) \, dx}{b}-\int \frac{x \cos (a+b x) \sin (a+b x)}{a+b x} \, dx\\ &=\frac{\cos (a+b x) \text{Ci}(a+b x)}{b^2}+\frac{x \text{Ci}(a+b x) \sin (a+b x)}{b}-\frac{1}{2} \int \frac{x \sin (2 (a+b x))}{a+b x} \, dx-\frac{\int \frac{\cos ^2(a+b x)}{a+b x} \, dx}{b}\\ &=\frac{\cos (a+b x) \text{Ci}(a+b x)}{b^2}+\frac{x \text{Ci}(a+b x) \sin (a+b x)}{b}-\frac{1}{2} \int \frac{x \sin (2 a+2 b x)}{a+b x} \, dx-\frac{\int \left (\frac{1}{2 (a+b x)}+\frac{\cos (2 a+2 b x)}{2 (a+b x)}\right ) \, dx}{b}\\ &=\frac{\cos (a+b x) \text{Ci}(a+b x)}{b^2}-\frac{\log (a+b x)}{2 b^2}+\frac{x \text{Ci}(a+b x) \sin (a+b x)}{b}-\frac{1}{2} \int \left (\frac{\sin (2 a+2 b x)}{b}+\frac{a \sin (2 a+2 b x)}{b (-a-b x)}\right ) \, dx-\frac{\int \frac{\cos (2 a+2 b x)}{a+b x} \, dx}{2 b}\\ &=\frac{\cos (a+b x) \text{Ci}(a+b x)}{b^2}-\frac{\text{Ci}(2 a+2 b x)}{2 b^2}-\frac{\log (a+b x)}{2 b^2}+\frac{x \text{Ci}(a+b x) \sin (a+b x)}{b}-\frac{\int \sin (2 a+2 b x) \, dx}{2 b}-\frac{a \int \frac{\sin (2 a+2 b x)}{-a-b x} \, dx}{2 b}\\ &=\frac{\cos (2 a+2 b x)}{4 b^2}+\frac{\cos (a+b x) \text{Ci}(a+b x)}{b^2}-\frac{\text{Ci}(2 a+2 b x)}{2 b^2}-\frac{\log (a+b x)}{2 b^2}+\frac{x \text{Ci}(a+b x) \sin (a+b x)}{b}+\frac{a \text{Si}(2 a+2 b x)}{2 b^2}\\ \end{align*}
Mathematica [A] time = 0.157884, size = 69, normalized size = 0.72 \[ \frac{-2 \text{CosIntegral}(2 (a+b x))+4 \text{CosIntegral}(a+b x) (b x \sin (a+b x)+\cos (a+b x))+2 a \text{Si}(2 (a+b x))-2 \log (a+b x)+\cos (2 (a+b x))}{4 b^2} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.062, size = 88, normalized size = 0.9 \begin{align*}{\frac{x{\it Ci} \left ( bx+a \right ) \sin \left ( bx+a \right ) }{b}}+{\frac{{\it Ci} \left ( bx+a \right ) \cos \left ( bx+a \right ) }{{b}^{2}}}+{\frac{ \left ( \cos \left ( bx+a \right ) \right ) ^{2}}{2\,{b}^{2}}}-{\frac{\ln \left ( bx+a \right ) }{2\,{b}^{2}}}-{\frac{{\it Ci} \left ( 2\,bx+2\,a \right ) }{2\,{b}^{2}}}+{\frac{a{\it Si} \left ( 2\,bx+2\,a \right ) }{2\,{b}^{2}}} \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 x{\rm Ci}\left (b x + a\right ) \cos \left (b x + a\right )\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F] time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (x \cos \left (b x + a\right ) \operatorname{Ci}\left (b x + a\right ), x\right ) \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 x \cos{\left (a + b x \right )} \operatorname{Ci}{\left (a + b x \right )}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [C] time = 1.17762, size = 143, normalized size = 1.49 \begin{align*}{\left (\frac{x \sin \left (b x + a\right )}{b} + \frac{\cos \left (b x + a\right )}{b^{2}}\right )} \operatorname{Ci}\left (b x + a\right ) + \frac{a \Im \left ( \operatorname{Ci}\left (2 \, b x + 2 \, a\right ) \right ) - a \Im \left ( \operatorname{Ci}\left (-2 \, b x - 2 \, a\right ) \right ) + 2 \, a \operatorname{Si}\left (2 \, b x + 2 \, a\right ) - 2 \, \log \left ({\left | b x + a \right |}\right ) - \Re \left ( \operatorname{Ci}\left (2 \, b x + 2 \, a\right ) \right ) - \Re \left ( \operatorname{Ci}\left (-2 \, b x - 2 \, a\right ) \right )}{4 \, b^{2}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]