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

Optimal. Leaf size=18 \[ -\frac{1}{5} \tanh ^{-1}\left (\frac{1}{5} (3 \cos (x)-4 \sin (x))\right ) \]

[Out]

-ArcTanh[(3*Cos[x] - 4*Sin[x])/5]/5

_______________________________________________________________________________________

Rubi [A]  time = 0.0207096, antiderivative size = 18, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 11, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.182 \[ -\frac{1}{5} \tanh ^{-1}\left (\frac{1}{5} (3 \cos (x)-4 \sin (x))\right ) \]

Antiderivative was successfully verified.

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

[Out]

-ArcTanh[(3*Cos[x] - 4*Sin[x])/5]/5

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 0.585207, size = 17, normalized size = 0.94 \[ - \frac{\operatorname{atanh}{\left (- \frac{4 \sin{\left (x \right )}}{5} + \frac{3 \cos{\left (x \right )}}{5} \right )}}{5} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(1/(4*cos(x)+3*sin(x)),x)

[Out]

-atanh(-4*sin(x)/5 + 3*cos(x)/5)/5

_______________________________________________________________________________________

Mathematica [B]  time = 0.0143775, size = 43, normalized size = 2.39 \[ \frac{1}{5} \log \left (2 \sin \left (\frac{x}{2}\right )+\cos \left (\frac{x}{2}\right )\right )-\frac{1}{5} \log \left (2 \cos \left (\frac{x}{2}\right )-\sin \left (\frac{x}{2}\right )\right ) \]

Antiderivative was successfully verified.

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

[Out]

-Log[2*Cos[x/2] - Sin[x/2]]/5 + Log[Cos[x/2] + 2*Sin[x/2]]/5

_______________________________________________________________________________________

Maple [A]  time = 0.046, size = 22, normalized size = 1.2 \[ -{\frac{1}{5}\ln \left ( \tan \left ({\frac{x}{2}} \right ) -2 \right ) }+{\frac{1}{5}\ln \left ( 2\,\tan \left ( x/2 \right ) +1 \right ) } \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

-1/5*ln(tan(1/2*x)-2)+1/5*ln(2*tan(1/2*x)+1)

_______________________________________________________________________________________

Maxima [A]  time = 1.36818, size = 41, normalized size = 2.28 \[ \frac{1}{5} \, \log \left (\frac{2 \, \sin \left (x\right )}{\cos \left (x\right ) + 1} + 1\right ) - \frac{1}{5} \, \log \left (\frac{\sin \left (x\right )}{\cos \left (x\right ) + 1} - 2\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

1/5*log(2*sin(x)/(cos(x) + 1) + 1) - 1/5*log(sin(x)/(cos(x) + 1) - 2)

_______________________________________________________________________________________

Fricas [A]  time = 0.221554, size = 36, normalized size = 2. \[ -\frac{1}{10} \, \log \left (\frac{3}{2} \, \cos \left (x\right ) - 2 \, \sin \left (x\right ) + \frac{5}{2}\right ) + \frac{1}{10} \, \log \left (-\frac{3}{2} \, \cos \left (x\right ) + 2 \, \sin \left (x\right ) + \frac{5}{2}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

-1/10*log(3/2*cos(x) - 2*sin(x) + 5/2) + 1/10*log(-3/2*cos(x) + 2*sin(x) + 5/2)

_______________________________________________________________________________________

Sympy [A]  time = 0.32849, size = 20, normalized size = 1.11 \[ - \frac{\log{\left (\tan{\left (\frac{x}{2} \right )} - 2 \right )}}{5} + \frac{\log{\left (\tan{\left (\frac{x}{2} \right )} + \frac{1}{2} \right )}}{5} \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

-log(tan(x/2) - 2)/5 + log(tan(x/2) + 1/2)/5

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.212357, size = 31, normalized size = 1.72 \[ \frac{1}{5} \,{\rm ln}\left ({\left | 2 \, \tan \left (\frac{1}{2} \, x\right ) + 1 \right |}\right ) - \frac{1}{5} \,{\rm ln}\left ({\left | \tan \left (\frac{1}{2} \, x\right ) - 2 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

1/5*ln(abs(2*tan(1/2*x) + 1)) - 1/5*ln(abs(tan(1/2*x) - 2))