get_value

Mapdl.get_value(entity='', entnum='', item1='', it1num='', item2='', it2num='', **kwargs)

Runs the MAPDL GET command and returns a Python value.

This method uses Mapdl.get().

See the full MADPL command documentation at *GET

Note

This method is not available when within the Mapdl.non_interactive() context manager.

Parameters
entitystr

Entity keyword. Valid keywords are "NODE", "ELEM", "KP", "LINE", "AREA", "VOLU", "PDS", etc.

entnumstr, int, optional

The number or label for the entity. In some cases, a zero (or blank "") entnum represents all entities of the set.

item1str, optional

The name of a particular item for the given entity.

it1numstr, int, optional

The number (or label) for the specified Item1 (if any). Some Item1 labels do not require an IT1NUM value.

item2str, optional

A second set of item labels and numbers to further qualify the item for which data are to be retrieved. Most items do not require this level of information.

it2numstr, int, optional

The number (or label) for the specified item2 (if any). Some item2 labels do not require an it2num value.

Returns
float

Floating point value of the parameter.

Examples

Retrieve the number of nodes.

>>> value = ansys.get_value('node', '', 'count')
>>> value
3003

Retrieve the number of nodes using keywords.

>>> value = ansys.get_value(entity='node', item1='count')
>>> value
3003