createh3ddatatype

Creates a datatype to be added to the H3D file.

Syntax

R = createh3ddatatype(fid, label, format, bind[, layers, hasCorners, pools])

Inputs

fid
Integer representing the file ID, returned from createh3dfile().
Type: double | integer
label
A label for the datatype.
Type: char | string
format
A string defining the type of data storage: scalar|vector|2Dtensor|3Dtensor.
Type: char | string
bind
A definition of the datatype support: 'node' or 'elem' are supported.
Type: char | string
layers
Optional argument. You can provide a matrix with layer IDs or a string cell with their name.
"all"
All previous layers are added to the datatype.
"none"
The datatype will not contain layer data.
Type: matrix | cell | string
hasCorners
Optional argument, specifying if there is corner data. Allowed values is 'corners'.
Type: char | string
pools
Optional argument. You can define results in different pools.
Provide the pool index (or indices in the matrix) or name (or names in string cell).
Type: integer | matrix | cell | string

Outputs

R
Index of the datatype in the H3D file.
Type: double | integer

Example

% Create H3D file
idx =createh3dfile(resultFile, 'append')
	
% Create H3D layers
lidx1 = createh3dlayer(idx, 'Layer 1');
lidx2 = createh3dlayer(idx, 'Layer 2');
	
% Create H3D pools
pidx1 = createh3dpool(idx, '2D');
pidx2 = createh3dpool(idx, '3D');

% Create datatype
tidx1  =createh3ddatatype(idx, 'Element Stresses', '3Dtensor', 'elem', 'pools', [pidx1 pidx2], 'layers', [lidx1 lidx2]);
	
closeh3dfile(idx)

Comments

It is not possible to create the same data type twice.