distance between two nodes
distance between two nodesPosted by paco_espinola at April 22. 2007
How can I get the distance between two nodes?
I am using salome 3.2.1
Re: distance between two nodesPosted by paco_espinola at April 25. 2007I realize that is not possible to get the distance between two nodes. So I am using a awk script to calculate that distance. But still is not a elegant solution. I want to calculate inside salome. But I am new in python. I am trying to access the node coordinates following the weida's script but in the python console when I write something like this import smesh pequeno=small.GetMesh() I got the following error Traceback (most recent call last): File "<input/>", line 1, in ? NameError: name 'small' is not defined. My mesh in the left window has the name small. So what is the problem? Thank you in advance.
Re: distance between two nodesPosted by Grigory Zhivotovsky at April 25. 2007
You can write in the python console the following commands
study = salome.myStudyManager.GetStudyByName("Study1"
theSObj = study.FindObject("small"
MObject = theSObj.GetObject()
Sure "Study1", "small", 1, 48 can be replaced by any relevant values. Or write function to use these values as arguments if you plan to use it often.