cemulate/polyomino-solver

Some optimizations about "_generateAllPossibleConfigurations" function

Closed this issue · 2 comments

When Polyomino is centrosymmetric or left right symmetric, repeated calculations are performed, resulting in multiple identical configs
image

I implemented this optimization in C++, but I am not familiar with JavaScript. Some of the features of C++and JavaScript are not the same, and I am unable to implement them

Thanks for the idea! It wasn't at all bad to implement. On the following test case, this optimization cuts down the SAT problem from 2768 variables and 889052 clauses (originally) to 1692 variables and 358086 clauses (the SAT methods still take forever to solve this problem, however).

image

Fixed by 1c824d8