I just want to add the following if you try to write a solver - Minesweeper is NP complete (Archive Link). That means until someone proves P = NP it might be possible that you can do nothing better then performing a brute force search in some situations (but maybe the game it is not NP complete for small fields).