Code Suggestion to Get Date for Previous Thursday

Code Suggestion to Get Date for Previous Thursday

Greetings all...

Any quick code suggestions for calculating the correct date for the previous Thursday from a certain date....

Ex:

The date given is Tuesday, August 20, 2013.  What is the date of the previous Thursday?

I know there has to be some use of the varied date functions here but I can't seem to get my mind around the correct logic.

Thanks,

Joel