Input and Output Formats

Input files

Reduce3D reads in files from Crystallize91, Crystallize95, Integrate, or Blob3D(?).  It can read old-style files, in which the fields have specific lengths (first 25 characters is a label, and the value follows that), or the new (better) style, in which fields are delimited by tab characters.  The file must be consistent - using tabs in the header but spaces in the body is not allowed. Note that in its output files, the program interprets all distances as having been in centimeters, but no algorithm actually requires this. If you had tiny or giant crystals and wanted to use µm or m, those would work just fine. The input file format is as follows:

Line(s) Data
1 Header line originally indicating the file format version – no longer used, but the line must be present
2 Comment string.  If made by Crystallize, this will include the Crystallize simulation parameters.
3 Optional additional comment line. Must not begin with the character “N” (which indicates the absence of the second comment line and instead the presence of the next line).  Lines two and three are combined into a single comment string, and parsed to determine the file type: a diffusion-controlled simulation (comment contains “Qd” or “diffusion”), an interface-controlled simulation (comment contains “interface”), a heat-flow-controlled simulation (comment contains “heat flow”), or a real data set (comment lacks all those strings).  Further, the comment string is parsed for a probability distribution function (pdf) which can optionally be matched by the envelope simulations.
4 Number of crystals line.
5 Total volume line (in sq. cm).
6 Optional bounds line.  This dictates the boundaries of the sample volume, independent of the set of crystals (and it overrides the data for the set of crystals).
If the text “Bound” is present, it is interpreted as a rectangular prism sample shape, and expects a string that begins with “Bounds:” followed by six real numbers, all separated by tabs.  The first three values are the coordinates of the lower corner of the prism, and the second three values are the coordinates of the upper corner of the prism.
If the text “Ctr/R/H” is present, it is interpreted as a cylinder, and expects a string that begins with “Ctr/R/H:” followed by five real numbers, all separated by tabs.  The first three values are the (x,y,z) coordinates of the center of the cylinder; the fourth is the radius, and the fifth is the height.
If none of the above applies, then there are no bounds set, unless the comment line indicates one of the simulation types.  If it is a simulation, then the sample is taken to be a rectangular prism with the lower bound at (0,0,0) and the upper bound;s coordinates at the cube root of the volume listed in line 5.
7 and up One line for each crystal, with the values separated by tabs.  The columns for each crystal are: the crystal number, the x, y, and z coordinates of the crystal’s center, the crystal’s radius, the slice in which the crystal’s center is located (slices are the individual CT scans, related to the early data flow pathway from Blob to Integrate to Reduce3D), and the crystal’s ID number (for Integrate files, this value is related to the index of the blob (2-D section of the crystal); for Crystallize simulation files, this value is related to the time at which the crystal nucleated).

A sample input file from Integrate is given below:
Integrate 2.2
John redo
Number of crystals:   4987
Total Volume (sq cm):      0.19483
1   0.77244   0.04564   0.04422   0.02500   4   600617
2   0.89878   0.04243   0.03442   0.01920   3   600584
3   0.82174   0.06202   0.03876   0.01929   3   600586
...
4987   0.85828   1.56687   0.89500   0.00847   90   27035229

And a file output from Crystallize might look like this:
Integrate 2.0 /time95 =  1.5500 Ma  temp95 = 505.50 °C   validNum = 1642, skew =  0.409 /
711.dc.1.int/exp, No = 2.500e-04, kap = 0.300, vol = 0.99, vf = 0.1028, Qd = 140.000, Dinf = 5.000e-07, T.H. = /lin/10.0, 10.000/0.0, 200.000, Tcr = 490.0, t.s. = 5.000e+04, mR = 0.0061, Bxi, seed = 74373570, pdf = 1, a:ps
Number of crystals:   2664
Total volume:      0.99100
1   0.07480   0.89142   0.32167   -0.03625   0   00000
2   0.53891   0.78786   0.52318   -0.03466   0   1742
3   0.65432   0.40680   0.69503   -0.03511   0   1812

Output Files

All output files are saved in the same directory as the input file, except the log file created when the "verbose" settting is checked.

The first line of each file is a file-type identifier, to be used by subsequent programs.  The second line is the comment line present in the input file.  In all cases, the labels are separated from the numeric fields by a tab character.  The file names are produced automatically, first by stripping off the last extension, if present and then appending one of [“.Reduce3D”, ".Reduce3DXl”, “.MeanCSD”, “.MaxCSD”, “.LogCSD”, “.RegCSD”, “.NNCSD”] as appropriate.
The Reduce3D file is the main data set, containing the results of the statistics and the settings used to produce those statistics.  The settings are saved in the text, and as a resource readable by the same version of Reduce3D that produced it, as discussed below.  The structure of the text file is as follows:

Line(s)

Data

1 Filename of input file
2 Label of Reduce3D version used to make the file
3 Comment from input file
4-61 Processing parameters
62-132 Main single-value statistics, many with envelope values on the same line.  All labels are separated from values by tab characters.
133-? Table of correlation function values and envelope values for same.  These are best not read directly, but by GraphCFs, code written for displaying these graphs.
?-? The table can be followed by a table of crystals.

Note that the Reduce3D file is created with a suffix set so that GraphCFs will open the file upon double-clicking.
The MeanCSD file consists of: a one-line header; a line with the name of the input file; a line citing the number of size classes used in generating the data that follow for the mean-normalized cumulative CSD plot;  a title line giving the name of the plot and the number of means the values were normalized to; and finally one line per size class, containing the fractional distance along the inverse normalized radius axis at the low limit of the size class, followed by the cumulative percentage of the crystals that fall into that size class.  These entries may be read simply as the abscissa and ordinate values for the cumulative CSD plot.
The MaxCSD file consists of: a one-line header; a line with the name of the input file; a line citing the number of size classes used in generating the data that follow for the maxn-normalized cumulative CSD plot;  a title line giving the name of the plot; and finally one line per size class, containing the fractional distance along the inverse normalized radius axis at the low limit of the size class, followed by the cumulative percentage of the crystals that fall into that size class.  These entries may be read simply as the abscissa and ordinate values for the cumulative CSD plot.
The LogCSD file consists of: a one-line header; a line with the name of the input file; a line citing the number of size classes used in generating the data that follow for the maxn-normalized cumulative CSD plot;  a title line giving the name of the plot; and finally one line per size class, containing the upper limit of the size class (in cm) followed by the natural log of the slope of the cumulative size distribution plot (ln [dN*/dL], in the notation of Cashman and Ferry, 1988) at that size class.  These entries may be read simply as the abscissa and ordinate values for the logarithmic CSD plot.