Integrand size = 10, antiderivative size = 28 \[ \int \sqrt {1+\csc ^2(x)} \, dx=-\text {arcsinh}\left (\frac {\cot (x)}{\sqrt {2}}\right )-\arctan \left (\frac {\cot (x)}{\sqrt {2+\cot ^2(x)}}\right ) \] Output:
-arcsinh(1/2*cot(x)*2^(1/2))-arctan(cot(x)/(2+cot(x)^2)^(1/2))
Leaf count is larger than twice the leaf count of optimal. \(68\) vs. \(2(28)=56\).
Time = 0.06 (sec) , antiderivative size = 68, normalized size of antiderivative = 2.43 \[ \int \sqrt {1+\csc ^2(x)} \, dx=\frac {\sqrt {2} \sqrt {1+\csc ^2(x)} \left (\arctan \left (\frac {\sqrt {2} \cos (x)}{\sqrt {-3+\cos (2 x)}}\right )+\log \left (\sqrt {2} \cos (x)+\sqrt {-3+\cos (2 x)}\right )\right ) \sin (x)}{\sqrt {-3+\cos (2 x)}} \] Input:
Integrate[Sqrt[1 + Csc[x]^2],x]
Output:
(Sqrt[2]*Sqrt[1 + Csc[x]^2]*(ArcTan[(Sqrt[2]*Cos[x])/Sqrt[-3 + Cos[2*x]]] + Log[Sqrt[2]*Cos[x] + Sqrt[-3 + Cos[2*x]]])*Sin[x])/Sqrt[-3 + Cos[2*x]]
Time = 0.20 (sec) , antiderivative size = 28, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.600, Rules used = {3042, 4616, 301, 222, 291, 216}
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 \sqrt {\csc ^2(x)+1} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \sqrt {\sec \left (x+\frac {\pi }{2}\right )^2+1}dx\) |
\(\Big \downarrow \) 4616 |
\(\displaystyle -\int \frac {\sqrt {\cot ^2(x)+2}}{\cot ^2(x)+1}d\cot (x)\) |
\(\Big \downarrow \) 301 |
\(\displaystyle -\int \frac {1}{\sqrt {\cot ^2(x)+2}}d\cot (x)-\int \frac {1}{\left (\cot ^2(x)+1\right ) \sqrt {\cot ^2(x)+2}}d\cot (x)\) |
\(\Big \downarrow \) 222 |
\(\displaystyle -\int \frac {1}{\left (\cot ^2(x)+1\right ) \sqrt {\cot ^2(x)+2}}d\cot (x)-\text {arcsinh}\left (\frac {\cot (x)}{\sqrt {2}}\right )\) |
\(\Big \downarrow \) 291 |
\(\displaystyle -\int \frac {1}{\frac {\cot ^2(x)}{\cot ^2(x)+2}+1}d\frac {\cot (x)}{\sqrt {\cot ^2(x)+2}}-\text {arcsinh}\left (\frac {\cot (x)}{\sqrt {2}}\right )\) |
\(\Big \downarrow \) 216 |
\(\displaystyle -\text {arcsinh}\left (\frac {\cot (x)}{\sqrt {2}}\right )-\arctan \left (\frac {\cot (x)}{\sqrt {\cot ^2(x)+2}}\right )\) |
Input:
Int[Sqrt[1 + Csc[x]^2],x]
Output:
-ArcSinh[Cot[x]/Sqrt[2]] - ArcTan[Cot[x]/Sqrt[2 + Cot[x]^2]]
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*A rcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a , 0] || GtQ[b, 0])
Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Simp[ArcSinh[Rt[b, 2]*(x/Sqrt [a])]/Rt[b, 2], x] /; FreeQ[{a, b}, x] && GtQ[a, 0] && PosQ[b]
Int[1/(Sqrt[(a_) + (b_.)*(x_)^2]*((c_) + (d_.)*(x_)^2)), x_Symbol] :> Subst [Int[1/(c - (b*c - a*d)*x^2), x], x, x/Sqrt[a + b*x^2]] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0]
Int[((a_) + (b_.)*(x_)^2)^(p_.)/((c_) + (d_.)*(x_)^2), x_Symbol] :> Simp[b/ d Int[(a + b*x^2)^(p - 1), x], x] - Simp[(b*c - a*d)/d Int[(a + b*x^2)^ (p - 1)/(c + d*x^2), x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && GtQ[p, 0] && (EqQ[p, 1/2] || EqQ[Denominator[p], 4] || (EqQ[p, 2/3] && E qQ[b*c + 3*a*d, 0]))
Int[((a_) + (b_.)*sec[(e_.) + (f_.)*(x_)]^2)^(p_), x_Symbol] :> With[{ff = FreeFactors[Tan[e + f*x], x]}, Simp[ff/f Subst[Int[(a + b + b*ff^2*x^2)^p /(1 + ff^2*x^2), x], x, Tan[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f, p}, x] && NeQ[a + b, 0] && NeQ[p, -1]
Leaf count of result is larger than twice the leaf count of optimal. \(148\) vs. \(2(25)=50\).
Time = 0.16 (sec) , antiderivative size = 149, normalized size of antiderivative = 5.32
method | result | size |
default | \(-\frac {\sqrt {4}\, \sqrt {-\cot \left (x \right )^{2}+2 \csc \left (x \right )^{2}}\, \left (\ln \left (\frac {2 \sqrt {-\frac {\cos \left (x \right )^{2}-2}{\left (\cos \left (x \right )+1\right )^{2}}}\, \cos \left (x \right )+2 \cos \left (x \right )+2 \sqrt {-\frac {\cos \left (x \right )^{2}-2}{\left (\cos \left (x \right )+1\right )^{2}}}+4}{\cos \left (x \right )+1}\right )+\operatorname {arctanh}\left (\frac {\cos \left (x \right )-2}{\left (\cos \left (x \right )+1\right ) \sqrt {-\frac {\cos \left (x \right )^{2}-2}{\left (\cos \left (x \right )+1\right )^{2}}}}\right )-2 \arctan \left (\frac {\cos \left (x \right )}{\left (\cos \left (x \right )+1\right ) \sqrt {-\frac {\cos \left (x \right )^{2}-2}{\left (\cos \left (x \right )+1\right )^{2}}}}\right )\right ) \left (\cot \left (x \right )-\csc \left (x \right )\right )}{4 \sqrt {-\frac {\cos \left (x \right )^{2}-2}{\left (\cos \left (x \right )+1\right )^{2}}}}\) | \(149\) |
Input:
int((1+csc(x)^2)^(1/2),x,method=_RETURNVERBOSE)
Output:
-1/4*4^(1/2)*(-cot(x)^2+2*csc(x)^2)^(1/2)*(ln(2*((-(cos(x)^2-2)/(cos(x)+1) ^2)^(1/2)*cos(x)+(-(cos(x)^2-2)/(cos(x)+1)^2)^(1/2)+cos(x)+2)/(cos(x)+1))+ arctanh((cos(x)-2)/(cos(x)+1)/(-(cos(x)^2-2)/(cos(x)+1)^2)^(1/2))-2*arctan (cos(x)/(cos(x)+1)/(-(cos(x)^2-2)/(cos(x)+1)^2)^(1/2)))/(-(cos(x)^2-2)/(co s(x)+1)^2)^(1/2)*(cot(x)-csc(x))
Leaf count of result is larger than twice the leaf count of optimal. 159 vs. \(2 (25) = 50\).
Time = 0.09 (sec) , antiderivative size = 159, normalized size of antiderivative = 5.68 \[ \int \sqrt {1+\csc ^2(x)} \, dx=\frac {1}{2} \, \arctan \left (\frac {{\left (\cos \left (x\right )^{3} - \cos \left (x\right )\right )} \sqrt {\frac {\cos \left (x\right )^{2} - 2}{\cos \left (x\right )^{2} - 1}} \sin \left (x\right ) - \cos \left (x\right ) \sin \left (x\right )}{\cos \left (x\right )^{4} - 3 \, \cos \left (x\right )^{2} + 1}\right ) - \frac {1}{2} \, \arctan \left (\frac {\sin \left (x\right )}{\cos \left (x\right )}\right ) - \frac {1}{2} \, \log \left (-\cos \left (x\right )^{2} + \cos \left (x\right ) \sin \left (x\right ) - {\left (\cos \left (x\right )^{2} - \cos \left (x\right ) \sin \left (x\right ) - 1\right )} \sqrt {\frac {\cos \left (x\right )^{2} - 2}{\cos \left (x\right )^{2} - 1}} + 2\right ) + \frac {1}{2} \, \log \left (-\cos \left (x\right )^{2} - \cos \left (x\right ) \sin \left (x\right ) - {\left (\cos \left (x\right )^{2} + \cos \left (x\right ) \sin \left (x\right ) - 1\right )} \sqrt {\frac {\cos \left (x\right )^{2} - 2}{\cos \left (x\right )^{2} - 1}} + 2\right ) \] Input:
integrate((1+csc(x)^2)^(1/2),x, algorithm="fricas")
Output:
1/2*arctan(((cos(x)^3 - cos(x))*sqrt((cos(x)^2 - 2)/(cos(x)^2 - 1))*sin(x) - cos(x)*sin(x))/(cos(x)^4 - 3*cos(x)^2 + 1)) - 1/2*arctan(sin(x)/cos(x)) - 1/2*log(-cos(x)^2 + cos(x)*sin(x) - (cos(x)^2 - cos(x)*sin(x) - 1)*sqrt ((cos(x)^2 - 2)/(cos(x)^2 - 1)) + 2) + 1/2*log(-cos(x)^2 - cos(x)*sin(x) - (cos(x)^2 + cos(x)*sin(x) - 1)*sqrt((cos(x)^2 - 2)/(cos(x)^2 - 1)) + 2)
\[ \int \sqrt {1+\csc ^2(x)} \, dx=\int \sqrt {\csc ^{2}{\left (x \right )} + 1}\, dx \] Input:
integrate((1+csc(x)**2)**(1/2),x)
Output:
Integral(sqrt(csc(x)**2 + 1), x)
\[ \int \sqrt {1+\csc ^2(x)} \, dx=\int { \sqrt {\csc \left (x\right )^{2} + 1} \,d x } \] Input:
integrate((1+csc(x)^2)^(1/2),x, algorithm="maxima")
Output:
integrate(sqrt(csc(x)^2 + 1), x)
Leaf count of result is larger than twice the leaf count of optimal. 130 vs. \(2 (25) = 50\).
Time = 0.17 (sec) , antiderivative size = 130, normalized size of antiderivative = 4.64 \[ \int \sqrt {1+\csc ^2(x)} \, dx=\frac {1}{2} \, {\left (4 \, \arctan \left (-\frac {1}{2} \, \tan \left (\frac {1}{2} \, x\right )^{2} + \frac {1}{2} \, \sqrt {\tan \left (\frac {1}{2} \, x\right )^{4} + 6 \, \tan \left (\frac {1}{2} \, x\right )^{2} + 1} - \frac {1}{2}\right ) - \log \left (\tan \left (\frac {1}{2} \, x\right )^{2} - \sqrt {\tan \left (\frac {1}{2} \, x\right )^{4} + 6 \, \tan \left (\frac {1}{2} \, x\right )^{2} + 1} + 3\right ) - \log \left (-\tan \left (\frac {1}{2} \, x\right )^{2} + \sqrt {\tan \left (\frac {1}{2} \, x\right )^{4} + 6 \, \tan \left (\frac {1}{2} \, x\right )^{2} + 1} + 1\right ) + \log \left (-\tan \left (\frac {1}{2} \, x\right )^{2} + \sqrt {\tan \left (\frac {1}{2} \, x\right )^{4} + 6 \, \tan \left (\frac {1}{2} \, x\right )^{2} + 1} - 1\right )\right )} \mathrm {sgn}\left (\sin \left (x\right )\right ) \] Input:
integrate((1+csc(x)^2)^(1/2),x, algorithm="giac")
Output:
1/2*(4*arctan(-1/2*tan(1/2*x)^2 + 1/2*sqrt(tan(1/2*x)^4 + 6*tan(1/2*x)^2 + 1) - 1/2) - log(tan(1/2*x)^2 - sqrt(tan(1/2*x)^4 + 6*tan(1/2*x)^2 + 1) + 3) - log(-tan(1/2*x)^2 + sqrt(tan(1/2*x)^4 + 6*tan(1/2*x)^2 + 1) + 1) + lo g(-tan(1/2*x)^2 + sqrt(tan(1/2*x)^4 + 6*tan(1/2*x)^2 + 1) - 1))*sgn(sin(x) )
Timed out. \[ \int \sqrt {1+\csc ^2(x)} \, dx=\int \sqrt {\frac {1}{{\sin \left (x\right )}^2}+1} \,d x \] Input:
int((1/sin(x)^2 + 1)^(1/2),x)
Output:
int((1/sin(x)^2 + 1)^(1/2), x)
\[ \int \sqrt {1+\csc ^2(x)} \, dx=\int \sqrt {\csc \left (x \right )^{2}+1}d x \] Input:
int((1+csc(x)^2)^(1/2),x)
Output:
int(sqrt(csc(x)**2 + 1),x)