1. Let so that

Hence we have which may or may not be a standard integral. I'll outline the integration below:

We know from our trig identities that so let's sub that into the integral:

We know that so then the reverse must be true: (the constant will be added later)

Thus where C is the constant of integration.

Back substitute to get your integral in terms of x

2. I'd go with a double angle identity:

which can be rearranged to give

In your example and hence .

The integral of cos(ax) is for constant, non-zero a.