find maximum integer partition product by finding patterns