Path Command

From OSUPDOCS
Jump to navigation Jump to search

The Path and Paths commands are used in FEA analyses to define paths that are used to define areas when generating a mesh.

Scripted Paths

In scripted files, the Path command has two forms.

Path Command

The first form is to define a new path:

Path (id),(intervals),<(ratio)>
  Keypoint "start",0,5
  Keypoint "middle",5,10
  Keypoints "end"
EndPath

where

  • (id) is the id to give to the new path. The id must be unique among all other paths.
  • (intervals) is the number of intervals along the path. When the path is used to mesh an area, it is the number of elements along that path.
  • Optional (ratio) defines the ratio of the first element size to the last element size and can be used to define unequal element sizes. Alternatively, (ratio> can be negative to specify the absolute size of the first element (in length units) to be |(ratio>|. If not specified, the default value is 1 which gives equally sized elements.

Within the Path block, there are a series of Keypoint and Keypoints commands that define new keypoints (e.g. key point "start") or refer to previously defined key points (e.g. key point "end" without specified coordinates). The keypoints are connected to define the path. Currently the path definition can only have two or three key points. Two key points define a line and three define an arc.

Paths Command

A path can be used in more than one area. The first time it is used it is defined as above. For all subsequent uses, however, it is reused by giving just the id. Thus, the second form of the Path command is to refer to a previous key point using the Paths command:

Paths (id1),<(id2)>,...

where there is no matching EndPath command and (id1) ((id2), ...) refer to the ids of previously defined paths. When more than one id is used they refer to consecutive paths in the current area.

XML Path Command

After the <Keypoints> block in the single <Mesh> element, all paths used by the mesh should be defined in a series of <Path> blocks that link the key points into lines or arcs and define mesh information along those paths. The basic format is:

  <Path id="bottom" intervals='6' ratio='1'>
    <keypt id='start'/>
    <keypt id='middle'/>
    <keypt id='end'/>
  </Path>

Subordinate to each <Path> command are <keypt> commands that list the key points that define the path. Use two key points to define a line or three key points to define an arc. The key points are selected by their id. The attributes for a <Path> command are:

  • id: An id for the path. The id's can be text or numbers and must be unique among all paths.
  • intervals: Number of elements along this path when it is meshed into an area.
  • ratio: Ratio of the size of the first element along the path to the last one. If ratio<0, then the absolute size of the first element on the path with be |ratio|. The default is 1.0 which gives equally sized elements.

Notes

  1. A scripted Path command to define a path can appear by itself or within an area block. A Paths command that refers to existing paths is only allowed within an area block.
  2. To programmatically access path propertie in scripted files, you can use the "at" expression @path.ID.prop where "ID" is the defined path id and the possible properties for prop are:
    • intervals - number of intervals along the path
    • ratio - ratio of first to last element size
    • first - id of the first key point
    • middle - id of the middle key point (or empty string is the path does not have a middle key point).
    • last - id of the last key point