---------------------------------------------------------------
  
           On-line HELP documentation for Fourier Scaling
  
  ---------------------------------------------------------------
  
  The first thing that must be done with new film data is to build the
  reflection scratch file.  This file is required for calculation of the
  coefficients (Option 3) and for making an output file (Option 4).
  
  In the first pass through the data file, film identifier fields and
  resolution limits are collected and sorted. The reflection scratch fil
  is built in the second pass.
  
  You also have the option of including previously scaled data at this
  point, provided you have saved the old scratch file (FS0002.DAT) and
  coefficient file (FS0003.DAT) by renaming them.
  
  A one letter code (eg. N for native, D for derivative) is assigned to
  identify the films for segragation when the output file is created
  (Option 4). This code is ignored when the films are scaled.
  
  
  
  
  
  
  Any operation which changes the Fourier coefficients causes them to
  be written to a scratch file named FS0003.DAT. The reflection file, na
  FS0002.DAT is also available (it isn't scratched) after each run. You
  therefore reenter the program at any time to continuing processing at
  same point where you left off, provided these files are intact.
  
  You should not try to do this if you have already scaled other data in
  same (or different) run, since recovery will have no effect - it will
  up the same data as the current run.
  
  
  
  
  
  
  
  
  
  
  
 3
 3     The calculation of the coefficients is the most complex and time-
 3consuming operation in the Fourier package. Each film is assigned
 3a correction surface represented by it Fourier expansion:
 3
 3                 A(x,y) = Sum: [a(m,n)cos(m*x)*cos(n*y)]
 3
 3for m=0 to MMAX and n=0 to NMAX.
 3
 3Four overlays of subroutines are involved in the computation: FSG, FSS
 3FSAMN, and FSR. FSG and FSSOLV are prescaling routines called if more
 3one film is being scaled. The coefficients are determined in the overl
 3FSAMN, provided coefficients other than the a(0,0) terms are required.
 3R-factors are computed in the overlay FSR. Each of these overlays gene
 3its own printout, and is identified by the overlay name and time of en
 3
 3After each iteration, the refined Fourier coefficients are saved in
 3a formatted control file named FS0003.DAT. This file and the reflectio
 3scratch file may be used to restart the program (Option  ).
 3
 3The user must enter MMAX and NMAX (above) to begin scaling.
 4
 4     This option creates a final scaled output file (of the DORGBN typ
 4
 4     The correction surfaces previously calculated (Option 3) are appl
 4to all measurements. If enabled, partial reflections are summed and
 4inconsistent observations are rejected. An assortment of R-factors and
 4reflection tallies are also printed. Final structure factors and their
 4estimated standard deviations are calculated. A one letter code may be
 4used to select which films are to be included in the output file, if m
 4than one derivative is present.
 4
 4The user must specify:
 4        . Whether partial reflections are to be summed (def: yes).
 4        . The data screening factor "beta" (more on this later).
 4       3. How many rejected reflections are to be printed (def: 0).
 4
 4
 4
 4
 4
 5
 5    This option calculates and plots the radially symmetric correction
 5surface of each film. This provides a quantitative estimate of the ext
 5crystal decay or disorder (when scaling native and derivatives).
 5
 5   No user input is required.
 5
 5
 5
 5
 5             **************************************
 5             *                                    *
 5             *   Decay plot not yet implemented   *
 5             *                                    *
 5             **************************************
 5
 5
 5
 5
 5
 6
 6Routine: FSPLOT
 6Purpose: Makes a  -dimensional representation of the Fourier correctio
 6         surface.
 6Input:
 6     There is only one prompt in this routine:
 6          IDENT,IOP1,IOP2 *
 6where -
 6     IDENT = an identifier corresponding to a film scaled by FS.
 6             If zero or negative, the routine returns to the menu.
 6     IOP1  =   to make a printer plot only.
 6               to make a contour plot only (41 by 41 binary)
 6             3 to make both types of plot.
 6     IOP2  = 0 to plot the entire correction.
 6            >0 to plot the terms other than a(0,0)
 6
 6Output: The program will tell give the range of the correction surface
 6     and, if a contour plot is made, the name of the plot file. This
 6     name will be of the form Fnnnnn.DAT where nnnnn=IDENT.
 6
 6
 7
 7    This option provides the capability of averaging the correction fo
 7reflection at a particular point on a film with the corrections at the
 7point on nearby films. This operation can easily be shown to be equiva
 7to preaveraging the coefficients themselves. Preaveraging has substant
 7computational advantages over averaging during the creation of the out
 7file.
 7
 7Coefficient averaging is not universally recommended. It may be most u
 7for crystals which show little decay.
 7
 7The user must input weighting factors for the nearby films. The number
 7of weighting factors is an odd number from   to  1. They will be norma
 7before applying the weights. Adjacent films are indicated by their fil
 7identifiers. For example, if 5 weights are entered, the coefficients f
 7film  8 will be averaged with films  6 through  0.
 7
 7
 7
 7
 8
 8This option selectively dumps the contents of the common blocks in the
 8program. Variables dumped are [current limit is in square brackets]:
 8
 8NTT: LU for user terminal input     NPRINT: LU for printed output
 8NUTIL1,2: Utility LU's              NSCR:   LU for reflecton scratch f
 8NHELP:  LU for help file            NDIM1:  Max. # film identifiers [8
 8NDIM2:  Max. coefficients per film [20]
 8NFILM1: Number of films present [NDIM1]
 8NFILM2: Number of good (scalable) films present [NFILM1]
 8MMAX:   Limit for x order [10]      NMAX:   Limit for y order [10]
 8NM:     # coeffs per film [NDIM2]   NITER:  Total # refinement cycles
 8NDIMZ:  Size of Z array             BETA:   Variance inflator
 8RMIN:   Low res. limit (Ang)        RMAX:   High res. limit (Ang)
 8TIME,DATE: ASCII strings with time and date
 8PFLAG:  TRUE if partials ignored    OFILE:  Output file name
 8
 8If NFILM1>0, program then prompts to continue with list of films.
 8This list includes film identifier, derivative code (1 character),
 8and film refinement status character: "*" means ignore,  "-" means use
 8the film but do not refine the coeffs.
10
10                         General HELP                   (panel   of  )
10
10         Fourier scaling is a method of crystallographic data
10reduction. Input consists of any number of files corresponding to
10precession and/or rotation films. Output consists of a master file of
10scaled structure factors suitable for further processing. Films are sc
10to each other by applying a rectangular correction surface expressed a
10Fourier summation in cartesian coordinates. The coefficients of the
10expansion are obtained by least squares, by minimizing the discrepanci
10among reflections which are equivalent by the symmetry of the reciproc
10lattice. Because the expansion can approximate a general surface, most
10types of systematic error can be cancelled at the same time.
10
10
10
10
10
10
10
10
  
                           General HELP                   (panel   of  )
  
  The normal sequence of operations is:
  
             Build the reflection scratch file
          3  Calculate the Fourier coefficients
          4  Create a scaled output file
  
  Once the coefficients have been calculated, you may also:
  
          5  Make a decay plot
          6  Make a correction surface plot
          7  Average the coefficients
  
  You may exit at any time (Option 0) and continue later by recovering
  the old coefficients and reflection scratch file (Option  ), since the
  coefficients are saved in a file after every scaling iteration.
  
  A status report (8) dumps the contents of the common blocks.