Extra accuracy for near-axis rays.
In the mesh method of ray tracing an option exists for 'improving' the near-axis values of Er, the radial component of the electric field. The option is accessed in Databuilder/Tracing the rays/method of tracing and accuracy. This option is loosely related to the option in CPO3D to improve near-axis fields by a user-supplied routine.
The program starts by finding the values of Er at the mesh points at a particular value of z and at values of r up to a pre-set maximum r_max specified by the user. These values are then put into a least-squares fit to find the parameters a and b in the expression
Er = a. r + b. r^3
(which is the expected theoretical dependence). The values of Er at the mesh points from r = 0 to r_max are then replaced by those derived from the parameters a and b. This type of replacement is carried out at all the relevant values of z, as specified by the user The z components of the field and the potentials at the mesh points are not altered.
More precisely, the program uses only half the values of Er -those that have the largest values of r. Also, when the number of values is 4 or more a fifth order term is included in the least-squares fit.
The user specifies r_max, the maximum value of r, together with the minimum and maximum values of z.
Care must be taken in choosing the value of r_max. If it is too large the dependence of Er on r might not be cubic, and if it is too small the dependence might not be smooth. If it is very large it might cover some electrodes, in which case the dependence on r would certainly not be cubic!
Before choosing r_max the user should investigate the dependence of Er on r at a few values of z (but not in regions of very weak field). For cylinder lenses (for example xmpl2d01.dat) a suitable value of r_max seems to be about 40% of the radius of the lens.
The improvement of Er should be carried out only in critical regions, and not for example in regions of low field that the rays pass through.
If the printing level is high enough the coefficients a and b will be put in the output data file.
An example of the use of this option is given in xmpl2d17.
The near-axis information is automatically saved for re-runs, and is re-used if no relevant parameters have been changed (the box still appears, but finishes more quickly).
Return to general note on ray tracing.
For users who are editing or constructing an 'input data file' without the use of the data-builder -that is, pre-processor:
But Manual editing is certainly not recommended -it is a relic from the time when the databuilder was not available All users are strongly encouraged to use the databuilder, which always gives the correct formats and which has many options for which the formats are not described or easily deduced.
The letter 'M' is used instead of 'm' (in the line that asks for the method of ray tracing).
The maximum value of r is put on the next line, together with the minimum and maximum values of z.