Guys, how to select HEXA elements by face. I can do it by menu, but how can I select these elements and add them to set using tcl script? Thank you!
Hi, Vladimir_Gantovnik,
Currently, we don´t support this selection method via API (python and tcl) for 3D elements, just for 2D
import hm import hm.entities as ent
model = hm.Model()
source_col = hm.CollectionByInteractiveSelection(model, ent.Element)
face_col = hm.CollectionByFace(model, source_col)
print(len(face_col)) Could not be the best approach, but as a workaround, you can request this selection as a *createmarkpanel https://help.altair.com/hwdesktop/hwd/topics/reference/hm/_createmarkpanel2.htm?zoom_highlight=*createmarkpanel
Regards,
Arthur
Thank you, Arthur! Of course, I want to select faces/elements by surfaces, put them in sets and use these sets in CZM contact without manual selection using *createmarkpanel but completely automatically. Thank you for the example script, I will use in some other applications.