DiffLat

DESCRIPTION

This module compares two input lattices. The items checked include

 the number of dimensions (nDim)
 the dimensions vector (dims)
 the primitive datatype (primType)
 the number of variables per node (nDataVar)
 the coordinate type (coordType)
 the number of coordinate variables (nCoordVar)
 

It also compares the data and coordinate arrays of the two lattices, reporting the number of differences, the min and max errors along with the average error. The error reporting for data and coordinates is determined by the dial parameter: Relative Error. A node-based comparison is made:

if(abs(NodeA-NodeB)) > RelativeError*max(abs(NodeA),abs(NodeB))

The number of errors reported are those which pass this test. This data and coordinate comparison is performed only if the nDim, dims vector, primType, nDataVar, coordType and nCoordVar integers are identical for the two lattices.

The output is sent to the module's standard output, which will appear in the Explorer log window or the standard output of Explorer, depending on log the configuration in effect.

INPUTS

Port: First Lattice In
Type: Lattice
Lattice A for comparing to Lattice B

Port: Second Lattice In
Type: Lattice
Lattice B for comparing to Lattice A

WIDGETS

Port: Relative Error
Type: Dial
Nodal relative error, data section

Port: Done
Type: Button
An output button. This will be reset from within the module upon completion. If the lattices compare without any differences, the button return value is zero. If the lattices have compare errors, the return value is one. This is useful for synchronizing a map.

Port: Compare Data
Type: Option Menu
Menu Item: Yes
Menu Item: No
Set to Yes or No depending on whether or not the data portion of the lattice should be compared.

Port: Compare Coords
Type: Option Menu
Menu Item: Yes
Menu Item: No
Set to Yes or No depending on whether or not the coordinate portion of the lattice should be compared.

OUTPUTS

PROBLEMS

SEE ALSO

GenLat PrintLat ReadLat
[ Documentation Home ]
© The Numerical Algorithms Group Ltd, Oxford UK. 1996