\(\int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx\) [2]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [F]
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 27, antiderivative size = 44 \[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=\frac {x}{\sqrt {2}}+\frac {\arctan \left (\frac {\sin (4+6 x)}{3+2 \sqrt {2}-\cos (4+6 x)}\right )}{3 \sqrt {2}} \]

[Out]

1/2*x*2^(1/2)+1/6*arctan(sin(4+6*x)/(3-cos(4+6*x)+2*2^(1/2)))*2^(1/2)

Rubi [A] (verified)

Time = 0.05 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.111, Rules used = {12, 3245, 2736} \[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=\frac {\arctan \left (\frac {\sin (6 x+4)}{-\cos (6 x+4)+2 \sqrt {2}+3}\right )}{3 \sqrt {2}}+\frac {x}{\sqrt {2}} \]

[In]

Int[(2*Csc[4 + 6*x])/(-Cot[4 + 6*x] + 3*Csc[4 + 6*x]),x]

[Out]

x/Sqrt[2] + ArcTan[Sin[4 + 6*x]/(3 + 2*Sqrt[2] - Cos[4 + 6*x])]/(3*Sqrt[2])

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2736

Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> With[{q = Rt[a^2 - b^2, 2]}, Simp[x/q, x] + Simp
[(2/(d*q))*ArcTan[b*(Cos[c + d*x]/(a + q + b*Sin[c + d*x]))], x]] /; FreeQ[{a, b, c, d}, x] && GtQ[a^2 - b^2,
0] && PosQ[a]

Rule 3245

Int[csc[(d_.) + (e_.)*(x_)]^(n_.)*((a_.) + csc[(d_.) + (e_.)*(x_)]*(b_.) + cot[(d_.) + (e_.)*(x_)]*(c_.))^(m_)
, x_Symbol] :> Int[1/(b + a*Sin[d + e*x] + c*Cos[d + e*x])^n, x] /; FreeQ[{a, b, c, d, e}, x] && EqQ[m + n, 0]
 && IntegerQ[n]

Rubi steps \begin{align*} \text {integral}& = 2 \int \frac {\csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx \\ & = 2 \int \frac {1}{3-\cos (4+6 x)} \, dx \\ & = \frac {x}{\sqrt {2}}+\frac {\arctan \left (\frac {\sin (4+6 x)}{3+2 \sqrt {2}-\cos (4+6 x)}\right )}{3 \sqrt {2}} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.02 (sec) , antiderivative size = 22, normalized size of antiderivative = 0.50 \[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=\frac {\arctan \left (\sqrt {2} \tan (2+3 x)\right )}{3 \sqrt {2}} \]

[In]

Integrate[(2*Csc[4 + 6*x])/(-Cot[4 + 6*x] + 3*Csc[4 + 6*x]),x]

[Out]

ArcTan[Sqrt[2]*Tan[2 + 3*x]]/(3*Sqrt[2])

Maple [A] (verified)

Time = 0.61 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.39

method result size
derivativedivides \(\frac {\sqrt {2}\, \arctan \left (\tan \left (2+3 x \right ) \sqrt {2}\right )}{6}\) \(17\)
default \(\frac {\sqrt {2}\, \arctan \left (\tan \left (2+3 x \right ) \sqrt {2}\right )}{6}\) \(17\)
risch \(\frac {i \sqrt {2}\, \ln \left ({\mathrm e}^{2 i \left (2+3 x \right )}-3-2 \sqrt {2}\right )}{12}-\frac {i \sqrt {2}\, \ln \left ({\mathrm e}^{2 i \left (2+3 x \right )}-3+2 \sqrt {2}\right )}{12}\) \(48\)

[In]

int(2*csc(4+6*x)/(-cot(4+6*x)+3*csc(4+6*x)),x,method=_RETURNVERBOSE)

[Out]

1/6*2^(1/2)*arctan(tan(2+3*x)*2^(1/2))

Fricas [A] (verification not implemented)

none

Time = 0.24 (sec) , antiderivative size = 33, normalized size of antiderivative = 0.75 \[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=-\frac {1}{12} \, \sqrt {2} \arctan \left (\frac {3 \, \sqrt {2} \cos \left (6 \, x + 4\right ) - \sqrt {2}}{4 \, \sin \left (6 \, x + 4\right )}\right ) \]

[In]

integrate(2*csc(4+6*x)/(-cot(4+6*x)+3*csc(4+6*x)),x, algorithm="fricas")

[Out]

-1/12*sqrt(2)*arctan(1/4*(3*sqrt(2)*cos(6*x + 4) - sqrt(2))/sin(6*x + 4))

Sympy [F]

\[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=- 2 \int \frac {\csc {\left (6 x + 4 \right )}}{\cot {\left (6 x + 4 \right )} - 3 \csc {\left (6 x + 4 \right )}}\, dx \]

[In]

integrate(2*csc(4+6*x)/(-cot(4+6*x)+3*csc(4+6*x)),x)

[Out]

-2*Integral(csc(6*x + 4)/(cot(6*x + 4) - 3*csc(6*x + 4)), x)

Maxima [A] (verification not implemented)

none

Time = 0.29 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.59 \[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=\frac {1}{6} \, \sqrt {2} \arctan \left (\frac {\sqrt {2} \sin \left (6 \, x + 4\right )}{\cos \left (6 \, x + 4\right ) + 1}\right ) \]

[In]

integrate(2*csc(4+6*x)/(-cot(4+6*x)+3*csc(4+6*x)),x, algorithm="maxima")

[Out]

1/6*sqrt(2)*arctan(sqrt(2)*sin(6*x + 4)/(cos(6*x + 4) + 1))

Giac [A] (verification not implemented)

none

Time = 0.30 (sec) , antiderivative size = 57, normalized size of antiderivative = 1.30 \[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=\frac {1}{6} \, \sqrt {2} {\left (3 \, x + \arctan \left (-\frac {\sqrt {2} \sin \left (6 \, x + 4\right ) - 2 \, \sin \left (6 \, x + 4\right )}{\sqrt {2} \cos \left (6 \, x + 4\right ) + \sqrt {2} - 2 \, \cos \left (6 \, x + 4\right ) + 2}\right ) + 2\right )} \]

[In]

integrate(2*csc(4+6*x)/(-cot(4+6*x)+3*csc(4+6*x)),x, algorithm="giac")

[Out]

1/6*sqrt(2)*(3*x + arctan(-(sqrt(2)*sin(6*x + 4) - 2*sin(6*x + 4))/(sqrt(2)*cos(6*x + 4) + sqrt(2) - 2*cos(6*x
 + 4) + 2)) + 2)

Mupad [B] (verification not implemented)

Time = 27.13 (sec) , antiderivative size = 16, normalized size of antiderivative = 0.36 \[ \int \frac {2 \csc (4+6 x)}{-\cot (4+6 x)+3 \csc (4+6 x)} \, dx=\frac {\sqrt {2}\,\mathrm {atan}\left (\sqrt {2}\,\mathrm {tan}\left (3\,x+2\right )\right )}{6} \]

[In]

int(-2/(sin(6*x + 4)*(cot(6*x + 4) - 3/sin(6*x + 4))),x)

[Out]

(2^(1/2)*atan(2^(1/2)*tan(3*x + 2)))/6