zernike - introduces arbitrary Zernike aberration into the field distribution.
Any aberration in a circle can be decomposed over a sum of Zernike polynomials. Cylindric lens can be modeled as a combination of Zernike (see below example)
We can also uniformly introduce the lens and tilt using Zernike. The difference is that lens and tilt accept conventional meters and radians, which are widely in use for description of optical setups, while Zernike uses the amplitude of the aberration, which frequently has to be derived from the technical description.
polynomials with negative n are rotated 90 degree relative to the polynomials with positive n. For example Zernike(f,5,3,1,1) gives the same aberration as Zernike(f,5,-3,1,1), but the last is rotated 90 degree.
f1=begin(0.01,1e-6); f2=circ_ap(f1,0.0045); file_ps(f2,"cl0"); f3=zernike(f2,2,2,0.0045,20); f4=zernike(f3,2,0,0.0045,-10); f5=fresnel(f4,1.55); f6=interpol(f5,0,0,0,0,45); dwf_fits(f6,"cl1");
Chen jingyuan, IAPCM, China.