Optimal. Leaf size=20 \[ a x+\frac{b \sin ^2(c+d x)}{2 d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0155313, antiderivative size = 20, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.125, Rules used = {2564, 30} \[ a x+\frac{b \sin ^2(c+d x)}{2 d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2564
Rule 30
Rubi steps
\begin{align*} \int (a+b \cos (c+d x) \sin (c+d x)) \, dx &=a x+b \int \cos (c+d x) \sin (c+d x) \, dx\\ &=a x+\frac{b \operatorname{Subst}(\int x \, dx,x,\sin (c+d x))}{d}\\ &=a x+\frac{b \sin ^2(c+d x)}{2 d}\\ \end{align*}
Mathematica [A] time = 0.0080549, size = 38, normalized size = 1.9 \[ a x+\frac{b \sin (2 c) \sin (2 d x)}{4 d}-\frac{b \cos (2 c) \cos (2 d x)}{4 d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.001, size = 19, normalized size = 1. \begin{align*} ax+{\frac{b \left ( \sin \left ( dx+c \right ) \right ) ^{2}}{2\,d}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.00264, size = 24, normalized size = 1.2 \begin{align*} a x - \frac{b \cos \left (d x + c\right )^{2}}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 2.30785, size = 49, normalized size = 2.45 \begin{align*} \frac{2 \, a d x - b \cos \left (d x + c\right )^{2}}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 0.199445, size = 24, normalized size = 1.2 \begin{align*} a x + b \left (\begin{cases} \frac{\sin ^{2}{\left (c + d x \right )}}{2 d} & \text{for}\: d \neq 0 \\x \sin{\left (c \right )} \cos{\left (c \right )} & \text{otherwise} \end{cases}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.12474, size = 24, normalized size = 1.2 \begin{align*} a x + \frac{b \sin \left (d x + c\right )^{2}}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]