10.15. Vector Glyph File Format

This file contains vector glyph information. Vector glyphs can represent static or transient forces or moments. These vectors can be located at a node id, an element id, or an x,y,z location. Transient vector glyphs can change value and/or location over time.

This file format is referenced from and EnSight Casefile, with a line in the GEOMETRY section, as such:

vector_glyphs: filename.vgf

See EnSight Gold Case File Format for more detail on the EnSight Casefile.

10.15.1. General Comments

  • This is an ascii file.

  • Comment lines are allowed in the file. To be a comment, the line must begin with a # sign, or be a blank line.

  • Each non-comment line begins with a keyword. When multiple lines are needed for a given keyword entry, the keyword is repeated on each line.

  • The various tokens on a given line must be separated by spaces. Do NOT allow the number of space separated tokens to exceed 15 on a line.


Note:  This restriction really only applys to the TIMELINE times: line. All others have a set number of tokens per line.


5. Transient timelines are specified separately, so they can easily be applied to multiple vector glyphs. Static vector glyphs do not reference a timeline.

10.15.2. File description

1. The first non-comment line must be exactly:

EnSight Vector Glyphs

2. The second line must be the version number, like:

Currently the only valid version is 1.0

Version 1.0

3. The third line must be the number of Vector Glyphs in the file, like:

where int is the number of vector glyphs

NumVectorGlyphs: int

4. The fourth line should be the number of Transient timelines in the file, if any. The line should look like:

where int is the number of vector glyph timelines.

(If all vector glyphs are static, the line is not needed, or should indicate that the number is 0).

NumTimeLines: int

5. Each vector glyph will start with a line containing the single capitalized word, VECTOR .

Under each VECTOR section, several lines are needed/possible:

VECTOR

This is a required 2 token line, where int is an id number.


Note:  This must be the first line of the section.


id: int

This is a required 2 (or more) token line.

description: string

This is a required 2 token line. constant must be FORCE or MOMENT

type: constant 

This is a required 2 token line. constant must be STATIC or TRANSIENT

 time_condition: constant

This is required if TRANSIENT time_condition. It is a 2 token line. int will be the id of the associated timeline.


Note:  The time_line must be specified after the time_condition, and before any xyzloc or values lines)


 time_line: int 

This is a required 2 token line. int is the associated part number

part: int 

Use this 2 token line if attaching to a node id. int is the node id to use.

 nidloc: int 

Use this 2 token line if attaching to an element id. int is the element id to use.

eidloc: int 

Use this 4 token line(s) if specifying an xyz location to act at. The three floats are the x,y,z locs. (There must be one of these lines for each time. Thus, for a STATIC glyph there will be just one line, but for a TRANSIENT glyph, there will be multiple - namely the numtimes of the associated timeline.)

 xyzloc: float float float 

Note:  One of the three location methods must be specified.


This is a required 4 token line(s). The three floats are the x,y,z components of the vector. (There must be one of these lines for each time. Thus, for a STATIC glyph there will be just one line, but for a TRANSIENT glyph, there will be multiple - namely the numtimes of the associated timeline.)

values: float float float

6. Each vector glyph timeline (if any) will start with a line containing the single capitalized word, TIMELINE .

Under each TIMELINE section, several lines are needed/possible:.

TIMELINE

This is a required 2 token line. int is an id number, and is the number that will be referenced by the VECTOR time_line


Note:  Must be the first line of the section.


id: int

This is a required 2 token line. int is the number of time steps in the timeline.


Note:  Must follow the id line, and precede the times line.


numtimes: int 

This is a required multi-token line. The floats are the time values. We must read in numtimes floats, however the number of these on a given line is somewhat arbitrary. Just make sure that you do not do more than 15 times per line.

times: float float ... 

This is an optional 2 token line. constant is UNDEF or NEAREST. This controls what will happen if EnSight specifies a time before the first time in this timeline. UNDEF will make the vector undefined. NEAREST will treat it as if it is at the first time.

before: constant  

This is an optional 2 token line. constant is NEAREST or INTERPOLATE. This controls what will happen if EnSight specifies a time between times in this timeline. NEAREST will cause the nearest time to be used. INTERPOLATE will interpolate between the bounding times.

amidst: constant 

This is an optional 2 token line. constant is UNDEF or NEAREST. This controls what will happen if EnSight specifies a time after the last time in this timeline. UNDEF will make the vector undefined. NEAREST will treat it as if it is at the last time.

after: constant 

Note:  The defaults for before, amidst, and after are:

before: UNDEF

amidst: INTERPOLATE

after: UNDEF

10.15.3. Example

The following fictitious example shows a few variations for 4 vector glyphs, 2 static and 2 transient. Three are FORCE vectors, and one is a MOMENT vector. You will note that one vector is located with a node id, one with an element id, and 2 with xyz locations.

We used some blank lines and some lines starting with #, for comments.

Note the use of the appropriate number of xyzloc and/or values lines.

Note that for the example, we did the TIMELINES times lines differently. The first TIMELINE put all times on the same line - which we can easily do without violating the 15 token limit because there are only 4 times. The second TIMELINE put each time on its own times line.

In this case we did not re-use the transient timelines, but we easily could have more than one vector glyph reference the same timeline.

EnSight Vector Glyphs
Version 1.0
#--------------------
NumVectorGlyphs: 4
NumTimeLines: 2
#--------------------
VECTOR
id: 1
description: dead load
type: FORCE
time_condition: STATIC
part: 1
nidloc: 173
values: 0.5 1.0 0.75

VECTOR
id: 2
description: wind load
type: FORCE
time_condition: TRANSIENT
time_line: 1
part: 1
eidloc: 13
values: 1.0 2.0 0.0
values: 0.0 2.0 1.0
values: 0.5 7.0 3.0
values: 2.0 5.0 8.0

VECTOR
id: 4
description: snow load
type: FORCE
time_condition: STATIC
part: 1
xyzloc: 1.5 1.5 1.0
values: 0.0 0.0 -5.25

VECTOR
id: 5
description: wrench
type: MOMENT
time_condition: TRANSIENT
time_line: 3
part: 72
xyzloc: 1.0 1.0 0.0
xyzloc: 1.1 1.8 0.2
xyzloc: 1.2 1.7 0.5
values: 10.0 15.0 2.0
values: 20.0 30.0 4.0
values: 100.0 150.0 20.0

#--------------------------

TIMELINE
id: 1
numtimes: 4
before: UNDEF
amidst: INTERPOLATE
after: NEAREST
times: 0.0 1.0 2.0 3.0

TIMELINE
id: 3
numtimes: 3
before: NEAREST
amidst: INTERPOLATE
after: UNDEF
times: 0.5
times: 1.5
times: 2.5