notes on using directories of MATXS files

These notes are meant to supplement the description of how to use TRANSX and BBC in the TRANSX Manual (LA-12312-MS) for users who would like to take advantage of the new capability to work with a directory of single-material MATXS files instead of the more conventional multi-material libraries.

This new option was added to make it easier to work with some of the very large libraries now becoming available in MATXS format. Libraries containing 100 MB of data and more are very time consuming to read, and they are difficult to move over the Internet. They are especially difficult to use on smaller machines, such as notebook computers. Storing the MATXS library as a directory of single-material files makes it very easy to reduce the size of the library for a particular set of applications; the user simply omits the materials that are not needed. When downloading materials from the Internet, no single file will be too long for reliable retrieval, and only the materials needed for the job need be requested. In addition, it is often faster to run TRANSX from the directory rather than from the multi-material library. Each material is accessed randomly when needed, and the code does not have to read through a lot of other numbers to find the desired data.

In TRANSX 2.15, the directory mode is requested by giving NGROUP negative and by adding a card just after the NGROUP card containing the name of the directory. For example, the input for test problem 1 would become

   test 1 -- material ordered tables
   0 1 0 1 1 1 0 3 0 0
   -30 2 34 0 0 3 1 6 1 1
   *matxs10/*/
   carbon tungst u-235
   * */
   1 1 cnat/
   2 1 w182 .263/
   ....
Note that the slash at the end of the directory name must be given as shown. The material names in the mix instructions must be the same as the file names in the matxs10 directory.

In order to make efficient use of this new scheme, it was necessary to add a number of new options to BBC. For example, MATXS libraries are normally delivered in ASCII mode, and they must be converted to binary mode before they can be used in TRANSX. An example of making this conversion using BBC 2.5 follows:

    -2 2 0 0 1
    *text10/*/
    *matxs10/*/
    h1 h2 h3 he3 he4 ... /
The -2 in the first line indicates that the input for BBC is to be taken from a directory in ASCII mode, and the +2 indicates that the output is to be written to a directory in binary mode. The two directory names are given in the following two lines. The user must create the output directory before running BBC. This sample also requests that an index be constructed. It will look very much like the index for a normal multi-material MATXS library.

Whenever input from a directory is requested, the user must provide a list of the file names to be processed, and the names must be given in the order desired for the output file or the index listing (typically ZA ordering). This list is the line "h1 h2 h3 ..." in the above example. In order to make it easier to construct such a list, a small program called ZASORT has been included in the new distribution. This program takes a list of material names (e.g., h1, be9, monat), one per line, as its standard input file, sorts them into ZA order, and writes the new list on the standard output. Therefore, the following unix command will generate the list required to read in an entire directory for conversion:

    ls text10 | zasort > list
It is only necessary to insert "list" into the input file for BBC, not forgetting to add a terminating / to the end of the list.

If the user would like to create a multi-material MATXS file from ASCII data on a directory, the following input could be used:

    -2 1 0 0 1
    *text10/*/
    h1 h2 h3 he3 ... /
    101 *bbc user*/
    *example of a multi-material matxs file*/
    *constructed from a directory of single-material*/
    *text files using bbc 2.5*/
    /
In this case, the first 1 on the first card will cause the output to be written to a binary file called "matxs". It is now necessary to provide the information to fill in the version field on the new library, and the number "101" has been selected. The Hollerith descriptive data on the library is provided as shown. The empty line terminates the descriptive input.

A directory of single-material files can be created from a multi-material file, such as matxs10 in the TRANSX distribution. The input for such an "explosion" run is as follows:

    1 2 0 0 1
    *matxs10/*/
The 1 on the first card causes input to be taken from a file named "matxs", and the 2 causes the output to be written into the directory "matxs10" in binary mode using file names derived from the material names on the matxs input file. No material list or descriptive data are needed for the explosion option.

The formal input instructions for BBC 2.5 are given below for the user's convenience:

  c  ---input----------------------------------------------------
  c
  c  card 1
  c       iinpf     input file type
  c                    2  binary file set (named by mat)
  c                    1  binary file (matxs)
  c                   -1  coded file (text)
  c                   -2  coded file set (named by mat)
  c       ioutf     output file type
  c                    2  binary file set (named by mat)
  c                    1  binary file (matxs or modout)
  c                    0  none
  c                   -1  coded file (text)
  c                   -2  coded file set (named by mat)
  c       imodf     modify flag
  c                    0  no modifications (default)
  c                    1  modifications given (modinp)
  c       list      list option
  c                    0  not listed
  c                    1  listed (default)
  c       indx      indexing option
  c                    0  not indexed
  c                    1  indexed (default)
  c  card 2   (iinpf.eq.2.or.iinpf.eq.-2 only)
  c       diri      input directory for set of files.
  c                 use *name/*/ (24 chars max).
  c  card 3   (ioutf.eq.2.or.ioutf.eq.-2 only)
  c       diro      output directory for set of files.
  c                 use *name/*/ (24 chars max).
  c  card 4   (ilist.ne.0 only)
  c       ird       record type print flags.
  c                    1  file identification
  c                    2  file control
  c                    3  set hollerith identification
  c                    4  file data
  c                    5  group structure
  c                    6  material control
  c                    7  vector control
  c                    8  vector block
  c                    9  scattering matrix control
  c                   10  scattering sub-block
  c                      one value for each record type
  c                      0  not printed, 1 printed.
  c  card 5   (imodf.ne.0 only)
  c       hoper     modify option
  c                    s  select materials from matxs input file
  c                    i  insert materials from modinp file
  c       hmat1     first material in range
  c       hmat2     last material (default=hmat1)
  c
  c     repeat card 3 until a blank line is read
  c
  c  card 6    (iinpf.eq.2 or iinpf.eq.-2 only)
  c       hmati     list of materials in the set to
  c                 be written into the output matxs file,
  c                 given in the order desired.
  c  card 7    (modifying or imploding only)
  c         modifying is implied by imodf.ne.0.  imploding is
  c         implied by iabs(iinpf).eq.2 and iabs(ioutf).ne.2.
  c       newver    new file version number
  c       huser     new user id string (up to 16 chars)
  c
  c  card 8    (modifying or imploding only)
  c       hline     line of new hollerith id data (72 char max)
  c
  c     repeat card 8 for each line of the new hollerith
  c     data block.  terminate with an empty line.  if no
  c     lines are read, the original block is unchanged.
 
  ---------------------------------------------------------------

TRANSX HyperText Manual
TRANSX HyperText Help Package
T-2 Nuclear Information Service