Find the following indefinite integral, identifying any rules of calculus that you use:

I think I need to use integration by substitution, so have rearranged to give:

I am not quite sure what to do next. The formula I have for integration by substitution is:

, where u = g(x)

Would I then get

f(x) =

and

g(x) = , so u = -cosx

or do I need to integrate both parts first as they are both composite integrals and then use the above formula on the answers I get?

Thanks for any help in advence