1

I have calculated the indefinite integral $\int \frac{-\sin x}{\cos^3x}dx$ by two ways and I get different solutions.

First, I substitute $u=\cos x$. Therefore, $$\int \frac{-\sin x}{\cos^3x}dx=\int u^{-3}du=-\frac{1}{2\cos^2x}+c$$

Second, I ve rewritten the integral and I substitute $u=\tan x$:

$$\int \frac{-\sin x}{\cos^3x}dx=\int -\tan x \sec^2xdx=\int -udu=-\frac{\tan^2 x}{2}+c$$

What is wrong with the solutions above? Are they same results?

I am sorry if this is very elementary.

Thanks for any help

user519955
  • 1,335

1 Answers1

2

This is a typical phenomenon in trigonometry integrals. Both integrals are correct. The point is using trigonometry formulas you can make similarities between the answer of integrals. You only need to keep in mind that, for instance, $$f(x)+c=f(x)+1+c=f(x)-0.5+c=\cdots.$$ This is because any number can be embedded in the unknown constant $c$.

$$\sec^2(x)=\frac{1}{\cos^2(x)}=1+\tan^2(x)$$ So in your case, you can write: $$\frac{-1}{2\cos^2(x)}+c=-\frac{1}{2}-\frac{1}{2}\tan^2(x)+c=-\frac{1}{2}\tan^2(x)+c-\frac{1}{2}=-\frac{1}{2}\tan^2(x)+c'$$

khashayar
  • 2,413