Modifications to problem cost function