3.118 \(\int \frac{1}{1+\cos (x)} \, dx\)

Optimal. Leaf size=9 \[ \frac{\sin (x)}{\cos (x)+1} \]

[Out]

Sin[x]/(1 + Cos[x])

_______________________________________________________________________________________

Rubi [A]  time = 0.0156868, antiderivative size = 9, normalized size of antiderivative = 1., number of steps used = 1, number of rules used = 1, integrand size = 6, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.167 \[ \frac{\sin (x)}{\cos (x)+1} \]

Antiderivative was successfully verified.

[In]  Int[(1 + Cos[x])^(-1),x]

[Out]

Sin[x]/(1 + Cos[x])

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 0.487695, size = 7, normalized size = 0.78 \[ \frac{\sin{\left (x \right )}}{\cos{\left (x \right )} + 1} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(1/(1+cos(x)),x)

[Out]

sin(x)/(cos(x) + 1)

_______________________________________________________________________________________

Mathematica [A]  time = 0.00577345, size = 6, normalized size = 0.67 \[ \tan \left (\frac{x}{2}\right ) \]

Antiderivative was successfully verified.

[In]  Integrate[(1 + Cos[x])^(-1),x]

[Out]

Tan[x/2]

_______________________________________________________________________________________

Maple [A]  time = 0.004, size = 5, normalized size = 0.6 \[ \tan \left ({\frac{x}{2}} \right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(1/(1+cos(x)),x)

[Out]

tan(1/2*x)

_______________________________________________________________________________________

Maxima [A]  time = 1.38645, size = 12, normalized size = 1.33 \[ \frac{\sin \left (x\right )}{\cos \left (x\right ) + 1} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(cos(x) + 1),x, algorithm="maxima")

[Out]

sin(x)/(cos(x) + 1)

_______________________________________________________________________________________

Fricas [A]  time = 0.219667, size = 12, normalized size = 1.33 \[ \frac{\sin \left (x\right )}{\cos \left (x\right ) + 1} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(cos(x) + 1),x, algorithm="fricas")

[Out]

sin(x)/(cos(x) + 1)

_______________________________________________________________________________________

Sympy [A]  time = 0.216179, size = 3, normalized size = 0.33 \[ \tan{\left (\frac{x}{2} \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(1+cos(x)),x)

[Out]

tan(x/2)

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.197388, size = 41, normalized size = 4.56 \[ -\frac{2 \, \tan \left (\frac{1}{2} \, x\right )}{{\left (x^{2} + 1\right )}{\left (\frac{x^{2} - 1}{x^{2} + 1} - 1\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(1/(cos(x) + 1),x, algorithm="giac")

[Out]

-2*tan(1/2*x)/((x^2 + 1)*((x^2 - 1)/(x^2 + 1) - 1))