update phi