Integrand size = 23, antiderivative size = 135 \[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=-\frac {7 \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {a+a \sin (c+d x)}}\right )}{8 \sqrt {a} d}+\frac {9 \cot (c+d x)}{8 d \sqrt {a+a \sin (c+d x)}}+\frac {\cot (c+d x) \csc (c+d x)}{12 d \sqrt {a+a \sin (c+d x)}}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a+a \sin (c+d x)}} \] Output:
-7/8*arctanh(a^(1/2)*cos(d*x+c)/(a+a*sin(d*x+c))^(1/2))/a^(1/2)/d+9/8*cot( d*x+c)/d/(a+a*sin(d*x+c))^(1/2)+1/12*cot(d*x+c)*csc(d*x+c)/d/(a+a*sin(d*x+ c))^(1/2)-1/3*cot(d*x+c)*csc(d*x+c)^2/d/(a+a*sin(d*x+c))^(1/2)
Leaf count is larger than twice the leaf count of optimal. \(292\) vs. \(2(135)=270\).
Time = 1.21 (sec) , antiderivative size = 292, normalized size of antiderivative = 2.16 \[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=\frac {\csc ^9\left (\frac {1}{2} (c+d x)\right ) \left (\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right ) \left (36 \cos \left (\frac {1}{2} (c+d x)\right )-46 \cos \left (\frac {3}{2} (c+d x)\right )-54 \cos \left (\frac {5}{2} (c+d x)\right )-36 \sin \left (\frac {1}{2} (c+d x)\right )-63 \log \left (1+\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right ) \sin (c+d x)+63 \log \left (1-\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right ) \sin (c+d x)-46 \sin \left (\frac {3}{2} (c+d x)\right )+54 \sin \left (\frac {5}{2} (c+d x)\right )+21 \log \left (1+\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right ) \sin (3 (c+d x))-21 \log \left (1-\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right ) \sin (3 (c+d x))\right )}{24 d \left (\csc ^2\left (\frac {1}{4} (c+d x)\right )-\sec ^2\left (\frac {1}{4} (c+d x)\right )\right )^3 \sqrt {a (1+\sin (c+d x))}} \] Input:
Integrate[Cot[c + d*x]^4/Sqrt[a + a*Sin[c + d*x]],x]
Output:
(Csc[(c + d*x)/2]^9*(Cos[(c + d*x)/2] + Sin[(c + d*x)/2])*(36*Cos[(c + d*x )/2] - 46*Cos[(3*(c + d*x))/2] - 54*Cos[(5*(c + d*x))/2] - 36*Sin[(c + d*x )/2] - 63*Log[1 + Cos[(c + d*x)/2] - Sin[(c + d*x)/2]]*Sin[c + d*x] + 63*L og[1 - Cos[(c + d*x)/2] + Sin[(c + d*x)/2]]*Sin[c + d*x] - 46*Sin[(3*(c + d*x))/2] + 54*Sin[(5*(c + d*x))/2] + 21*Log[1 + Cos[(c + d*x)/2] - Sin[(c + d*x)/2]]*Sin[3*(c + d*x)] - 21*Log[1 - Cos[(c + d*x)/2] + Sin[(c + d*x)/ 2]]*Sin[3*(c + d*x)]))/(24*d*(Csc[(c + d*x)/4]^2 - Sec[(c + d*x)/4]^2)^3*S qrt[a*(1 + Sin[c + d*x])])
Time = 1.53 (sec) , antiderivative size = 253, normalized size of antiderivative = 1.87, number of steps used = 21, number of rules used = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.870, Rules used = {3042, 3197, 3042, 3128, 219, 3523, 27, 3042, 3463, 27, 3042, 3463, 27, 3042, 3464, 3042, 3128, 219, 3252, 219}
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 {\cot ^4(c+d x)}{\sqrt {a \sin (c+d x)+a}} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {1}{\tan (c+d x)^4 \sqrt {a \sin (c+d x)+a}}dx\) |
\(\Big \downarrow \) 3197 |
\(\displaystyle \int \frac {1}{\sqrt {\sin (c+d x) a+a}}dx+\int \frac {\csc ^4(c+d x) \left (1-2 \sin ^2(c+d x)\right )}{\sqrt {\sin (c+d x) a+a}}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {1}{\sqrt {\sin (c+d x) a+a}}dx+\int \frac {1-2 \sin (c+d x)^2}{\sin (c+d x)^4 \sqrt {\sin (c+d x) a+a}}dx\) |
\(\Big \downarrow \) 3128 |
\(\displaystyle \int \frac {1-2 \sin (c+d x)^2}{\sin (c+d x)^4 \sqrt {\sin (c+d x) a+a}}dx-\frac {2 \int \frac {1}{2 a-\frac {a^2 \cos ^2(c+d x)}{\sin (c+d x) a+a}}d\frac {a \cos (c+d x)}{\sqrt {\sin (c+d x) a+a}}}{d}\) |
\(\Big \downarrow \) 219 |
\(\displaystyle \int \frac {1-2 \sin (c+d x)^2}{\sin (c+d x)^4 \sqrt {\sin (c+d x) a+a}}dx-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}\) |
\(\Big \downarrow \) 3523 |
\(\displaystyle \frac {\int -\frac {\csc ^3(c+d x) (7 \sin (c+d x) a+a)}{2 \sqrt {\sin (c+d x) a+a}}dx}{3 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\frac {\int \frac {\csc ^3(c+d x) (7 \sin (c+d x) a+a)}{\sqrt {\sin (c+d x) a+a}}dx}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\int \frac {7 \sin (c+d x) a+a}{\sin (c+d x)^3 \sqrt {\sin (c+d x) a+a}}dx}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3463 |
\(\displaystyle -\frac {\frac {\int \frac {3 \csc ^2(c+d x) \left (\sin (c+d x) a^2+9 a^2\right )}{2 \sqrt {\sin (c+d x) a+a}}dx}{2 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\frac {\frac {3 \int \frac {\csc ^2(c+d x) \left (\sin (c+d x) a^2+9 a^2\right )}{\sqrt {\sin (c+d x) a+a}}dx}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {3 \int \frac {\sin (c+d x) a^2+9 a^2}{\sin (c+d x)^2 \sqrt {\sin (c+d x) a+a}}dx}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3463 |
\(\displaystyle -\frac {\frac {3 \left (\frac {\int -\frac {\csc (c+d x) \left (7 a^3-9 a^3 \sin (c+d x)\right )}{2 \sqrt {\sin (c+d x) a+a}}dx}{a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {\int \frac {\csc (c+d x) \left (7 a^3-9 a^3 \sin (c+d x)\right )}{\sqrt {\sin (c+d x) a+a}}dx}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {\int \frac {7 a^3-9 a^3 \sin (c+d x)}{\sin (c+d x) \sqrt {\sin (c+d x) a+a}}dx}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3464 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {7 a^2 \int \csc (c+d x) \sqrt {\sin (c+d x) a+a}dx-16 a^3 \int \frac {1}{\sqrt {\sin (c+d x) a+a}}dx}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {7 a^2 \int \frac {\sqrt {\sin (c+d x) a+a}}{\sin (c+d x)}dx-16 a^3 \int \frac {1}{\sqrt {\sin (c+d x) a+a}}dx}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3128 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {7 a^2 \int \frac {\sqrt {\sin (c+d x) a+a}}{\sin (c+d x)}dx+\frac {32 a^3 \int \frac {1}{2 a-\frac {a^2 \cos ^2(c+d x)}{\sin (c+d x) a+a}}d\frac {a \cos (c+d x)}{\sqrt {\sin (c+d x) a+a}}}{d}}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 219 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {7 a^2 \int \frac {\sqrt {\sin (c+d x) a+a}}{\sin (c+d x)}dx+\frac {16 \sqrt {2} a^{5/2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{d}}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 3252 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {\frac {16 \sqrt {2} a^{5/2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{d}-\frac {14 a^3 \int \frac {1}{a-\frac {a^2 \cos ^2(c+d x)}{\sin (c+d x) a+a}}d\frac {a \cos (c+d x)}{\sqrt {\sin (c+d x) a+a}}}{d}}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
\(\Big \downarrow \) 219 |
\(\displaystyle -\frac {\frac {3 \left (-\frac {\frac {16 \sqrt {2} a^{5/2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{d}-\frac {14 a^{5/2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {a \sin (c+d x)+a}}\right )}{d}}{2 a}-\frac {9 a^2 \cot (c+d x)}{d \sqrt {a \sin (c+d x)+a}}\right )}{4 a}-\frac {a \cot (c+d x) \csc (c+d x)}{2 d \sqrt {a \sin (c+d x)+a}}}{6 a}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {a} \cos (c+d x)}{\sqrt {2} \sqrt {a \sin (c+d x)+a}}\right )}{\sqrt {a} d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d \sqrt {a \sin (c+d x)+a}}\) |
Input:
Int[Cot[c + d*x]^4/Sqrt[a + a*Sin[c + d*x]],x]
Output:
-((Sqrt[2]*ArcTanh[(Sqrt[a]*Cos[c + d*x])/(Sqrt[2]*Sqrt[a + a*Sin[c + d*x] ])])/(Sqrt[a]*d)) - (Cot[c + d*x]*Csc[c + d*x]^2)/(3*d*Sqrt[a + a*Sin[c + d*x]]) - (-1/2*(a*Cot[c + d*x]*Csc[c + d*x])/(d*Sqrt[a + a*Sin[c + d*x]]) + (3*(-1/2*((-14*a^(5/2)*ArcTanh[(Sqrt[a]*Cos[c + d*x])/Sqrt[a + a*Sin[c + d*x]]])/d + (16*Sqrt[2]*a^(5/2)*ArcTanh[(Sqrt[a]*Cos[c + d*x])/(Sqrt[2]*S qrt[a + a*Sin[c + d*x]])])/d)/a - (9*a^2*Cot[c + d*x])/(d*Sqrt[a + a*Sin[c + d*x]])))/(4*a))/(6*a)
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))* ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt Q[a, 0] || LtQ[b, 0])
Int[1/Sqrt[(a_) + (b_.)*sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[-2/d Subst[Int[1/(2*a - x^2), x], x, b*(Cos[c + d*x]/Sqrt[a + b*Sin[c + d*x]])], x] /; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)/tan[(e_.) + (f_.)*(x_)]^4, x_Symbol] :> Int[(a + b*Sin[e + f*x])^m, x] + Int[(a + b*Sin[e + f*x])^m*(( 1 - 2*Sin[e + f*x]^2)/Sin[e + f*x]^4), x] /; FreeQ[{a, b, e, f, m}, x] && E qQ[a^2 - b^2, 0] && IntegerQ[m - 1/2] && !LtQ[m, -1]
Int[Sqrt[(a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]]/((c_.) + (d_.)*sin[(e_.) + ( f_.)*(x_)]), x_Symbol] :> Simp[-2*(b/f) Subst[Int[1/(b*c + a*d - d*x^2), x], x, b*(Cos[e + f*x]/Sqrt[a + b*Sin[e + f*x]])], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0]
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Sim p[(B*c - A*d)*Cos[e + f*x]*(a + b*Sin[e + f*x])^m*((c + d*Sin[e + f*x])^(n + 1)/(f*(n + 1)*(c^2 - d^2))), x] + Simp[1/(b*(n + 1)*(c^2 - d^2)) Int[(a + b*Sin[e + f*x])^m*(c + d*Sin[e + f*x])^(n + 1)*Simp[A*(a*d*m + b*c*(n + 1)) - B*(a*c*m + b*d*(n + 1)) + b*(B*c - A*d)*(m + n + 2)*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f, A, B, m}, x] && NeQ[b*c - a*d, 0] && Eq Q[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && LtQ[n, -1] && (IntegerQ[n] || EqQ[m + 1/2, 0])
Int[((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)])/(Sqrt[(a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]]*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])), x_Symbol] :> Simp[(A *b - a*B)/(b*c - a*d) Int[1/Sqrt[a + b*Sin[e + f*x]], x], x] + Simp[(B*c - A*d)/(b*c - a*d) Int[Sqrt[a + b*Sin[e + f*x]]/(c + d*Sin[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f, A, B}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0]
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_)*((A_.) + (C_.)*sin[(e_.) + (f_.)*(x_)]^2), x_Symbol] :> Simp[(-(c^2*C + A*d^2))*Cos[e + f*x]*(a + b*Sin[e + f*x])^m*((c + d*Sin[e + f*x])^(n + 1)/(d*f*(n + 1)*(c^2 - d^2))), x] + Simp[1/(b*d*(n + 1)*(c^2 - d^2)) Int[(a + b*Sin[e + f*x])^m*(c + d*Sin[e + f*x])^(n + 1)*Simp[A*d*(a *d*m + b*c*(n + 1)) + c*C*(a*c*m + b*d*(n + 1)) - b*(A*d^2*(m + n + 2) + C* (c^2*(m + 1) + d^2*(n + 1)))*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f, A, C, m}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && !LtQ[m, -2^(-1)] && (LtQ[n, -1] || EqQ[m + n + 2, 0])
Time = 0.27 (sec) , antiderivative size = 144, normalized size of antiderivative = 1.07
method | result | size |
default | \(\frac {\left (1+\sin \left (d x +c \right )\right ) \sqrt {-a \left (\sin \left (d x +c \right )-1\right )}\, \left (-21 \,\operatorname {arctanh}\left (\frac {\sqrt {-a \left (\sin \left (d x +c \right )-1\right )}}{\sqrt {a}}\right ) a^{3} \sin \left (d x +c \right )^{3}+27 \left (-a \left (\sin \left (d x +c \right )-1\right )\right )^{\frac {5}{2}} \sqrt {a}-56 \left (-a \left (\sin \left (d x +c \right )-1\right )\right )^{\frac {3}{2}} a^{\frac {3}{2}}+21 \sqrt {-a \left (\sin \left (d x +c \right )-1\right )}\, a^{\frac {5}{2}}\right )}{24 a^{\frac {7}{2}} \sin \left (d x +c \right )^{3} \cos \left (d x +c \right ) \sqrt {a +a \sin \left (d x +c \right )}\, d}\) | \(144\) |
Input:
int(cot(d*x+c)^4/(a+a*sin(d*x+c))^(1/2),x,method=_RETURNVERBOSE)
Output:
1/24*(1+sin(d*x+c))*(-a*(sin(d*x+c)-1))^(1/2)*(-21*arctanh((-a*(sin(d*x+c) -1))^(1/2)/a^(1/2))*a^3*sin(d*x+c)^3+27*(-a*(sin(d*x+c)-1))^(5/2)*a^(1/2)- 56*(-a*(sin(d*x+c)-1))^(3/2)*a^(3/2)+21*(-a*(sin(d*x+c)-1))^(1/2)*a^(5/2)) /a^(7/2)/sin(d*x+c)^3/cos(d*x+c)/(a+a*sin(d*x+c))^(1/2)/d
Leaf count of result is larger than twice the leaf count of optimal. 369 vs. \(2 (115) = 230\).
Time = 0.10 (sec) , antiderivative size = 369, normalized size of antiderivative = 2.73 \[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=\frac {21 \, {\left (\cos \left (d x + c\right )^{4} - 2 \, \cos \left (d x + c\right )^{2} - {\left (\cos \left (d x + c\right )^{3} + \cos \left (d x + c\right )^{2} - \cos \left (d x + c\right ) - 1\right )} \sin \left (d x + c\right ) + 1\right )} \sqrt {a} \log \left (\frac {a \cos \left (d x + c\right )^{3} - 7 \, a \cos \left (d x + c\right )^{2} - 4 \, {\left (\cos \left (d x + c\right )^{2} + {\left (\cos \left (d x + c\right ) + 3\right )} \sin \left (d x + c\right ) - 2 \, \cos \left (d x + c\right ) - 3\right )} \sqrt {a \sin \left (d x + c\right ) + a} \sqrt {a} - 9 \, a \cos \left (d x + c\right ) + {\left (a \cos \left (d x + c\right )^{2} + 8 \, a \cos \left (d x + c\right ) - a\right )} \sin \left (d x + c\right ) - a}{\cos \left (d x + c\right )^{3} + \cos \left (d x + c\right )^{2} + {\left (\cos \left (d x + c\right )^{2} - 1\right )} \sin \left (d x + c\right ) - \cos \left (d x + c\right ) - 1}\right ) - 4 \, {\left (27 \, \cos \left (d x + c\right )^{3} + 25 \, \cos \left (d x + c\right )^{2} - {\left (27 \, \cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) - 17\right )} \sin \left (d x + c\right ) - 19 \, \cos \left (d x + c\right ) - 17\right )} \sqrt {a \sin \left (d x + c\right ) + a}}{96 \, {\left (a d \cos \left (d x + c\right )^{4} - 2 \, a d \cos \left (d x + c\right )^{2} + a d - {\left (a d \cos \left (d x + c\right )^{3} + a d \cos \left (d x + c\right )^{2} - a d \cos \left (d x + c\right ) - a d\right )} \sin \left (d x + c\right )\right )}} \] Input:
integrate(cot(d*x+c)^4/(a+a*sin(d*x+c))^(1/2),x, algorithm="fricas")
Output:
1/96*(21*(cos(d*x + c)^4 - 2*cos(d*x + c)^2 - (cos(d*x + c)^3 + cos(d*x + c)^2 - cos(d*x + c) - 1)*sin(d*x + c) + 1)*sqrt(a)*log((a*cos(d*x + c)^3 - 7*a*cos(d*x + c)^2 - 4*(cos(d*x + c)^2 + (cos(d*x + c) + 3)*sin(d*x + c) - 2*cos(d*x + c) - 3)*sqrt(a*sin(d*x + c) + a)*sqrt(a) - 9*a*cos(d*x + c) + (a*cos(d*x + c)^2 + 8*a*cos(d*x + c) - a)*sin(d*x + c) - a)/(cos(d*x + c )^3 + cos(d*x + c)^2 + (cos(d*x + c)^2 - 1)*sin(d*x + c) - cos(d*x + c) - 1)) - 4*(27*cos(d*x + c)^3 + 25*cos(d*x + c)^2 - (27*cos(d*x + c)^2 + 2*co s(d*x + c) - 17)*sin(d*x + c) - 19*cos(d*x + c) - 17)*sqrt(a*sin(d*x + c) + a))/(a*d*cos(d*x + c)^4 - 2*a*d*cos(d*x + c)^2 + a*d - (a*d*cos(d*x + c) ^3 + a*d*cos(d*x + c)^2 - a*d*cos(d*x + c) - a*d)*sin(d*x + c))
\[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=\int \frac {\cot ^{4}{\left (c + d x \right )}}{\sqrt {a \left (\sin {\left (c + d x \right )} + 1\right )}}\, dx \] Input:
integrate(cot(d*x+c)**4/(a+a*sin(d*x+c))**(1/2),x)
Output:
Integral(cot(c + d*x)**4/sqrt(a*(sin(c + d*x) + 1)), x)
\[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=\int { \frac {\cot \left (d x + c\right )^{4}}{\sqrt {a \sin \left (d x + c\right ) + a}} \,d x } \] Input:
integrate(cot(d*x+c)^4/(a+a*sin(d*x+c))^(1/2),x, algorithm="maxima")
Output:
integrate(cot(d*x + c)^4/sqrt(a*sin(d*x + c) + a), x)
Time = 0.20 (sec) , antiderivative size = 185, normalized size of antiderivative = 1.37 \[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=\frac {\frac {21 \, \log \left ({\left | \frac {1}{2} \, \sqrt {2} + \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right )}{\sqrt {a} \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )} - \frac {21 \, \log \left ({\left | -\frac {1}{2} \, \sqrt {2} + \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right )}{\sqrt {a} \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )} + \frac {2 \, \sqrt {2} {\left (108 \, \sqrt {a} \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 112 \, \sqrt {a} \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 21 \, \sqrt {a} \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (2 \, \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )}^{3} a \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{48 \, d} \] Input:
integrate(cot(d*x+c)^4/(a+a*sin(d*x+c))^(1/2),x, algorithm="giac")
Output:
1/48*(21*log(abs(1/2*sqrt(2) + sin(-1/4*pi + 1/2*d*x + 1/2*c)))/(sqrt(a)*s gn(cos(-1/4*pi + 1/2*d*x + 1/2*c))) - 21*log(abs(-1/2*sqrt(2) + sin(-1/4*p i + 1/2*d*x + 1/2*c)))/(sqrt(a)*sgn(cos(-1/4*pi + 1/2*d*x + 1/2*c))) + 2*s qrt(2)*(108*sqrt(a)*sin(-1/4*pi + 1/2*d*x + 1/2*c)^5 - 112*sqrt(a)*sin(-1/ 4*pi + 1/2*d*x + 1/2*c)^3 + 21*sqrt(a)*sin(-1/4*pi + 1/2*d*x + 1/2*c))/((2 *sin(-1/4*pi + 1/2*d*x + 1/2*c)^2 - 1)^3*a*sgn(cos(-1/4*pi + 1/2*d*x + 1/2 *c))))/d
Timed out. \[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=\int \frac {{\mathrm {cot}\left (c+d\,x\right )}^4}{\sqrt {a+a\,\sin \left (c+d\,x\right )}} \,d x \] Input:
int(cot(c + d*x)^4/(a + a*sin(c + d*x))^(1/2),x)
Output:
int(cot(c + d*x)^4/(a + a*sin(c + d*x))^(1/2), x)
\[ \int \frac {\cot ^4(c+d x)}{\sqrt {a+a \sin (c+d x)}} \, dx=\frac {\sqrt {a}\, \left (\int \frac {\sqrt {\sin \left (d x +c \right )+1}\, \cot \left (d x +c \right )^{4}}{\sin \left (d x +c \right )+1}d x \right )}{a} \] Input:
int(cot(d*x+c)^4/(a+a*sin(d*x+c))^(1/2),x)
Output:
(sqrt(a)*int((sqrt(sin(c + d*x) + 1)*cot(c + d*x)**4)/(sin(c + d*x) + 1),x ))/a