This module contains NamedSelectionsDict, NamedSelectionsIterator and NamedSelection classes.

class ansys.dpf.post.named_selection.NamedSelections(mesh: Mesh)#

Dictionary of available named selections for a given mesh.

keys()#

Returns the available named selections.

Return type:

List[str]

get(k[, d]) D[k] if k in D, else d.  d defaults to None.#
items() a set-like object providing a view on D's items#
values() an object providing a view on D's values#
class ansys.dpf.post.named_selection.NamedSelection(name: str, node_ids: List[int] | None = None, element_ids: List[int] | None = None, face_ids: List[int] | None = None, cell_ids: List[int] | None = None, scoping: Scoping | None = None)#

Named Selection class associating a name to a list of mesh entities.

property name: str#

Returns the name.

set_id(index: int, scopingid: int)#

Sets the ID of the underlying scoping’s index.

id(index: int)#

Retrieve the ID at a given index.

Return type:

int

index(id: int)#

Retrieve the index of a given ID.

Return type:

int

property ids: DPFArray | List[int]#

Retrieve a list of IDs in the underlying scoping.

property location: str#

Location of the IDs as a string.

property size: int#

Length of the list of IDs.