added global cost constraint version; pretty slow