3.4. BATCH MODE OPERATION OF BALSAC/LATTICE

next, previous Section / Table of Contents / Index Apart from interactive sessions you can run the LATTICE part of BALSAC also in batch mode. BALSAC/LATTICE starting in batch mode uses information from a set of option flags given in the structure input file. These flags refer to character codes identical to those used interactively in the main option menu, see Sec. 6.4.2. In batch mode LATTICE runs by itself according to the option flag sequence until it reaches an option flag "," (exit). This finishes the batch run and BALSAC exits to the operating system command line. Let us think of a typical batch run with a scenario a) create the lattice section, b) plot the structure, c) change the view of the plot, d) plot the structure a second time, e) finish the run. Since a) is automatically carried out in the beginning of a batch mode run you need to specify four options, b) - e). In the main option menu "plotting" is selected by the option key [X], "view" by [V], and "finish" by [,]. Therefore, the number of options is NBATCH = 4 and the string of option flags reads "XVX," (upper case characters are accepted only, see Card 1 of the input file). Option "view" requires additional input (one Card 10 defining THETA, PHI, ROT, MAGNF, PERSP, NFOC, see Sec. 6.4.2). This Card has to be added at the end of the batch file to complete the input. During the batch run you may want to save the lattice structure and additional numerical information on an output file. In this case you have to define the name of the output file and its format on the first line of the input file, see below and Sec. 6.4.2. In the following example we list the LATUSE input file 'bcc112.lat' included in the XMPLS subdirectory of the BALSAC package ----------------------------------------------------------------------------- 50 0 4XVX, 3 1.000000000 bcc lattice -.500000000 .500000000 .500000000 .500000000 -.500000000 .500000000 .500000000 .500000000 -.500000000 1 0 .000000000 .000000000 .000000000 .433012702 26 1 1 2 0 8 6 4 1 .000 .000 .000 .000 .000 0 0.00000 0.00000 .00000 1.00000 0.00000 0 16 1 4 5 0 0 0 0 50.00000 10.00000 .00000 1.00000 3.00000 0 ----------------------------------------------------------------------------- which you can use in a BALSAC run "balsac -l bcc112.lat". This will show a section of the (112) face of a bcc crystal in two different views. In the first picture you look perpendicular to the plane in parallel projection where you can identify the surface periodicity. After you press [,] the second picture gives you a perspective view of the section. You finish the BALSAC/LATTICE session by pressing [,] again. Try it out! In batch mode BALSAC/LATTICE indicates its present status by messages n. : Option = [x] where "x" is the key code of the nth option defined by the input. This line may, however, be overwritten by other numerical or graphics output of BALSAC. If BALSAC/LATTICE is run in batch mode you do not have to manually initiate plotting each layer in a layer-by-layer plot of a lattice section. Instead, BALSAC plots layer after layer waiting for some time between successive layers where the waiting time is determined by the delay parameter NDELAY given in the structure input file, see Sec. 6.4.2. On a 100 MHz Pentium PC a value NDELAY = 100000 corresponds to a delay time of about 1.5 sec. On Unix systems much smaller NDELAY values may be needed. However, when a plot is finished BALSAC always stops and waits for you to press a key allowing to inspect the plot as long as you like or to capture the graphics screen for further use, see Sec. 4.2. With the "Define atoms" option [Y] any delays are ignored and BALSAC returns to the main option menu for further options which allows batch runs without any manual intervention, see below. BALSAC/LATTICE run in batch mode is particularly useful to convert LATUSE format input files to other file formats for subsequent applications. For example, you can generate PostScript file output of a lattice section without inspecting the section by using the option flags "YO," (for options "Define atoms", "store on file", "finish") and giving a meaningful output file name in the LATUSE input file, see Sec. 6.4.2. In the following example we list the LATUSE input file 'fcc117.lat' included in the XMPLS subdirectory of the BALSAC package ----------------------------------------------------------------------------- 50 3fcc117.eps 3YO, 2 1.000000000 fcc lattice .000000000 .500000000 .500000000 .500000000 .000000000 .500000000 .500000000 .500000000 .000000000 1 0 .000000000 .000000000 .000000000 .353553391 13 1 1 7 0 8 4 10 1 .000 .000 .000 .000 .000 0 50.00000 10.00000 .00000 1.00000 3.00000 0 16 1 4 5 0 0 0 0 ----------------------------------------------------------------------------- which you can use in a BALSAC run "balsac -l fcc117.lat". This creates a PostScript output file named 'fcc117.eps' which shows a section of the (117) face of a fcc crystal. Try it out! next, previous Section / Table of Contents / Index