The three icons above when opened to their dialog display a checkbox like the one below. The purpose of this option is to permit you to have certain parameters change with each iteration of a loop. You will notice that this box is not visible unless the dialog has been opened from an icon.
Selecting the file in these cases occurs after you close the dialog box associated with the icon with the "Batch file" check box checked. A moment after closing a standard file selection box opens. If you see the file you have prepared, select it. If the file is not selectable it may need to have an appropriate file extension. Acceptable file extension are "text","TEXT","txt","TXT","csv","CSV".
The
direct propagation icon and the zonal lens icon have equivalent options in their
dialogs. They each have at least one field (distance for direct
propagation and focal length for zonal lens) which may be filled by taking records
containing up to 5 numbers for the lens function and 7 for the direct propagation
option. The numbers are taken in order up to a carriage return from a text file.
On each execution of the icon a new focal length or propagation distance will
be used followed by other fields in order up to 5 or 7 until the list is exhausted,
at which point execution of the script may stop. So if you wish to change the
center of the view in each view of a direct propagation you will need to make
a table with 7 columns with the centers in the last two columns. Zeros in any
column will result in the previous value being entered with the exception of
the last two columns, where zero are a reasonable entry and will be entered
a zero. Note again tables that are no wider than you need are ok as long as
the first column contains a usable number and something (zero) is put in for
unused columns. In each of these windows the columns read left to right are
entered from top to bottom in the dialog. No more fields will be used than are in the window.
You will find that the "rotator" window does not show a batch button until you have enabled the
"something else" text box.
If the batch box is clicked an additional box will be displayed which gives the option of having the current distance displayed upon the scripting window. (lower left corner) This option will not be saved with the script but must be reentered each time you wish to watch the progress. This avoids clutter on the screen.
Execution may stop at the end of the file. If a (green) branch line has been provided, however, execution will branch rather than quitting when the table of entries has been exhausted. If execution returns to this icon after branching, the batch will restart from the beginning of the file.
The rescale icon first pain
has up to four fields that can be filled by a batch file. When you
have activated the batch file option and selected the batch file the fields
are filled in order: multiply real part then imaginary
part then add real part then imaginary part.
This takes four numbers up to a carriage return from the file. On each execution
up to four more numbers are taken. If there are more than four number in the record they will be ignored.
If the "Formula" or "Quick Calc." panes are displayed then [up to] seven
entries are defined as variables "c1" to "c7". When the list is exhausted execution stops or branches.
The best way to prepare this list is to use a spread sheet and
save the result as tab or comma separated text file.
When a script is saved the data loaded from the batch file is not saved with the script, the name of the file and location is saved instead. If it is not in the expected place the file will, if all is well, be hunted down by the program. Just in case you should include the name of the file in a "read me" icon and save it with the script.
When execution reaches a point where it tries to read one more record than is supplied execution will stop silently and the icon will be left highlighted. But, if an alternative (green) path has been provided, rather than stopping, execution will continue along the branch path, and the batch will restart. All of these icons can so branch. So can some others.
Because the program is so often before me I find it convenient to make small tables of one or two
colums of data by using the "clip text" icon
and just preparing the data with a short script. When clipped these can be pasted into Excel or Numbers.