Came here because we're having a similar problem with our Model S. Driving on a rainy night with system on "Auto" mode and window started fogging up. Turned defogger on, both defrost, and defog mode, and didn't have real effect until manually turning the fan to "11". Left it in that mode, and ~20 minutes later the window suddenly and dangerously fogged up entirely, blocking vision. Cycled defogger to defrost, off, and then back to defog, turned fan back to 11, and window cleared. However, ~20 minutes later, same thing happened again - and this has repeated at least 4 times!
Keep in mind that the window is suddenly fogging with the defogger having been on for a while on '11'!
What could cause this? We had the window repaired recently. Could this be a flaw in how it was installed?