IBM Release 1.93 manual Macro

Models: Release 1.93

1 93
Download 93 pages 50.46 Kb
Page 17
Image 17
MACRO

given name and field component. The parameters xsize, ysize, zsize are not macro parameters, but will be supplied from the current context when the macro is expanded. Note the string concatenation used to generate the file names.

MACDEF FieldAll(kwd, fname)), /* Make I and Q field files

 

/* with appropriate file names and symbolic limits

 

FIELD variable=kwd xlo=0 xhi=xmax ylo=0 yhi=ymax ,

 

zlo=0 zhi=zsize phase=0.0 state=steady file=fname’i’; ,

 

FIELD variable=kwd xlo=0 xhi=xsize ylo=0 yhi=ysize ,

 

zlo=0 zhi=zsize phase=2*atan(1) state=steady /* etc

 

file=fname’q’;

 

 

 

 

MACRO

Expand a user macro. Unlike MACDEF, which must be in the

 

GLOBAL group, MACRO can be used anywhere. Macro expansion

 

is typographical, like C macros. String concatenation is performed,

 

as shown in the previous example.

 

Syntax: MACRO name(arg1, ..., argN);

 

Example: Using the example from the MACDEF statement,

 

MACRO FieldAll(Ex, Ant01Ex);

 

is equivalent to

 

FIELD variable=Ex xlo=0 xhi=xsize ylo=0 yhi=ysize ,

 

zlo=0 zhi=zsize phase=0.0 state=steady file=Ant01Exi;,

 

FIELD variable=Ex xlo=0 xhi=xsize ylo=0 yhi=ysize ,

 

zlo=0 zhi=zsize phase=2*atan(1) state=steady ,

 

file=Ant01Exq;

 

 

 

 

POSTPROCESSOR Tell POEMS which postprocessor executable to use (currently the only choice available is empost).

Syntax: POSTPROCESSOR <postprocessor command line>

PRINT

Print output, similar to the REXX SAY statement. Any number of

 

arguments may be supplied, and strings and expressions may occur

 

in any order. Strings inside double quotes will be printed as is,

 

whereas expressions will be evaluated first. PRINT statements are

 

executed each time the input file is parsed, i.e. at the beginning of

 

the run and before each tempest iteration.

13

Page 17
Image 17
IBM Release 1.93 manual Macro