Jump to content

  • Log In with Google      Sign In   
  • Create Account

A* applied to minesweeper game


Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.


  • You cannot reply to this topic
46 replies to this topic

#41   Members   

127
Like
0Likes
Like

Posted 09 May 2013 - 03:15 PM

I was thinking about finding all possible combination for squares with number. 

 

 

? ? ? ? ?
? ? 2 ? ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

In this example i will find all possible locations for every number. For example square 2 in second row. 

 

 

 

? X ? ? ?
? X 2 ? ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

 

? ? X ? ?
? X 2 ? ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

 

? ? ? X ?
? X 2 ? ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

? ? ? ? ?
? X 2 X ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

? X X ? ?
? ? 2 ? ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

? X ? X ?
? ? 2 ? ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

? X ? ? ?
? ? 2 X ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

? ? X X ?
? ? 2 ? ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

? ? X ? ?
? ? 2 X ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

? ? ? X ?
? ? 2 X ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

There are 10 possible locations for mines around this square. If we find possible locations for all squares with number, then we can calculate probability without guessing and also we can be sure that all possible consistent combinations are found and here in your algorithm we do random distribution and we can't be sure for bigger tables that all consistent possibilities were computed. 



#42   Members   

20272
Like
0Likes
Like

Posted 09 May 2013 - 08:45 PM

You don't know if all those 10 distributions of two bombs around that "2" are equally likely or not.

#43   Members   

127
Like
0Likes
Like

Posted 09 May 2013 - 11:01 PM

You don't know if all those 10 distributions of two bombs around that "2" are equally likely or not.

What do you mean? I didn't understand you. If these 10 distributions are all possible for square "2", and if we find for rest of squares all possible distributions, we can make all combinations between all squares with numbers and only possible combinations will be found.



#44   Members   

20272
Like
0Likes
Like

Posted 10 May 2013 - 07:40 AM

Oh, perhaps I didn't understand exactly what you proposed. Would you mind fleshing out your algorithm so I can understand better?

#45   Members   

127
Like
0Likes
Like

Posted 10 May 2013 - 08:42 AM

ok, look at those 10 combinations. 

 

 

? B C D ?
? A 2 E ?
? 2 2 1 1
? ? 1 0 0
? ? 1 0 0

 

These 10 possibilities are: ab,ac,ad,ae,bc,bd,be,cd,ce,de. Now we can do same thing for rest of numbers and if we pair each possibility for each square with possibilities from another squares and do intersect, we will get all possible positions of mines and not mines. I was thinking about applying this algorithm first and then we can apply your algorithm. Maybe it can give better results.



#46   Members   

20272
Like
0Likes
Like

Posted 10 May 2013 - 08:57 AM

The "pair each possibility for each square with possibilities from another squares and do intersect" part sounds ill defined to me. If you can describe an algorithm to do that, that would be great. Otherwise I can't tell if it would work without bias or not.

#47   Members   

127
Like
0Likes
Like

Posted 13 May 2013 - 09:09 AM

The "pair each possibility for each square with possibilities from another squares and do intersect" part sounds ill defined to me. If you can describe an algorithm to do that, that would be great. Otherwise I can't tell if it would work without bias or not.

Check your private messages.






Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.