DIFFLMRG - MERGE DIFFLAUE OUTPUT FILES ====================================== INTRODUCTION The program DIFFLMRG is used to sort and merge a number of DIFFLAUE output MTZ files. The program assumes that the same columns are present in each of the input files and that they are in the order produced by DIFFLAUE. The program was written by J.W. Campbell, Daresbury Laboratory. List of sections: Data Control Cards Input and Output Files Running the Program Notes Printer Output Error Messages Program Function References Examples DATA CONTROL CARDS If the program is run in interactive mode the items will be prompted for as indicated. Data Card 1 NFILES The number of input files to be merged Data Card 2 TITLE Title for the output MTZ file containing the sorted and merged data (max of 70 characters) INPUT AND OUTPUT FILES The input files are: a) The control data file b) The input MTZ reflection files which were written by the program DIFFLAUE. All files must have the same no. of columns in the same order. The files will have 7, 8 or 9 columns. The columns are H K L FL1 SIGL1 FL2 SIGL2 and optionally PHI and/or W. The output files are: a) A reflection data file in standard MTZ format containing the sorted and merged Laue data. The columns will be the same as those for the input MTZ files. RUNNING THE PROGRAM Use the command 'laue difflmrg' If the default TERMINAL is accepted for DATA the program will be run interactively and the required control data items will be input from the terminal. Parameters: DATA The control data file. HKLIN1 The first input MTZ file. HKLIN2 The second input MTZ file. HKLIN3 etc. as needed HKLOUT The output reflection data file containing the sorted and merged reflection data. NOTES None. PRINTER OUTPUT The printer output starts with details of the first input MTZ data file including the number of reflections read. Details of the header information of the output MTZ file are then given. The output continues with details from the other input MTZ data files again including the numbers of reflections read. A summary table then gives details of the following items: * Total number of reflections read in * Number of reflections omitted because of sigma(F) values of zero. * The number of reflections for which there are multiple measurements. * The number of merged reflections written to the output file. ERROR MESSAGES a) Errors in the control data **A MINIMUM OF TWO INPUT FILES MUST BE SPECIFIED** b) Errors during the running of the processing of the MTZ files **NO. OF COLUMNS MISMATCH BETWEEN FILES** (All input files must have identical structures) **MAXIMUM OF n REFLECTIONS EXCEEDED** (n indicates the current maximum no. of reflections which can currently be handled by the program e.g. 50000) **INDICES OUT OF RANGE -127 TO 127, HKL = h k l ** (h k l are the indices of the offending reflection) **NUMBER OF COLUMNS INVALID FOR A DIFFLAUE O/P FILE** (DIFFLAUE output files should have 8, 9 or 10 columns) c) Other MTZ file handling errors Other error messages may be produced by the MTZ file handling routines. PROGRAM FUNCTION The program DIFFLMRG is used to merge data from a number of DIFFLAUE output MTZ reflection data files. The data are also sorted on h, k and l. For reflections with more than one entry, weighted averages are taken for the FL1, SIGL1, FL2 and SIGL2 columns. For the phase and weight columns (if present), the first values encountered are taken and no averaging is done. The program assumes that the same columns in the same order are present in the all of the input files and that the columns are those expected from DIFFLAUE. The program has a number of reflections limit built in (50000 in the original implementation). REFERENCES None. EXAMPLES Example of the control data for merging 3 DIFFLAUE output files. 3 MERGED DATA SETS A26, A27 and A30