I'm not sure where you're coming from. Do you know the answer already, is this just a little puzzle for us?
If not, what do you know about trig that might help you? I notice we have a cos^2, which suggests a half-angle identity, and a pi/8 (half of a half of a half), which again suggest a half-angle identity. Do you know those identities? If you don't, you can find them online if necessary and work this out.