Consider:

where are constants.

If we use the substitution:

then we have:

If the argument of the cosine function is non-linear, that is, its derivative is not constant, then you will need a function that is a constant times this derivative as a factor to the cosine function within the integrand in order to use this substitution technique.