working version of objective function measures