Here, we show you a step-by-step solved example of integrals of rational functions of sine and cosine. This solution was automatically generated by our smart calculator:
We can solve the integral $\int\frac{1}{3-\cos\left(x\right)}dx$ by applying the method Weierstrass substitution (also known as tangent half-angle substitution) which converts an integral of trigonometric functions into a rational function of $t$ by setting the substitution
Hence
Substituting in the original integral we get
Multiplying fractions $\frac{1}{3-\frac{1-t^{2}}{1+t^{2}}} \times \frac{2}{1+t^{2}}$
Multiplying the fraction by $-1$
Combine $3+\frac{-1+t^{2}}{1+t^{2}}$ in a single fraction
Divide fractions $\frac{2}{\frac{-1+t^{2}+3\left(1+t^{2}\right)}{1+t^{2}}\left(1+t^{2}\right)}$ with Keep, Change, Flip: $a\div \frac{b}{c}=\frac{a}{1}\div\frac{b}{c}=\frac{a}{1}\times\frac{c}{b}=\frac{a\cdot c}{b}$
Simplify the fraction $\frac{2\left(1+t^{2}\right)}{\left(-1+t^{2}+3\left(1+t^{2}\right)\right)\left(1+t^{2}\right)}$ by $1+t^{2}$
Simplifying
The integral of a function times a constant ($2$) is equal to the constant times the integral of the function
Solve the product $3\left(1+t^{2}\right)$
Subtract the values $3$ and $-1$
Combining like terms $t^{2}$ and $3t^{2}$
Simplify the expression
The power of a product is equal to the product of it's factors raised to the same power
Solve the integral applying the substitution $u^2=2t^{2}$. Then, take the square root of both sides, simplifying we have
Differentiate both sides of the equation $u=\sqrt{2}t$
Find the derivative
The derivative of a function multiplied by a constant is equal to the constant times the derivative of the function
The derivative of the linear function is equal to $1$
Now, in order to rewrite $dt$ in terms of $du$, we need to find the derivative of $u$. We need to calculate $du$, we can do that by deriving the equation above
Isolate $dt$ in the previous equation
Any expression multiplied by $1$ is equal to itself
Simplify the fraction $2\cdot \left(\frac{\frac{1}{\sqrt{2}}}{2}\right)\int\frac{1}{u^2+1}du$
After replacing everything and simplifying, the integral results in
Solve the integral by applying the formula $\displaystyle\int\frac{x'}{x^2+a^2}dx=\frac{1}{a}\arctan\left(\frac{x}{a}\right)$
Replace $u$ with the value that we assigned to it in the beginning: $\sqrt{2}t$
Replace $u$ with the value that we assigned to it in the beginning: $\sqrt{2}t$
Replace $t$ with the value that we assigned to it in the beginning: $\tan\left(\frac{x}{2}\right)$
As the integral that we are solving is an indefinite integral, when we finish integrating we must add the constant of integration $C$
Access detailed step by step solutions to thousands of problems, growing every day!
Most popular problems solved with this calculator: