VariablesWithMesh » History » Revision 1
Revision 1/2
| Next »
Ted Sume, 11/13/2019 02:58 PM
VariablesWithMesh¶
Variables that are combined with their meshes¶
Particle data is often written out in such a way that the points and velocities (or other internal particle variables) are in one array. This page describes the metadata for this situation.
Jump to
- Variables and their metadata
- Variables that are combined with their meshes
- Data ordering
- Variables defined in terms of other variables
- Multidomain metadata
- Other metadata
Particle data
Dataset "electrons" {
Att vsType = "variableWithMesh" // Required string
Att vsNumSpatialDims = 3 // Either this or vsSpatialIndices is required
Att vsLimits = "mylimits" // Optional string
Att vsTimeGroup = "mytime" // Optional string
Att vsIndexOrder = "compMinorC" // Optional string, defaults to "compMinorC", denoting whether
// the variable index or the data index varies most rapidly.
DATASPACE [n0, n1] // Required float array
Att vsLabels = "x, y, z, dx, dy, dz" // Optional string
}
- vsNumSpatialDims indicates the number of variables that are spatial positions. These are in the first positions.
- vsLimits indicates a visualization region
- vsTimeGroup indicates a time group for this data
- vsIndexOrder is "compMinor" by default, which means that the variable index is last. If "compMajor", then the variable index is first.
- vsLabels gives user-friendly names for the components of this variable. See Variables for more information.
Specifying the Number of Spatial Dimensions
A VariableWithMesh allows two different methods to specify the number of spatial dimensions.
The first is the attribute vsNumSpatialDims. If given, it is assumed that the spatial information is contained in the first components of the variable. If vsNumSpatialDims is "3", the variable will be marked as a 3-d variable, with position information in the first, second, and third components of the variable.
The second is the attribute vsSpatialIndices. This is an integer array that specifies which components of the variable contain spatial information. This attribute is most useful for cases where the position data is interspersed with other data, such as velocity. A classic example of this is synergia, which outputs velocity data between each column of position data. For a synergia file with the components "x, dx, y, dy, z, dz", the user would give a vsSpatialIndices value of [0, 2, 4].
Note that a value of [0, 1, 2] is equivalent to a vsNumSpatialDims value of 3. In general, the vsSpatialIndices attribute can express all of the same information as vsNumSpatialDims.
Updated by Ted Sume about 5 years ago · 1 revisions