Added compiler optimizations. Takes longer to compile but seems to provide a solid performance improvement!
Made 8-point static array instead of vector
Implemented policyflip of patterns