move patterns to Pattern module from Board class