3.4 \(\int \frac {1}{3+3 \cos (x)+4 \sin (x)} \, dx\)

Optimal. Leaf size=15 \[ \frac {1}{4} \log \left (4 \tan \left (\frac {x}{2}\right )+3\right ) \]

[Out]

1/4*ln(3+4*tan(1/2*x))

________________________________________________________________________________________

Rubi [A]  time = 0.01, antiderivative size = 15, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {3124, 31} \[ \frac {1}{4} \log \left (4 \tan \left (\frac {x}{2}\right )+3\right ) \]

Antiderivative was successfully verified.

[In]

Int[(3 + 3*Cos[x] + 4*Sin[x])^(-1),x]

[Out]

Log[3 + 4*Tan[x/2]]/4

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 3124

Int[(cos[(d_.) + (e_.)*(x_)]*(b_.) + (a_) + (c_.)*sin[(d_.) + (e_.)*(x_)])^(-1), x_Symbol] :> Module[{f = Free
Factors[Tan[(d + e*x)/2], x]}, Dist[(2*f)/e, Subst[Int[1/(a + b + 2*c*f*x + (a - b)*f^2*x^2), x], x, Tan[(d +
e*x)/2]/f], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[a^2 - b^2 - c^2, 0]

Rubi steps

\begin {align*} \int \frac {1}{3+3 \cos (x)+4 \sin (x)} \, dx &=2 \operatorname {Subst}\left (\int \frac {1}{6+8 x} \, dx,x,\tan \left (\frac {x}{2}\right )\right )\\ &=\frac {1}{4} \log \left (3+4 \tan \left (\frac {x}{2}\right )\right )\\ \end {align*}

________________________________________________________________________________________

Mathematica [B]  time = 0.02, size = 34, normalized size = 2.27 \[ \frac {1}{4} \log \left (4 \sin \left (\frac {x}{2}\right )+3 \cos \left (\frac {x}{2}\right )\right )-\frac {1}{4} \log \left (\cos \left (\frac {x}{2}\right )\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[(3 + 3*Cos[x] + 4*Sin[x])^(-1),x]

[Out]

-1/4*Log[Cos[x/2]] + Log[3*Cos[x/2] + 4*Sin[x/2]]/4

________________________________________________________________________________________

fricas [B]  time = 0.76, size = 23, normalized size = 1.53 \[ -\frac {1}{8} \, \log \left (\frac {1}{2} \, \cos \relax (x) + \frac {1}{2}\right ) + \frac {1}{8} \, \log \left (-\frac {7}{2} \, \cos \relax (x) + 12 \, \sin \relax (x) + \frac {25}{2}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(3+3*cos(x)+4*sin(x)),x, algorithm="fricas")

[Out]

-1/8*log(1/2*cos(x) + 1/2) + 1/8*log(-7/2*cos(x) + 12*sin(x) + 25/2)

________________________________________________________________________________________

giac [A]  time = 1.13, size = 12, normalized size = 0.80 \[ \frac {1}{4} \, \log \left ({\left | 4 \, \tan \left (\frac {1}{2} \, x\right ) + 3 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(3+3*cos(x)+4*sin(x)),x, algorithm="giac")

[Out]

1/4*log(abs(4*tan(1/2*x) + 3))

________________________________________________________________________________________

maple [A]  time = 0.05, size = 12, normalized size = 0.80 \[ \frac {\ln \left (4 \tan \left (\frac {x}{2}\right )+3\right )}{4} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(3+3*cos(x)+4*sin(x)),x)

[Out]

1/4*ln(3+4*tan(1/2*x))

________________________________________________________________________________________

maxima [A]  time = 0.57, size = 15, normalized size = 1.00 \[ \frac {1}{4} \, \log \left (\frac {4 \, \sin \relax (x)}{\cos \relax (x) + 1} + 3\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(3+3*cos(x)+4*sin(x)),x, algorithm="maxima")

[Out]

1/4*log(4*sin(x)/(cos(x) + 1) + 3)

________________________________________________________________________________________

mupad [B]  time = 0.08, size = 11, normalized size = 0.73 \[ \frac {\ln \left (4\,\mathrm {tan}\left (\frac {x}{2}\right )+3\right )}{4} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(3*cos(x) + 4*sin(x) + 3),x)

[Out]

log(4*tan(x/2) + 3)/4

________________________________________________________________________________________

sympy [A]  time = 0.26, size = 10, normalized size = 0.67 \[ \frac {\log {\left (\tan {\left (\frac {x}{2} \right )} + \frac {3}{4} \right )}}{4} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(3+3*cos(x)+4*sin(x)),x)

[Out]

log(tan(x/2) + 3/4)/4

________________________________________________________________________________________