2. HOW POEMS WORKS
2.1. Program Organization
The POEMS system consists of six parts: the
2.2. The Front-End Script: poems.cmd
The front end script poems.cmd is the part of POEMS that the user will interact with (almost exclusively). It parses the input file, performs error checking, and handles all the symbols and equations. It generates the intermediate files that are used as input by FIDO/TEMPEST and EMPOST, and produces log files and console output to keep the user informed as to the progress of the run. The script is written in REXX, whose advanced parsing capabilities and very flexible stem processing made it a natural choice. Speed is not a serious issue, since only a tiny part of the run time is spent in the REXX code; almost all is used in the FDTD simulation.
2.2.1. Script Operation
The concept underlying the script’s design is that the user should be able to optimize or step anything he likes, in any combination. Therefore,
a.Enter SETUP mode
b.Parse the input file and set all the variables. Note which variables are to be stepped or optimized (the controlling variables).
c.Enter OPTIMIZE or STEP mode. For each iteration,
(i)Update the controlling variables for the current iteration
(ii)Parse the input file, setting all the variables except the controlling ones. This preserves all the dependencies.
(iii)Generate the intermediate files for FIDO/TEMPEST and EMPOST, based on the current values of all the variables.
(iv)Run FIDO/TEMPEST, capturing its console output to a file.
(v)If FIDO/TEMPEST fails, stop. If it succeeds, call EMPOST to generate the inputs to the
6