Integrand size = 30, antiderivative size = 49 \[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=\frac {c \cos (e+f x) \log (1+\sin (e+f x))}{f \sqrt {a+a \sin (e+f x)} \sqrt {c-c \sin (e+f x)}} \] Output:
c*cos(f*x+e)*ln(1+sin(f*x+e))/f/(a+a*sin(f*x+e))^(1/2)/(c-c*sin(f*x+e))^(1 /2)
Result contains complex when optimal does not.
Time = 1.76 (sec) , antiderivative size = 118, normalized size of antiderivative = 2.41 \[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=-\frac {\sqrt {2} \left (i+e^{i (e+f x)}\right ) \left (f x+2 i \log \left (i+e^{i (e+f x)}\right )\right ) \sqrt {c-c \sin (e+f x)}}{\left (-i+e^{i (e+f x)}\right ) \sqrt {-i a e^{-i (e+f x)} \left (i+e^{i (e+f x)}\right )^2} f} \] Input:
Integrate[Sqrt[c - c*Sin[e + f*x]]/Sqrt[a + a*Sin[e + f*x]],x]
Output:
-((Sqrt[2]*(I + E^(I*(e + f*x)))*(f*x + (2*I)*Log[I + E^(I*(e + f*x))])*Sq rt[c - c*Sin[e + f*x]])/((-I + E^(I*(e + f*x)))*Sqrt[((-I)*a*(I + E^(I*(e + f*x)))^2)/E^(I*(e + f*x))]*f))
Time = 0.35 (sec) , antiderivative size = 51, normalized size of antiderivative = 1.04, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {3042, 3216, 3042, 3146, 16}
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 \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a \sin (e+f x)+a}} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a \sin (e+f x)+a}}dx\) |
\(\Big \downarrow \) 3216 |
\(\displaystyle \frac {a c \cos (e+f x) \int \frac {\cos (e+f x)}{\sin (e+f x) a+a}dx}{\sqrt {a \sin (e+f x)+a} \sqrt {c-c \sin (e+f x)}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {a c \cos (e+f x) \int \frac {\cos (e+f x)}{\sin (e+f x) a+a}dx}{\sqrt {a \sin (e+f x)+a} \sqrt {c-c \sin (e+f x)}}\) |
\(\Big \downarrow \) 3146 |
\(\displaystyle \frac {c \cos (e+f x) \int \frac {1}{\sin (e+f x) a+a}d(a \sin (e+f x))}{f \sqrt {a \sin (e+f x)+a} \sqrt {c-c \sin (e+f x)}}\) |
\(\Big \downarrow \) 16 |
\(\displaystyle \frac {c \cos (e+f x) \log (a \sin (e+f x)+a)}{f \sqrt {a \sin (e+f x)+a} \sqrt {c-c \sin (e+f x)}}\) |
Input:
Int[Sqrt[c - c*Sin[e + f*x]]/Sqrt[a + a*Sin[e + f*x]],x]
Output:
(c*Cos[e + f*x]*Log[a + a*Sin[e + f*x]])/(f*Sqrt[a + a*Sin[e + f*x]]*Sqrt[ c - c*Sin[e + f*x]])
Int[(c_.)/((a_.) + (b_.)*(x_)), x_Symbol] :> Simp[c*(Log[RemoveContent[a + b*x, x]]/b), x] /; FreeQ[{a, b, c}, x]
Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m _.), x_Symbol] :> Simp[1/(b^p*f) Subst[Int[(a + x)^(m + (p - 1)/2)*(a - x )^((p - 1)/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x] && I ntegerQ[(p - 1)/2] && EqQ[a^2 - b^2, 0] && (GeQ[p, -1] || !IntegerQ[m + 1/ 2])
Int[Sqrt[(a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]]/Sqrt[(c_) + (d_.)*sin[(e_.) + (f_.)*(x_)]], x_Symbol] :> Simp[a*c*(Cos[e + f*x]/(Sqrt[a + b*Sin[e + f*x ]]*Sqrt[c + d*Sin[e + f*x]])) Int[Cos[e + f*x]/(c + d*Sin[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0 ]
Leaf count of result is larger than twice the leaf count of optimal. \(106\) vs. \(2(45)=90\).
Time = 1.73 (sec) , antiderivative size = 107, normalized size of antiderivative = 2.18
method | result | size |
default | \(-\frac {\tan \left (\frac {\pi }{4}+\frac {f x}{2}+\frac {e}{2}\right ) \left (\ln \left (\frac {2}{\cos \left (\frac {\pi }{4}+\frac {f x}{2}+\frac {e}{2}\right )+1}\right )-\ln \left (-\cot \left (\frac {\pi }{4}+\frac {f x}{2}+\frac {e}{2}\right )+\csc \left (\frac {\pi }{4}+\frac {f x}{2}+\frac {e}{2}\right )\right )\right ) \sqrt {c \cos \left (\frac {\pi }{4}+\frac {f x}{2}+\frac {e}{2}\right )^{2}}\, \sqrt {4}}{f \sqrt {a \sin \left (\frac {\pi }{4}+\frac {f x}{2}+\frac {e}{2}\right )^{2}}}\) | \(107\) |
Input:
int((c-c*sin(f*x+e))^(1/2)/(a+sin(f*x+e)*a)^(1/2),x,method=_RETURNVERBOSE)
Output:
-1/f*tan(1/4*Pi+1/2*f*x+1/2*e)*(ln(2/(cos(1/4*Pi+1/2*f*x+1/2*e)+1))-ln(-co t(1/4*Pi+1/2*f*x+1/2*e)+csc(1/4*Pi+1/2*f*x+1/2*e)))*(c*cos(1/4*Pi+1/2*f*x+ 1/2*e)^2)^(1/2)/(a*sin(1/4*Pi+1/2*f*x+1/2*e)^2)^(1/2)*4^(1/2)
\[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=\int { \frac {\sqrt {-c \sin \left (f x + e\right ) + c}}{\sqrt {a \sin \left (f x + e\right ) + a}} \,d x } \] Input:
integrate((c-c*sin(f*x+e))^(1/2)/(a+a*sin(f*x+e))^(1/2),x, algorithm="fric as")
Output:
integral(sqrt(-c*sin(f*x + e) + c)/sqrt(a*sin(f*x + e) + a), x)
\[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=\int \frac {\sqrt {- c \left (\sin {\left (e + f x \right )} - 1\right )}}{\sqrt {a \left (\sin {\left (e + f x \right )} + 1\right )}}\, dx \] Input:
integrate((c-c*sin(f*x+e))**(1/2)/(a+a*sin(f*x+e))**(1/2),x)
Output:
Integral(sqrt(-c*(sin(e + f*x) - 1))/sqrt(a*(sin(e + f*x) + 1)), x)
Time = 0.14 (sec) , antiderivative size = 64, normalized size of antiderivative = 1.31 \[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=-\frac {\frac {2 \, \sqrt {c} \log \left (\frac {\sin \left (f x + e\right )}{\cos \left (f x + e\right ) + 1} + 1\right )}{\sqrt {a}} - \frac {\sqrt {c} \log \left (\frac {\sin \left (f x + e\right )^{2}}{{\left (\cos \left (f x + e\right ) + 1\right )}^{2}} + 1\right )}{\sqrt {a}}}{f} \] Input:
integrate((c-c*sin(f*x+e))^(1/2)/(a+a*sin(f*x+e))^(1/2),x, algorithm="maxi ma")
Output:
-(2*sqrt(c)*log(sin(f*x + e)/(cos(f*x + e) + 1) + 1)/sqrt(a) - sqrt(c)*log (sin(f*x + e)^2/(cos(f*x + e) + 1)^2 + 1)/sqrt(a))/f
Time = 0.17 (sec) , antiderivative size = 59, normalized size of antiderivative = 1.20 \[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=-\frac {2 \, \sqrt {c} \log \left (\frac {2 \, {\left | \cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right ) \right |}}{{\left | f \right |}}\right ) \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )}{\sqrt {a} f \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )} \] Input:
integrate((c-c*sin(f*x+e))^(1/2)/(a+a*sin(f*x+e))^(1/2),x, algorithm="giac ")
Output:
-2*sqrt(c)*log(2*abs(cos(-1/4*pi + 1/2*f*x + 1/2*e))/abs(f))*sgn(sin(-1/4* pi + 1/2*f*x + 1/2*e))/(sqrt(a)*f*sgn(cos(-1/4*pi + 1/2*f*x + 1/2*e)))
Timed out. \[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=\int \frac {\sqrt {c-c\,\sin \left (e+f\,x\right )}}{\sqrt {a+a\,\sin \left (e+f\,x\right )}} \,d x \] Input:
int((c - c*sin(e + f*x))^(1/2)/(a + a*sin(e + f*x))^(1/2),x)
Output:
int((c - c*sin(e + f*x))^(1/2)/(a + a*sin(e + f*x))^(1/2), x)
\[ \int \frac {\sqrt {c-c \sin (e+f x)}}{\sqrt {a+a \sin (e+f x)}} \, dx=\frac {\sqrt {c}\, \sqrt {a}\, \left (\int \frac {\sqrt {\sin \left (f x +e \right )+1}\, \sqrt {-\sin \left (f x +e \right )+1}}{\sin \left (f x +e \right )+1}d x \right )}{a} \] Input:
int((c-c*sin(f*x+e))^(1/2)/(a+a*sin(f*x+e))^(1/2),x)
Output:
(sqrt(c)*sqrt(a)*int((sqrt(sin(e + f*x) + 1)*sqrt( - sin(e + f*x) + 1))/(s in(e + f*x) + 1),x))/a