## graph

   'graph'  [<amplitude|*chars*> 'amp']|
[<material|*chars*> 'mat']|
[<set|seq> 'length' ['+'|'-']]|
[<set>|'-p' 'nr'|'time'|'descr'|<parameter-name> ->
[<Dataset-name> <entity-name>|<parameter-name> ] ->
[<first-Dataset-Nr> <last-Dataset-Nr>]  ]

This keyword is used to create time history plots of nodal values. The values of the pre-selected nodes stored in the referenced set will be written to a file called ”graph_<nr>.out”. A gnuplot command file will be written called ”graph_<nr>.gnu” and executed. The resulting file ”graph_<nr>.ps” will be automatically displayed with the postscript viewer unless the user has used “asgn” to turn the presentation off (and the <nr> can be defined). The default viewer is ”ghostview” but this can be changed in the ”cgx.h” file before the program is build. See also “How to generate a time-history plot” for further details.

A set with the nodes of interest must be created (usually with “qadd”) before a graph can be drawn. If the parameter l (length) is used to plot values along the length of a set of nodes then this set should be of the sequence type (usually created with “qseq”):

graph seq length

The length is calculated as the sum of the distances between successive nodes. Un-ordered sets (as created with “qadd”) will be ordered in a way that the positive direction points away from the origin of the coordinate system. The direction can be chosen with a '+' or '-' sign following the 'length' parameter ('+' is default).

Instead using existing nodes it is possible to use a line or a combined line “lcmb” as a method to generate new locations for data-points. The current displayed results will be automatically mapped to this locations and shown in a 2D graph over the length of the line:

graph lineset length +

The set lineset stores a line. Since a '+' was given the graph starts at the beginning of the line. With a '-' it would start at the end of the line.

Since version 1.8, there are two ways of operation. One way is to specify the Datasets and the entity as parameters of the command

graph set time DISP D1

which will display the displacement D1 of nodes in ”set” vs. the dataset-time of all ”DISP” Datasets. The first and the last dataset can be specified optionally.

For the traditional way, a sequence of datasets must have been selected (see Toggle Dataset Sequence). After the selection of the datasets, an Entity must be specified. Then, the user could use the graph command to generate the history-plot of this pre-defined sequence. The command

graph set nr

will display the values on the node-positions vs. the dataset-numbers. The command

graph set time

will display the values on the node-positions vs. the dataset-values (usually time or frequency, see Nodal Results Block, parameter “VALUE”)) and the command

graph set descr

will display the values on the node-positions vs. the dataset-description (only makes sense if the description is a numerical value. See Nodal Results Block), parameter “TEXT”, for the location of this data in the frd-file.

In addition, a second data-file is written ”graph.out2” which stores the node-number and the node-coordinates and all values at this node-position for all datasets. This file can be used to display values over node-positions, etc. It is up to the user to generate a suitable plot out of this data.

The ”graph” files can be edited and combined. For example to plot one type of value vs. another type of value.

If an ccx- or Abaqus-input-file was read then it is also possible to create time history plots of the amplitudes (*AMPLITUDE in ccx) or the material-properties can be displayed (*MATERIAL in ccx):

graph amplitude-name amp

graph material-name mat

Wildcards (*) can be used to search for amplitudes or materials of a certain expression.

The parameters related to datasets can also be displayed with the graph command:

graph -p time DISP HID

This command plots the nodal-diameters used in a cyclic symmetry calculation over the dataset-value. Only few parameters are written from ccx in frd-format. Other applications might define its own parameters in frd-format (see Parameter Header Record for the format of a parameter record). If needed cgx can also create this dataset parameters, see the ”ds” command on how to do it.

The running number in the name of the written file is stored in the value !graph_Nr (the leading '!' prevents the value from beeing written by the send or save command). It can be used in a subsequent ”sys” command to change the filename.