Computing high order wave aberration coefficients from variations of best focus for small artificial pupils