Good job trying to figure out the timeline for your purchase. I've worked with buyers who know what they are looking for and can decide within a few days after seeing a specific handful of homes. I've also worked with buyers who need a lot of time and patience to "feel right" about their home. In any instance, you should keep a 45 day time frame, because there is a possibility of an issue coming up at the last minute, which is not to say you cannot close - it just takes extra days to resolve that. If you are ready, there is no problem selecting a 30 day closing date, however, just keep in mind that you may have to make a shift. It is possible that the seller may negotiate the closing date a little further than what you might want.
Remember that the transaction process involves not just you and the sellers. The mortgage company has to coordinate with their underwriters and appraisers, and the Title Company has to coordinate this with the lender, and both parties. Inspections, Surveys, Appraisals, HOA, Home Warranties, are just a few items that tie all of this together. Your agent will help coordinate all of this, but you should be aware constantly to make the process smoother.
All of the above is for regular resale transaction. If a foreclosure or short sale is involved, that changes the timeline. If you are buying a new home, give it 4 to 5 months now.
I like to educate my clients on the transaction process to give them a good idea of what they will be involved with, so they don't feel stumped unnecessarily.