You may remember from your math class that \(\displaystyle\int \cos x \, dx = \sin x + C\), but what happens if it is integral of -cos x?
Negative sign is a multiplication by (-1)
To get from $\cos x$ to $-\cos x$, we need to multiply it by a negative one:
\[ \begin{align*} (-1) \cdot \cos x = – \cos x. \end{align*} \]
So we are multiplying it by a constant and can use the formula:
\[ \begin{align*} \displaystyle{\int} Cf(x) \:dx = C\displaystyle{\int}f(x) \:dx \end{align*} \]
Computation
\[ \begin{align*} \displaystyle{\int} -\cos x \:dx = \displaystyle{\int} (-1)\cdot \cos x \:dx = – \displaystyle{\int}\cos x \:dx = \boxed{- \sin x} \end{align*} \]
Good luck with your future math adventures!