Integrand size = 27, antiderivative size = 299 \[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=-\frac {a^3 (7+2 n p) \cos (e+f x) \sin (e+f x) \left (c (d \sin (e+f x))^p\right )^n}{f (2+n p) (3+n p)}+\frac {a^3 (5+4 n p) \cos (e+f x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (1+n p),\frac {1}{2} (3+n p),\sin ^2(e+f x)\right ) \sin (e+f x) \left (c (d \sin (e+f x))^p\right )^n}{f (1+n p) (2+n p) \sqrt {\cos ^2(e+f x)}}+\frac {a^3 (11+4 n p) \cos (e+f x) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (2+n p),\frac {1}{2} (4+n p),\sin ^2(e+f x)\right ) \sin ^2(e+f x) \left (c (d \sin (e+f x))^p\right )^n}{f (2+n p) (3+n p) \sqrt {\cos ^2(e+f x)}}-\frac {\cos (e+f x) \sin (e+f x) \left (c (d \sin (e+f x))^p\right )^n \left (a^3+a^3 \sin (e+f x)\right )}{f (3+n p)} \] Output:
-a^3*(2*n*p+7)*cos(f*x+e)*sin(f*x+e)*(c*(d*sin(f*x+e))^p)^n/f/(n*p+2)/(n*p +3)+a^3*(4*n*p+5)*cos(f*x+e)*hypergeom([1/2, 1/2*n*p+1/2],[1/2*n*p+3/2],si n(f*x+e)^2)*sin(f*x+e)*(c*(d*sin(f*x+e))^p)^n/f/(n*p+1)/(n*p+2)/(cos(f*x+e )^2)^(1/2)+a^3*(4*n*p+11)*cos(f*x+e)*hypergeom([1/2, 1/2*n*p+1],[1/2*n*p+2 ],sin(f*x+e)^2)*sin(f*x+e)^2*(c*(d*sin(f*x+e))^p)^n/f/(n*p+2)/(n*p+3)/(cos (f*x+e)^2)^(1/2)-cos(f*x+e)*sin(f*x+e)*(c*(d*sin(f*x+e))^p)^n*(a^3+a^3*sin (f*x+e))/f/(n*p+3)
Time = 1.01 (sec) , antiderivative size = 297, normalized size of antiderivative = 0.99 \[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=-\frac {a^3 \cos (e+f x) \sqrt {\cos ^2(e+f x)} \sin (e+f x) \left (c (d \sin (e+f x))^p\right )^n \left (\left (24+26 n p+9 n^2 p^2+n^3 p^3\right ) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (1+n p),\frac {1}{2} (3+n p),\sin ^2(e+f x)\right )+\frac {1}{2} (1+n p) \sin (e+f x) \left (6 \left (12+7 n p+n^2 p^2\right ) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},1+\frac {n p}{2},2+\frac {n p}{2},\sin ^2(e+f x)\right )+2 (2+n p) \sin (e+f x) \left (3 (4+n p) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (3+n p),\frac {1}{2} (5+n p),\sin ^2(e+f x)\right )+(3+n p) \operatorname {Hypergeometric2F1}\left (\frac {1}{2},2+\frac {n p}{2},3+\frac {n p}{2},\sin ^2(e+f x)\right ) \sin (e+f x)\right )\right )\right )}{f (1+n p) (2+n p) (3+n p) (4+n p) (-1+\sin (e+f x)) (1+\sin (e+f x))} \] Input:
Integrate[(c*(d*Sin[e + f*x])^p)^n*(a + a*Sin[e + f*x])^3,x]
Output:
-((a^3*Cos[e + f*x]*Sqrt[Cos[e + f*x]^2]*Sin[e + f*x]*(c*(d*Sin[e + f*x])^ p)^n*((24 + 26*n*p + 9*n^2*p^2 + n^3*p^3)*Hypergeometric2F1[1/2, (1 + n*p) /2, (3 + n*p)/2, Sin[e + f*x]^2] + ((1 + n*p)*Sin[e + f*x]*(6*(12 + 7*n*p + n^2*p^2)*Hypergeometric2F1[1/2, 1 + (n*p)/2, 2 + (n*p)/2, Sin[e + f*x]^2 ] + 2*(2 + n*p)*Sin[e + f*x]*(3*(4 + n*p)*Hypergeometric2F1[1/2, (3 + n*p) /2, (5 + n*p)/2, Sin[e + f*x]^2] + (3 + n*p)*Hypergeometric2F1[1/2, 2 + (n *p)/2, 3 + (n*p)/2, Sin[e + f*x]^2]*Sin[e + f*x])))/2))/(f*(1 + n*p)*(2 + n*p)*(3 + n*p)*(4 + n*p)*(-1 + Sin[e + f*x])*(1 + Sin[e + f*x])))
Time = 1.20 (sec) , antiderivative size = 306, normalized size of antiderivative = 1.02, number of steps used = 12, number of rules used = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.444, Rules used = {3042, 3305, 3042, 3242, 3042, 3447, 3042, 3502, 3042, 3227, 3042, 3122}
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)^3 \left (c (d \sin (e+f x))^p\right )^n \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int (a \sin (e+f x)+a)^3 \left (c (d \sin (e+f x))^p\right )^ndx\) |
\(\Big \downarrow \) 3305 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \int (d \sin (e+f x))^{n p} (\sin (e+f x) a+a)^3dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \int (d \sin (e+f x))^{n p} (\sin (e+f x) a+a)^3dx\) |
\(\Big \downarrow \) 3242 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\int (d \sin (e+f x))^{n p} (\sin (e+f x) a+a) \left (2 d (n p+2) a^2+d (2 n p+7) \sin (e+f x) a^2\right )dx}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\int (d \sin (e+f x))^{n p} (\sin (e+f x) a+a) \left (2 d (n p+2) a^2+d (2 n p+7) \sin (e+f x) a^2\right )dx}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3447 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\int (d \sin (e+f x))^{n p} \left (d (2 n p+7) \sin ^2(e+f x) a^3+2 d (n p+2) a^3+\left (2 d (n p+2) a^3+d (2 n p+7) a^3\right ) \sin (e+f x)\right )dx}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\int (d \sin (e+f x))^{n p} \left (d (2 n p+7) \sin (e+f x)^2 a^3+2 d (n p+2) a^3+\left (2 d (n p+2) a^3+d (2 n p+7) a^3\right ) \sin (e+f x)\right )dx}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3502 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\frac {\int (d \sin (e+f x))^{n p} \left (d^2 (n p+3) (4 n p+5) a^3+d^2 (n p+2) (4 n p+11) \sin (e+f x) a^3\right )dx}{d (n p+2)}-\frac {a^3 (2 n p+7) \cos (e+f x) (d \sin (e+f x))^{n p+1}}{f (n p+2)}}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\frac {\int (d \sin (e+f x))^{n p} \left (d^2 (n p+3) (4 n p+5) a^3+d^2 (n p+2) (4 n p+11) \sin (e+f x) a^3\right )dx}{d (n p+2)}-\frac {a^3 (2 n p+7) \cos (e+f x) (d \sin (e+f x))^{n p+1}}{f (n p+2)}}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3227 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\frac {a^3 d^2 (n p+3) (4 n p+5) \int (d \sin (e+f x))^{n p}dx+a^3 d (n p+2) (4 n p+11) \int (d \sin (e+f x))^{n p+1}dx}{d (n p+2)}-\frac {a^3 (2 n p+7) \cos (e+f x) (d \sin (e+f x))^{n p+1}}{f (n p+2)}}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\frac {a^3 d^2 (n p+3) (4 n p+5) \int (d \sin (e+f x))^{n p}dx+a^3 d (n p+2) (4 n p+11) \int (d \sin (e+f x))^{n p+1}dx}{d (n p+2)}-\frac {a^3 (2 n p+7) \cos (e+f x) (d \sin (e+f x))^{n p+1}}{f (n p+2)}}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
\(\Big \downarrow \) 3122 |
\(\displaystyle (d \sin (e+f x))^{-n p} \left (c (d \sin (e+f x))^p\right )^n \left (\frac {\frac {\frac {a^3 d (n p+3) (4 n p+5) \cos (e+f x) (d \sin (e+f x))^{n p+1} \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (n p+1),\frac {1}{2} (n p+3),\sin ^2(e+f x)\right )}{f (n p+1) \sqrt {\cos ^2(e+f x)}}+\frac {a^3 (4 n p+11) \cos (e+f x) (d \sin (e+f x))^{n p+2} \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {1}{2} (n p+2),\frac {1}{2} (n p+4),\sin ^2(e+f x)\right )}{f \sqrt {\cos ^2(e+f x)}}}{d (n p+2)}-\frac {a^3 (2 n p+7) \cos (e+f x) (d \sin (e+f x))^{n p+1}}{f (n p+2)}}{d (n p+3)}-\frac {\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (d \sin (e+f x))^{n p+1}}{d f (n p+3)}\right )\) |
Input:
Int[(c*(d*Sin[e + f*x])^p)^n*(a + a*Sin[e + f*x])^3,x]
Output:
((c*(d*Sin[e + f*x])^p)^n*(-((Cos[e + f*x]*(d*Sin[e + f*x])^(1 + n*p)*(a^3 + a^3*Sin[e + f*x]))/(d*f*(3 + n*p))) + (-((a^3*(7 + 2*n*p)*Cos[e + f*x]* (d*Sin[e + f*x])^(1 + n*p))/(f*(2 + n*p))) + ((a^3*d*(3 + n*p)*(5 + 4*n*p) *Cos[e + f*x]*Hypergeometric2F1[1/2, (1 + n*p)/2, (3 + n*p)/2, Sin[e + f*x ]^2]*(d*Sin[e + f*x])^(1 + n*p))/(f*(1 + n*p)*Sqrt[Cos[e + f*x]^2]) + (a^3 *(11 + 4*n*p)*Cos[e + f*x]*Hypergeometric2F1[1/2, (2 + n*p)/2, (4 + n*p)/2 , Sin[e + f*x]^2]*(d*Sin[e + f*x])^(2 + n*p))/(f*Sqrt[Cos[e + f*x]^2]))/(d *(2 + n*p)))/(d*(3 + n*p))))/(d*Sin[e + f*x])^(n*p)
Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[Cos[c + d*x]*(( b*Sin[c + d*x])^(n + 1)/(b*d*(n + 1)*Sqrt[Cos[c + d*x]^2]))*Hypergeometric2 F1[1/2, (n + 1)/2, (n + 3)/2, Sin[c + d*x]^2], x] /; FreeQ[{b, c, d, n}, x] && !IntegerQ[2*n]
Int[((b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*sin[(e_.) + (f_.)*(x _)]), x_Symbol] :> Simp[c Int[(b*Sin[e + f*x])^m, x], x] + Simp[d/b Int [(b*Sin[e + f*x])^(m + 1), x], x] /; FreeQ[{b, c, d, e, f, m}, x]
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Simp[(-b^2)*Cos[e + f*x]*(a + b*Sin[e + f*x ])^(m - 2)*((c + d*Sin[e + f*x])^(n + 1)/(d*f*(m + n))), x] + Simp[1/(d*(m + n)) Int[(a + b*Sin[e + f*x])^(m - 2)*(c + d*Sin[e + f*x])^n*Simp[a*b*c* (m - 2) + b^2*d*(n + 1) + a^2*d*(m + n) - b*(b*c*(m - 1) - a*d*(3*m + 2*n - 2))*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f, n}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && GtQ[m, 1] && !LtQ[ n, -1] && (IntegersQ[2*m, 2*n] || IntegerQ[m + 1/2] || (IntegerQ[m] && EqQ[ c, 0]))
Int[((c_.)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(p_))^(n_)*((a_.) + (b_.)*sin[(e _.) + (f_.)*(x_)])^(m_.), x_Symbol] :> Simp[c^IntPart[n]*((c*(d*Sin[e + f*x ])^p)^FracPart[n]/(d*Sin[e + f*x])^(p*FracPart[n])) Int[(a + b*Sin[e + f* x])^m*(d*Sin[e + f*x])^(n*p), x], x] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && !IntegerQ[n]
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Int[(a + b*Sin[e + f*x])^m*(A*c + (B*c + A*d)*Sin[e + f*x] + B*d*Sin[e + f*x]^2), x] /; FreeQ[{a, b, c, d, e, f, A, B, m}, x] && NeQ[b*c - a*d, 0]
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)] + (C_.)*sin[(e_.) + (f_.)*(x_)]^2), x_Symbol] :> Simp[(-C)*Co s[e + f*x]*((a + b*Sin[e + f*x])^(m + 1)/(b*f*(m + 2))), x] + Simp[1/(b*(m + 2)) Int[(a + b*Sin[e + f*x])^m*Simp[A*b*(m + 2) + b*C*(m + 1) + (b*B*(m + 2) - a*C)*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, e, f, A, B, C, m}, x] && !LtQ[m, -1]
\[\int \left (c \left (d \sin \left (f x +e \right )\right )^{p}\right )^{n} \left (a +a \sin \left (f x +e \right )\right )^{3}d x\]
Input:
int((c*(d*sin(f*x+e))^p)^n*(a+a*sin(f*x+e))^3,x)
Output:
int((c*(d*sin(f*x+e))^p)^n*(a+a*sin(f*x+e))^3,x)
\[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=\int { {\left (a \sin \left (f x + e\right ) + a\right )}^{3} \left (\left (d \sin \left (f x + e\right )\right )^{p} c\right )^{n} \,d x } \] Input:
integrate((c*(d*sin(f*x+e))^p)^n*(a+a*sin(f*x+e))^3,x, algorithm="fricas")
Output:
integral(-(3*a^3*cos(f*x + e)^2 - 4*a^3 + (a^3*cos(f*x + e)^2 - 4*a^3)*sin (f*x + e))*((d*sin(f*x + e))^p*c)^n, x)
\[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=a^{3} \left (\int \left (c \left (d \sin {\left (e + f x \right )}\right )^{p}\right )^{n}\, dx + \int 3 \left (c \left (d \sin {\left (e + f x \right )}\right )^{p}\right )^{n} \sin {\left (e + f x \right )}\, dx + \int 3 \left (c \left (d \sin {\left (e + f x \right )}\right )^{p}\right )^{n} \sin ^{2}{\left (e + f x \right )}\, dx + \int \left (c \left (d \sin {\left (e + f x \right )}\right )^{p}\right )^{n} \sin ^{3}{\left (e + f x \right )}\, dx\right ) \] Input:
integrate((c*(d*sin(f*x+e))**p)**n*(a+a*sin(f*x+e))**3,x)
Output:
a**3*(Integral((c*(d*sin(e + f*x))**p)**n, x) + Integral(3*(c*(d*sin(e + f *x))**p)**n*sin(e + f*x), x) + Integral(3*(c*(d*sin(e + f*x))**p)**n*sin(e + f*x)**2, x) + Integral((c*(d*sin(e + f*x))**p)**n*sin(e + f*x)**3, x))
\[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=\int { {\left (a \sin \left (f x + e\right ) + a\right )}^{3} \left (\left (d \sin \left (f x + e\right )\right )^{p} c\right )^{n} \,d x } \] Input:
integrate((c*(d*sin(f*x+e))^p)^n*(a+a*sin(f*x+e))^3,x, algorithm="maxima")
Output:
integrate((a*sin(f*x + e) + a)^3*((d*sin(f*x + e))^p*c)^n, x)
\[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=\int { {\left (a \sin \left (f x + e\right ) + a\right )}^{3} \left (\left (d \sin \left (f x + e\right )\right )^{p} c\right )^{n} \,d x } \] Input:
integrate((c*(d*sin(f*x+e))^p)^n*(a+a*sin(f*x+e))^3,x, algorithm="giac")
Output:
integrate((a*sin(f*x + e) + a)^3*((d*sin(f*x + e))^p*c)^n, x)
Timed out. \[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=\int {\left (c\,{\left (d\,\sin \left (e+f\,x\right )\right )}^p\right )}^n\,{\left (a+a\,\sin \left (e+f\,x\right )\right )}^3 \,d x \] Input:
int((c*(d*sin(e + f*x))^p)^n*(a + a*sin(e + f*x))^3,x)
Output:
int((c*(d*sin(e + f*x))^p)^n*(a + a*sin(e + f*x))^3, x)
\[ \int \left (c (d \sin (e+f x))^p\right )^n (a+a \sin (e+f x))^3 \, dx=d^{n p} c^{n} a^{3} \left (\int \sin \left (f x +e \right )^{n p}d x +\int \sin \left (f x +e \right )^{n p} \sin \left (f x +e \right )^{3}d x +3 \left (\int \sin \left (f x +e \right )^{n p} \sin \left (f x +e \right )^{2}d x \right )+3 \left (\int \sin \left (f x +e \right )^{n p} \sin \left (f x +e \right )d x \right )\right ) \] Input:
int((c*(d*sin(f*x+e))^p)^n*(a+a*sin(f*x+e))^3,x)
Output:
d**(n*p)*c**n*a**3*(int(sin(e + f*x)**(n*p),x) + int(sin(e + f*x)**(n*p)*s in(e + f*x)**3,x) + 3*int(sin(e + f*x)**(n*p)*sin(e + f*x)**2,x) + 3*int(s in(e + f*x)**(n*p)*sin(e + f*x),x))