Hi, Welcome to the Forum.
I think the others have already discussed the distances and the coastal wind direction. It is almost 900 miles from San Francisco (SF) to Seattle. Also, from SF to Yellowstone National Park the distance is almost 1500 miles, and there is not easily accessible return transportation to SF. And yes, the wind on the coast during the summer is primarily a north wind.
What do you really want to see: coastal, forests, National Parks, deserts? Are you going to be camping or credit card touring? How many miles do you anticipate averaging in a day? Are the 4 weeks bike time or does that include travel days? When is your start date?
There are a lot of us from the west coast on this forum that have ridden a lot of this country; and I'm sure we can come up with some good alternatives that will meet your interests and time constraints.