Python API to assign LCS to a node

Sudhir_Ingstron
Altair Community Member
I have a local coordinate system in my model, and I need to assign this system as the displacement coordinate system to a node. Please help with the Python API for this.
Thank you
Sudhir
0
Best Answer
-
using the new Python Recorder in 2025.0 i got this:
import hm
import hm.entities as entdef run():
from hm.mdi import apis
model = apis.HmModelDebug()model.setreviewtransparentmode(mode=0)
collection = hm.Collection(model, hm.FilterByEnumeration(ent.Node, ids=[2, 4]))
system_entity = ent.System(model, 2)
# [TIP]: systemsetanalysis is deprecated.
model.systemsetanalysis(collection=collection, system_entity=system_entity)
model.setreviewtransparentmode(mode=1)
model.setreviewtransparentmode(mode=0)0
Answers
-
using the new Python Recorder in 2025.0 i got this:
import hm
import hm.entities as entdef run():
from hm.mdi import apis
model = apis.HmModelDebug()model.setreviewtransparentmode(mode=0)
collection = hm.Collection(model, hm.FilterByEnumeration(ent.Node, ids=[2, 4]))
system_entity = ent.System(model, 2)
# [TIP]: systemsetanalysis is deprecated.
model.systemsetanalysis(collection=collection, system_entity=system_entity)
model.setreviewtransparentmode(mode=1)
model.setreviewtransparentmode(mode=0)0 -
Thank you for your response, Adriano.
0