Integrand size = 25, antiderivative size = 62 \[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=-\frac {2 a (3 A+B) \cos (e+f x)}{3 f \sqrt {a+a \sin (e+f x)}}-\frac {2 B \cos (e+f x) \sqrt {a+a \sin (e+f x)}}{3 f} \] Output:
-2/3*a*(3*A+B)*cos(f*x+e)/f/(a+a*sin(f*x+e))^(1/2)-2/3*B*cos(f*x+e)*(a+a*s in(f*x+e))^(1/2)/f
Time = 0.30 (sec) , antiderivative size = 82, normalized size of antiderivative = 1.32 \[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=-\frac {2 \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right ) \sqrt {a (1+\sin (e+f x))} (3 A+2 B+B \sin (e+f x))}{3 f \left (\cos \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {1}{2} (e+f x)\right )\right )} \] Input:
Integrate[Sqrt[a + a*Sin[e + f*x]]*(A + B*Sin[e + f*x]),x]
Output:
(-2*(Cos[(e + f*x)/2] - Sin[(e + f*x)/2])*Sqrt[a*(1 + Sin[e + f*x])]*(3*A + 2*B + B*Sin[e + f*x]))/(3*f*(Cos[(e + f*x)/2] + Sin[(e + f*x)/2]))
Time = 0.30 (sec) , antiderivative size = 62, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.160, Rules used = {3042, 3230, 3042, 3125}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \sqrt {a \sin (e+f x)+a} (A+B \sin (e+f x)) \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sqrt {a \sin (e+f x)+a} (A+B \sin (e+f x))dx\) |
\(\Big \downarrow \) 3230 |
\(\displaystyle \frac {1}{3} (3 A+B) \int \sqrt {\sin (e+f x) a+a}dx-\frac {2 B \cos (e+f x) \sqrt {a \sin (e+f x)+a}}{3 f}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {1}{3} (3 A+B) \int \sqrt {\sin (e+f x) a+a}dx-\frac {2 B \cos (e+f x) \sqrt {a \sin (e+f x)+a}}{3 f}\) |
\(\Big \downarrow \) 3125 |
\(\displaystyle -\frac {2 a (3 A+B) \cos (e+f x)}{3 f \sqrt {a \sin (e+f x)+a}}-\frac {2 B \cos (e+f x) \sqrt {a \sin (e+f x)+a}}{3 f}\) |
Input:
Int[Sqrt[a + a*Sin[e + f*x]]*(A + B*Sin[e + f*x]),x]
Output:
(-2*a*(3*A + B)*Cos[e + f*x])/(3*f*Sqrt[a + a*Sin[e + f*x]]) - (2*B*Cos[e + f*x]*Sqrt[a + a*Sin[e + f*x]])/(3*f)
Int[Sqrt[(a_) + (b_.)*sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[-2*b*(Cos [c + d*x]/(d*Sqrt[a + b*Sin[c + d*x]])), x] /; FreeQ[{a, b, c, d}, x] && Eq Q[a^2 - b^2, 0]
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(-d)*Cos[e + f*x]*((a + b*Sin[e + f*x])^m/( f*(m + 1))), x] + Simp[(a*d*m + b*c*(m + 1))/(b*(m + 1)) Int[(a + b*Sin[e + f*x])^m, x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && !LtQ[m, -2^(-1)]
Time = 0.52 (sec) , antiderivative size = 58, normalized size of antiderivative = 0.94
method | result | size |
default | \(\frac {2 \left (1+\sin \left (f x +e \right )\right ) a \left (\sin \left (f x +e \right )-1\right ) \left (B \sin \left (f x +e \right )+3 A +2 B \right )}{3 \cos \left (f x +e \right ) \sqrt {a +a \sin \left (f x +e \right )}\, f}\) | \(58\) |
parts | \(\frac {2 A \left (1+\sin \left (f x +e \right )\right ) \left (\sin \left (f x +e \right )-1\right ) a}{\cos \left (f x +e \right ) \sqrt {a +a \sin \left (f x +e \right )}\, f}+\frac {2 B \left (1+\sin \left (f x +e \right )\right ) a \left (\sin \left (f x +e \right )-1\right ) \left (\sin \left (f x +e \right )+2\right )}{3 \cos \left (f x +e \right ) \sqrt {a +a \sin \left (f x +e \right )}\, f}\) | \(96\) |
Input:
int((a+a*sin(f*x+e))^(1/2)*(A+B*sin(f*x+e)),x,method=_RETURNVERBOSE)
Output:
2/3*(1+sin(f*x+e))*a*(sin(f*x+e)-1)*(B*sin(f*x+e)+3*A+2*B)/cos(f*x+e)/(a+a *sin(f*x+e))^(1/2)/f
Time = 0.09 (sec) , antiderivative size = 85, normalized size of antiderivative = 1.37 \[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=-\frac {2 \, {\left (B \cos \left (f x + e\right )^{2} + {\left (3 \, A + 2 \, B\right )} \cos \left (f x + e\right ) + {\left (B \cos \left (f x + e\right ) - 3 \, A - B\right )} \sin \left (f x + e\right ) + 3 \, A + B\right )} \sqrt {a \sin \left (f x + e\right ) + a}}{3 \, {\left (f \cos \left (f x + e\right ) + f \sin \left (f x + e\right ) + f\right )}} \] Input:
integrate((a+a*sin(f*x+e))^(1/2)*(A+B*sin(f*x+e)),x, algorithm="fricas")
Output:
-2/3*(B*cos(f*x + e)^2 + (3*A + 2*B)*cos(f*x + e) + (B*cos(f*x + e) - 3*A - B)*sin(f*x + e) + 3*A + B)*sqrt(a*sin(f*x + e) + a)/(f*cos(f*x + e) + f* sin(f*x + e) + f)
\[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=\int \sqrt {a \left (\sin {\left (e + f x \right )} + 1\right )} \left (A + B \sin {\left (e + f x \right )}\right )\, dx \] Input:
integrate((a+a*sin(f*x+e))**(1/2)*(A+B*sin(f*x+e)),x)
Output:
Integral(sqrt(a*(sin(e + f*x) + 1))*(A + B*sin(e + f*x)), x)
\[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=\int { {\left (B \sin \left (f x + e\right ) + A\right )} \sqrt {a \sin \left (f x + e\right ) + a} \,d x } \] Input:
integrate((a+a*sin(f*x+e))^(1/2)*(A+B*sin(f*x+e)),x, algorithm="maxima")
Output:
integrate((B*sin(f*x + e) + A)*sqrt(a*sin(f*x + e) + a), x)
Time = 0.23 (sec) , antiderivative size = 85, normalized size of antiderivative = 1.37 \[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=\frac {\sqrt {2} {\left (B \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) \sin \left (-\frac {3}{4} \, \pi + \frac {3}{2} \, f x + \frac {3}{2} \, e\right ) + 3 \, {\left (2 \, A \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) + B \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )\right )} \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )} \sqrt {a}}{3 \, f} \] Input:
integrate((a+a*sin(f*x+e))^(1/2)*(A+B*sin(f*x+e)),x, algorithm="giac")
Output:
1/3*sqrt(2)*(B*sgn(cos(-1/4*pi + 1/2*f*x + 1/2*e))*sin(-3/4*pi + 3/2*f*x + 3/2*e) + 3*(2*A*sgn(cos(-1/4*pi + 1/2*f*x + 1/2*e)) + B*sgn(cos(-1/4*pi + 1/2*f*x + 1/2*e)))*sin(-1/4*pi + 1/2*f*x + 1/2*e))*sqrt(a)/f
Timed out. \[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=\int \left (A+B\,\sin \left (e+f\,x\right )\right )\,\sqrt {a+a\,\sin \left (e+f\,x\right )} \,d x \] Input:
int((A + B*sin(e + f*x))*(a + a*sin(e + f*x))^(1/2),x)
Output:
int((A + B*sin(e + f*x))*(a + a*sin(e + f*x))^(1/2), x)
\[ \int \sqrt {a+a \sin (e+f x)} (A+B \sin (e+f x)) \, dx=\sqrt {a}\, \left (\left (\int \sqrt {\sin \left (f x +e \right )+1}d x \right ) a +\left (\int \sqrt {\sin \left (f x +e \right )+1}\, \sin \left (f x +e \right )d x \right ) b \right ) \] Input:
int((a+a*sin(f*x+e))^(1/2)*(A+B*sin(f*x+e)),x)
Output:
sqrt(a)*(int(sqrt(sin(e + f*x) + 1),x)*a + int(sqrt(sin(e + f*x) + 1)*sin( e + f*x),x)*b)