Freenode, like other IRC servers, has the property that one's connection will drop at the slightest hiccup. Fortunately mIRC knows to automatically reconnect when this happens.
The problem lies with some channels such as #ai, which cannot be joined unless one's nickname is registered. mIRC doesn't know how to send the password to NickServ, and even if it did, at the time it reconnects, the original connection is still present on the server as a ghost; it doesn't know to wait a few minutes for the original connection to be garbage collected; thus it is not able to stay on such channels.
Is there a way to solve this problem either with mIRC or some other IRC client that runs on Windows?