Integrand size = 25, antiderivative size = 199 \[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\frac {16 \cot (c+d x)}{5 a^2 d \sqrt {e \csc (c+d x)}}-\frac {2 \cot ^3(c+d x)}{5 a^2 d \sqrt {e \csc (c+d x)}}-\frac {4 \csc (c+d x)}{a^2 d \sqrt {e \csc (c+d x)}}-\frac {2 \cot (c+d x) \csc ^2(c+d x)}{5 a^2 d \sqrt {e \csc (c+d x)}}+\frac {4 \csc ^3(c+d x)}{5 a^2 d \sqrt {e \csc (c+d x)}}+\frac {28 E\left (\left .\frac {1}{2} \left (c-\frac {\pi }{2}+d x\right )\right |2\right )}{5 a^2 d \sqrt {e \csc (c+d x)} \sqrt {\sin (c+d x)}} \] Output:
16/5*cot(d*x+c)/a^2/d/(e*csc(d*x+c))^(1/2)-2/5*cot(d*x+c)^3/a^2/d/(e*csc(d *x+c))^(1/2)-4*csc(d*x+c)/a^2/d/(e*csc(d*x+c))^(1/2)-2/5*cot(d*x+c)*csc(d* x+c)^2/a^2/d/(e*csc(d*x+c))^(1/2)+4/5*csc(d*x+c)^3/a^2/d/(e*csc(d*x+c))^(1 /2)-28/5*EllipticE(cos(1/2*c+1/4*Pi+1/2*d*x),2^(1/2))/a^2/d/(e*csc(d*x+c)) ^(1/2)/sin(d*x+c)^(1/2)
Result contains higher order function than in optimal. Order 5 vs. order 4 in optimal.
Time = 1.87 (sec) , antiderivative size = 252, normalized size of antiderivative = 1.27 \[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\frac {4 \cos ^4\left (\frac {1}{2} (c+d x)\right ) \sqrt {\csc (c+d x)} \sec ^2(c+d x) \left (-\frac {28 \sqrt {2} e^{i (c-d x)} \sqrt {\frac {i e^{i (c+d x)}}{-1+e^{2 i (c+d x)}}} \left (3-3 e^{2 i (c+d x)}+e^{2 i d x} \left (1+e^{2 i c}\right ) \sqrt {1-e^{2 i (c+d x)}} \operatorname {Hypergeometric2F1}\left (\frac {1}{2},\frac {3}{4},\frac {7}{4},e^{2 i (c+d x)}\right )\right )}{1+e^{2 i c}}-3 \sqrt {\csc (c+d x)} \left ((-23+5 \cos (2 c)) \cos (d x) \sec (c)-2 \left (-10+\sec ^2\left (\frac {1}{2} (c+d x)\right )+5 \sin (c) \sin (d x)\right )\right )\right )}{15 a^2 d \sqrt {e \csc (c+d x)} (1+\sec (c+d x))^2} \] Input:
Integrate[1/(Sqrt[e*Csc[c + d*x]]*(a + a*Sec[c + d*x])^2),x]
Output:
(4*Cos[(c + d*x)/2]^4*Sqrt[Csc[c + d*x]]*Sec[c + d*x]^2*((-28*Sqrt[2]*E^(I *(c - d*x))*Sqrt[(I*E^(I*(c + d*x)))/(-1 + E^((2*I)*(c + d*x)))]*(3 - 3*E^ ((2*I)*(c + d*x)) + E^((2*I)*d*x)*(1 + E^((2*I)*c))*Sqrt[1 - E^((2*I)*(c + d*x))]*Hypergeometric2F1[1/2, 3/4, 7/4, E^((2*I)*(c + d*x))]))/(1 + E^((2 *I)*c)) - 3*Sqrt[Csc[c + d*x]]*((-23 + 5*Cos[2*c])*Cos[d*x]*Sec[c] - 2*(-1 0 + Sec[(c + d*x)/2]^2 + 5*Sin[c]*Sin[d*x]))))/(15*a^2*d*Sqrt[e*Csc[c + d* x]]*(1 + Sec[c + d*x])^2)
Time = 0.83 (sec) , antiderivative size = 171, normalized size of antiderivative = 0.86, number of steps used = 9, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.360, Rules used = {3042, 4366, 3042, 4360, 3042, 3354, 3042, 3352, 2009}
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 {1}{(a \sec (c+d x)+a)^2 \sqrt {e \csc (c+d x)}} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {1}{\left (a-a \csc \left (c+d x-\frac {\pi }{2}\right )\right )^2 \sqrt {e \sec \left (c+d x-\frac {\pi }{2}\right )}}dx\) |
\(\Big \downarrow \) 4366 |
\(\displaystyle \frac {\int \frac {\sqrt {\sin (c+d x)}}{(\sec (c+d x) a+a)^2}dx}{\sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \frac {\sqrt {\cos \left (c+d x-\frac {\pi }{2}\right )}}{\left (a-a \csc \left (c+d x-\frac {\pi }{2}\right )\right )^2}dx}{\sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
\(\Big \downarrow \) 4360 |
\(\displaystyle \frac {\int \frac {\cos ^2(c+d x) \sqrt {\sin (c+d x)}}{(-\cos (c+d x) a-a)^2}dx}{\sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \frac {\sqrt {-\cos \left (c+d x+\frac {\pi }{2}\right )} \sin \left (c+d x+\frac {\pi }{2}\right )^2}{\left (-\sin \left (c+d x+\frac {\pi }{2}\right ) a-a\right )^2}dx}{\sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
\(\Big \downarrow \) 3354 |
\(\displaystyle \frac {\int \frac {\cos ^2(c+d x) (a-a \cos (c+d x))^2}{\sin ^{\frac {7}{2}}(c+d x)}dx}{a^4 \sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \frac {\sin \left (c+d x-\frac {\pi }{2}\right )^2 \left (\sin \left (c+d x-\frac {\pi }{2}\right ) a+a\right )^2}{\cos \left (c+d x-\frac {\pi }{2}\right )^{7/2}}dx}{a^4 \sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
\(\Big \downarrow \) 3352 |
\(\displaystyle \frac {\int \left (\frac {a^2 \cos ^4(c+d x)}{\sin ^{\frac {7}{2}}(c+d x)}-\frac {2 a^2 \cos ^3(c+d x)}{\sin ^{\frac {7}{2}}(c+d x)}+\frac {a^2 \cos ^2(c+d x)}{\sin ^{\frac {7}{2}}(c+d x)}\right )dx}{a^4 \sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {\frac {4 a^2}{5 d \sin ^{\frac {5}{2}}(c+d x)}-\frac {4 a^2}{d \sqrt {\sin (c+d x)}}+\frac {28 a^2 E\left (\left .\frac {1}{2} \left (c+d x-\frac {\pi }{2}\right )\right |2\right )}{5 d}-\frac {2 a^2 \cos ^3(c+d x)}{5 d \sin ^{\frac {5}{2}}(c+d x)}-\frac {2 a^2 \cos (c+d x)}{5 d \sin ^{\frac {5}{2}}(c+d x)}+\frac {16 a^2 \cos (c+d x)}{5 d \sqrt {\sin (c+d x)}}}{a^4 \sqrt {\sin (c+d x)} \sqrt {e \csc (c+d x)}}\) |
Input:
Int[1/(Sqrt[e*Csc[c + d*x]]*(a + a*Sec[c + d*x])^2),x]
Output:
((28*a^2*EllipticE[(c - Pi/2 + d*x)/2, 2])/(5*d) + (4*a^2)/(5*d*Sin[c + d* x]^(5/2)) - (2*a^2*Cos[c + d*x])/(5*d*Sin[c + d*x]^(5/2)) - (2*a^2*Cos[c + d*x]^3)/(5*d*Sin[c + d*x]^(5/2)) - (4*a^2)/(d*Sqrt[Sin[c + d*x]]) + (16*a ^2*Cos[c + d*x])/(5*d*Sqrt[Sin[c + d*x]]))/(a^4*Sqrt[e*Csc[c + d*x]]*Sqrt[ Sin[c + d*x]])
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n _)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> Int[ExpandTrig [(g*cos[e + f*x])^p, (d*sin[e + f*x])^n*(a + b*sin[e + f*x])^m, x], x] /; F reeQ[{a, b, d, e, f, g, n, p}, x] && EqQ[a^2 - b^2, 0] && IGtQ[m, 0]
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n _)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_), x_Symbol] :> Simp[(a/g)^(2* m) Int[(g*Cos[e + f*x])^(2*m + p)*((d*Sin[e + f*x])^n/(a - b*Sin[e + f*x] )^m), x], x] /; FreeQ[{a, b, d, e, f, g, n, p}, x] && EqQ[a^2 - b^2, 0] && ILtQ[m, 0]
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.), x_Symbol] :> Int[(g*Cos[e + f*x])^p*((b + a*Sin[e + f*x])^m/Si n[e + f*x]^m), x] /; FreeQ[{a, b, e, f, g, p}, x] && IntegerQ[m]
Int[(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.)*((g_.)*sec[(e_.) + (f_.)*( x_)])^(p_), x_Symbol] :> Simp[g^IntPart[p]*(g*Sec[e + f*x])^FracPart[p]*Cos [e + f*x]^FracPart[p] Int[(a + b*Csc[e + f*x])^m/Cos[e + f*x]^p, x], x] / ; FreeQ[{a, b, e, f, g, m, p}, x] && !IntegerQ[p]
Result contains complex when optimal does not.
Time = 1.06 (sec) , antiderivative size = 287, normalized size of antiderivative = 1.44
method | result | size |
default | \(-\frac {\sqrt {2}\, \left (\left (28 \cos \left (d x +c \right )^{2}+56 \cos \left (d x +c \right )+28\right ) \sqrt {1+i \cot \left (d x +c \right )-i \csc \left (d x +c \right )}\, \sqrt {1-i \cot \left (d x +c \right )+i \csc \left (d x +c \right )}\, \sqrt {i \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}\, \operatorname {EllipticE}\left (\sqrt {1+i \cot \left (d x +c \right )-i \csc \left (d x +c \right )}, \frac {\sqrt {2}}{2}\right )+\left (-14 \cos \left (d x +c \right )^{2}-28 \cos \left (d x +c \right )-14\right ) \sqrt {1+i \cot \left (d x +c \right )-i \csc \left (d x +c \right )}\, \sqrt {1-i \cot \left (d x +c \right )+i \csc \left (d x +c \right )}\, \sqrt {i \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}\, \operatorname {EllipticF}\left (\sqrt {1+i \cot \left (d x +c \right )-i \csc \left (d x +c \right )}, \frac {\sqrt {2}}{2}\right )+\left (5 \cos \left (d x +c \right )^{2}+\cos \left (d x +c \right )-6\right ) \sqrt {2}\right ) \csc \left (d x +c \right )}{5 a^{2} d \left (1+\cos \left (d x +c \right )\right ) \sqrt {e \csc \left (d x +c \right )}}\) | \(287\) |
Input:
int(1/(e*csc(d*x+c))^(1/2)/(a+a*sec(d*x+c))^2,x,method=_RETURNVERBOSE)
Output:
-1/5/a^2/d*2^(1/2)*((28*cos(d*x+c)^2+56*cos(d*x+c)+28)*(1+I*cot(d*x+c)-I*c sc(d*x+c))^(1/2)*(1-I*cot(d*x+c)+I*csc(d*x+c))^(1/2)*(I*(csc(d*x+c)-cot(d* x+c)))^(1/2)*EllipticE((1+I*cot(d*x+c)-I*csc(d*x+c))^(1/2),1/2*2^(1/2))+(- 14*cos(d*x+c)^2-28*cos(d*x+c)-14)*(1+I*cot(d*x+c)-I*csc(d*x+c))^(1/2)*(1-I *cot(d*x+c)+I*csc(d*x+c))^(1/2)*(I*(csc(d*x+c)-cot(d*x+c)))^(1/2)*Elliptic F((1+I*cot(d*x+c)-I*csc(d*x+c))^(1/2),1/2*2^(1/2))+(5*cos(d*x+c)^2+cos(d*x +c)-6)*2^(1/2))/(1+cos(d*x+c))/(e*csc(d*x+c))^(1/2)*csc(d*x+c)
Result contains complex when optimal does not.
Time = 0.09 (sec) , antiderivative size = 129, normalized size of antiderivative = 0.65 \[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\frac {2 \, {\left (7 \, \sqrt {2 i \, e} {\left (\cos \left (d x + c\right ) + 1\right )} {\rm weierstrassZeta}\left (4, 0, {\rm weierstrassPInverse}\left (4, 0, \cos \left (d x + c\right ) + i \, \sin \left (d x + c\right )\right )\right ) + 7 \, \sqrt {-2 i \, e} {\left (\cos \left (d x + c\right ) + 1\right )} {\rm weierstrassZeta}\left (4, 0, {\rm weierstrassPInverse}\left (4, 0, \cos \left (d x + c\right ) - i \, \sin \left (d x + c\right )\right )\right ) + {\left (9 \, \cos \left (d x + c\right )^{2} - \cos \left (d x + c\right ) - 8\right )} \sqrt {\frac {e}{\sin \left (d x + c\right )}}\right )}}{5 \, {\left (a^{2} d e \cos \left (d x + c\right ) + a^{2} d e\right )}} \] Input:
integrate(1/(e*csc(d*x+c))^(1/2)/(a+a*sec(d*x+c))^2,x, algorithm="fricas")
Output:
2/5*(7*sqrt(2*I*e)*(cos(d*x + c) + 1)*weierstrassZeta(4, 0, weierstrassPIn verse(4, 0, cos(d*x + c) + I*sin(d*x + c))) + 7*sqrt(-2*I*e)*(cos(d*x + c) + 1)*weierstrassZeta(4, 0, weierstrassPInverse(4, 0, cos(d*x + c) - I*sin (d*x + c))) + (9*cos(d*x + c)^2 - cos(d*x + c) - 8)*sqrt(e/sin(d*x + c)))/ (a^2*d*e*cos(d*x + c) + a^2*d*e)
\[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\frac {\int \frac {1}{\sqrt {e \csc {\left (c + d x \right )}} \sec ^{2}{\left (c + d x \right )} + 2 \sqrt {e \csc {\left (c + d x \right )}} \sec {\left (c + d x \right )} + \sqrt {e \csc {\left (c + d x \right )}}}\, dx}{a^{2}} \] Input:
integrate(1/(e*csc(d*x+c))**(1/2)/(a+a*sec(d*x+c))**2,x)
Output:
Integral(1/(sqrt(e*csc(c + d*x))*sec(c + d*x)**2 + 2*sqrt(e*csc(c + d*x))* sec(c + d*x) + sqrt(e*csc(c + d*x))), x)/a**2
\[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\int { \frac {1}{\sqrt {e \csc \left (d x + c\right )} {\left (a \sec \left (d x + c\right ) + a\right )}^{2}} \,d x } \] Input:
integrate(1/(e*csc(d*x+c))^(1/2)/(a+a*sec(d*x+c))^2,x, algorithm="maxima")
Output:
integrate(1/(sqrt(e*csc(d*x + c))*(a*sec(d*x + c) + a)^2), x)
\[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\int { \frac {1}{\sqrt {e \csc \left (d x + c\right )} {\left (a \sec \left (d x + c\right ) + a\right )}^{2}} \,d x } \] Input:
integrate(1/(e*csc(d*x+c))^(1/2)/(a+a*sec(d*x+c))^2,x, algorithm="giac")
Output:
integrate(1/(sqrt(e*csc(d*x + c))*(a*sec(d*x + c) + a)^2), x)
Timed out. \[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\int \frac {{\cos \left (c+d\,x\right )}^2}{a^2\,\sqrt {\frac {e}{\sin \left (c+d\,x\right )}}\,{\left (\cos \left (c+d\,x\right )+1\right )}^2} \,d x \] Input:
int(1/((a + a/cos(c + d*x))^2*(e/sin(c + d*x))^(1/2)),x)
Output:
int(cos(c + d*x)^2/(a^2*(e/sin(c + d*x))^(1/2)*(cos(c + d*x) + 1)^2), x)
\[ \int \frac {1}{\sqrt {e \csc (c+d x)} (a+a \sec (c+d x))^2} \, dx=\frac {\sqrt {e}\, \left (\int \frac {\sqrt {\csc \left (d x +c \right )}}{\csc \left (d x +c \right ) \sec \left (d x +c \right )^{2}+2 \csc \left (d x +c \right ) \sec \left (d x +c \right )+\csc \left (d x +c \right )}d x \right )}{a^{2} e} \] Input:
int(1/(e*csc(d*x+c))^(1/2)/(a+a*sec(d*x+c))^2,x)
Output:
(sqrt(e)*int(sqrt(csc(c + d*x))/(csc(c + d*x)*sec(c + d*x)**2 + 2*csc(c + d*x)*sec(c + d*x) + csc(c + d*x)),x))/(a**2*e)