Minor edit in mulgrids optimize()- changed syntax of exception for consistency with other exceptions