What is wrong with my two solutions for indefinite integral? Are they the same result?

90 Views Asked by At

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

1

There are 1 best solutions below

0
On BEST ANSWER

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'$$