Integrand size = 29, antiderivative size = 129 \[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=-\frac {2^{\frac {1}{2}+m} a \cos (e+f x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2}-m,\frac {3}{2},\frac {(c-d) (1-\sin (e+f x))}{2 (c+d \sin (e+f x))}\right ) (a+a \sin (e+f x))^{-1+m} \left (\frac {(c+d) (1+\sin (e+f x))}{c+d \sin (e+f x)}\right )^{\frac {1}{2}-m} (c+d \sin (e+f x))^{-m}}{(c+d) f} \] Output:
-2^(1/2+m)*a*cos(f*x+e)*hypergeom([1/2, 1/2-m],[3/2],(c-d)*(1-sin(f*x+e))/ (2*c+2*d*sin(f*x+e)))*(a+a*sin(f*x+e))^(-1+m)*((c+d)*(1+sin(f*x+e))/(c+d*s in(f*x+e)))^(1/2-m)/(c+d)/f/((c+d*sin(f*x+e))^m)
Result contains complex when optimal does not.
Time = 12.55 (sec) , antiderivative size = 352, normalized size of antiderivative = 2.73 \[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=\frac {\operatorname {Hypergeometric2F1}\left (1+m,1+2 m,2 (1+m),\frac {2 i d \sqrt {c^2-d^2} (\cos (e+f x)+i (1+\sin (e+f x)))}{\left (c-d+\sqrt {c^2-d^2}\right ) \left (-c+\sqrt {c^2-d^2}+i d \cos (e+f x)-d \sin (e+f x)\right )}\right ) (\cos (e+f x)-i \sin (e+f x)) (a (1+\sin (e+f x)))^m (1-i \cos (e+f x)+\sin (e+f x)) (c+d \sin (e+f x))^{-1-m} \left (c+\sqrt {c^2-d^2}-i d \cos (e+f x)+d \sin (e+f x)\right ) \left (\frac {\left (-c+d+\sqrt {c^2-d^2}\right ) \left (c+\sqrt {c^2-d^2}-i d \cos (e+f x)+d \sin (e+f x)\right )}{\left (c-d+\sqrt {c^2-d^2}\right ) \left (-c+\sqrt {c^2-d^2}+i d \cos (e+f x)-d \sin (e+f x)\right )}\right )^m}{\left (c-d+\sqrt {c^2-d^2}\right ) f (1+2 m)} \] Input:
Integrate[(a + a*Sin[e + f*x])^m*(c + d*Sin[e + f*x])^(-1 - m),x]
Output:
(Hypergeometric2F1[1 + m, 1 + 2*m, 2*(1 + m), ((2*I)*d*Sqrt[c^2 - d^2]*(Co s[e + f*x] + I*(1 + Sin[e + f*x])))/((c - d + Sqrt[c^2 - d^2])*(-c + Sqrt[ c^2 - d^2] + I*d*Cos[e + f*x] - d*Sin[e + f*x]))]*(Cos[e + f*x] - I*Sin[e + f*x])*(a*(1 + Sin[e + f*x]))^m*(1 - I*Cos[e + f*x] + Sin[e + f*x])*(c + d*Sin[e + f*x])^(-1 - m)*(c + Sqrt[c^2 - d^2] - I*d*Cos[e + f*x] + d*Sin[e + f*x])*(((-c + d + Sqrt[c^2 - d^2])*(c + Sqrt[c^2 - d^2] - I*d*Cos[e + f *x] + d*Sin[e + f*x]))/((c - d + Sqrt[c^2 - d^2])*(-c + Sqrt[c^2 - d^2] + I*d*Cos[e + f*x] - d*Sin[e + f*x])))^m)/((c - d + Sqrt[c^2 - d^2])*f*(1 + 2*m))
Time = 0.34 (sec) , antiderivative size = 129, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.103, Rules used = {3042, 3267, 142}
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 (a \sin (e+f x)+a)^m (c+d \sin (e+f x))^{-m-1} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int (a \sin (e+f x)+a)^m (c+d \sin (e+f x))^{-m-1}dx\) |
\(\Big \downarrow \) 3267 |
\(\displaystyle \frac {a^2 \cos (e+f x) \int \frac {(\sin (e+f x) a+a)^{m-\frac {1}{2}} (c+d \sin (e+f x))^{-m-1}}{\sqrt {a-a \sin (e+f x)}}d\sin (e+f x)}{f \sqrt {a-a \sin (e+f x)} \sqrt {a \sin (e+f x)+a}}\) |
\(\Big \downarrow \) 142 |
\(\displaystyle -\frac {a 2^{m+\frac {1}{2}} \cos (e+f x) (a \sin (e+f x)+a)^{m-1} \left (\frac {(c+d) (\sin (e+f x)+1)}{c+d \sin (e+f x)}\right )^{\frac {1}{2}-m} (c+d \sin (e+f x))^{-m} \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2}-m,\frac {3}{2},\frac {(c-d) (1-\sin (e+f x))}{2 (c+d \sin (e+f x))}\right )}{f (c+d)}\) |
Input:
Int[(a + a*Sin[e + f*x])^m*(c + d*Sin[e + f*x])^(-1 - m),x]
Output:
-((2^(1/2 + m)*a*Cos[e + f*x]*Hypergeometric2F1[1/2, 1/2 - m, 3/2, ((c - d )*(1 - Sin[e + f*x]))/(2*(c + d*Sin[e + f*x]))]*(a + a*Sin[e + f*x])^(-1 + m)*(((c + d)*(1 + Sin[e + f*x]))/(c + d*Sin[e + f*x]))^(1/2 - m))/((c + d )*f*(c + d*Sin[e + f*x])^m))
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) )^(p_), x_] :> Simp[((a + b*x)^(m + 1)*(c + d*x)^n*((e + f*x)^(p + 1)/((b*e - a*f)*(m + 1)))*Hypergeometric2F1[m + 1, -n, m + 2, (-(d*e - c*f))*((a + b*x)/((b*c - a*d)*(e + f*x)))])/((b*e - a*f)*((c + d*x)/((b*c - a*d)*(e + f *x))))^n, x] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && EqQ[m + n + p + 2, 0] && !IntegerQ[n]
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*sin[(e_.) + ( f_.)*(x_)])^(n_.), x_Symbol] :> Simp[a^2*(Cos[e + f*x]/(f*Sqrt[a + b*Sin[e + f*x]]*Sqrt[a - b*Sin[e + f*x]])) Subst[Int[(a + b*x)^(m - 1/2)*((c + d* x)^n/Sqrt[a - b*x]), x], x, Sin[e + f*x]], x] /; FreeQ[{a, b, c, d, e, f, m , n}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && !IntegerQ[m]
\[\int \left (a +a \sin \left (f x +e \right )\right )^{m} \left (c +d \sin \left (f x +e \right )\right )^{-1-m}d x\]
Input:
int((a+a*sin(f*x+e))^m*(c+d*sin(f*x+e))^(-1-m),x)
Output:
int((a+a*sin(f*x+e))^m*(c+d*sin(f*x+e))^(-1-m),x)
\[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=\int { {\left (a \sin \left (f x + e\right ) + a\right )}^{m} {\left (d \sin \left (f x + e\right ) + c\right )}^{-m - 1} \,d x } \] Input:
integrate((a+a*sin(f*x+e))^m*(c+d*sin(f*x+e))^(-1-m),x, algorithm="fricas" )
Output:
integral((a*sin(f*x + e) + a)^m*(d*sin(f*x + e) + c)^(-m - 1), x)
\[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=\int \left (a \left (\sin {\left (e + f x \right )} + 1\right )\right )^{m} \left (c + d \sin {\left (e + f x \right )}\right )^{- m - 1}\, dx \] Input:
integrate((a+a*sin(f*x+e))**m*(c+d*sin(f*x+e))**(-1-m),x)
Output:
Integral((a*(sin(e + f*x) + 1))**m*(c + d*sin(e + f*x))**(-m - 1), x)
\[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=\int { {\left (a \sin \left (f x + e\right ) + a\right )}^{m} {\left (d \sin \left (f x + e\right ) + c\right )}^{-m - 1} \,d x } \] Input:
integrate((a+a*sin(f*x+e))^m*(c+d*sin(f*x+e))^(-1-m),x, algorithm="maxima" )
Output:
integrate((a*sin(f*x + e) + a)^m*(d*sin(f*x + e) + c)^(-m - 1), x)
\[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=\int { {\left (a \sin \left (f x + e\right ) + a\right )}^{m} {\left (d \sin \left (f x + e\right ) + c\right )}^{-m - 1} \,d x } \] Input:
integrate((a+a*sin(f*x+e))^m*(c+d*sin(f*x+e))^(-1-m),x, algorithm="giac")
Output:
integrate((a*sin(f*x + e) + a)^m*(d*sin(f*x + e) + c)^(-m - 1), x)
Timed out. \[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=\int \frac {{\left (a+a\,\sin \left (e+f\,x\right )\right )}^m}{{\left (c+d\,\sin \left (e+f\,x\right )\right )}^{m+1}} \,d x \] Input:
int((a + a*sin(e + f*x))^m/(c + d*sin(e + f*x))^(m + 1),x)
Output:
int((a + a*sin(e + f*x))^m/(c + d*sin(e + f*x))^(m + 1), x)
\[ \int (a+a \sin (e+f x))^m (c+d \sin (e+f x))^{-1-m} \, dx=\int \frac {\left (a +a \sin \left (f x +e \right )\right )^{m}}{\left (\sin \left (f x +e \right ) d +c \right )^{m} \sin \left (f x +e \right ) d +\left (\sin \left (f x +e \right ) d +c \right )^{m} c}d x \] Input:
int((a+a*sin(f*x+e))^m*(c+d*sin(f*x+e))^(-1-m),x)
Output:
int((sin(e + f*x)*a + a)**m/((sin(e + f*x)*d + c)**m*sin(e + f*x)*d + (sin (e + f*x)*d + c)**m*c),x)