redo the way that variables are transformed for nonlinear optimization