-
-
May 2, 2022 at 10:33 am
teaxdriv
SubscriberHello,
I would like to ask you how to export nodal displacements from Worbench?
Best regards
Michal
May 3, 2022 at 10:29 amMay 3, 2022 at 11:04 amteaxdriv
SubscriberHello peteroznewman thank you very much for your reply! I know this, but I search for automated way of export using APDL or Python script. The results should look like: Node ID X coord Y coord Z coord UX UY UZ USUM.
Best regards
Michal
May 3, 2022 at 12:03 pmErKo
Ansys EmployeeHi Michal
Yes it is possible to export using apdl or act or python results (dpf), but it is something you would need to script your self.
Search the forum and the internet and you should find plenty of information
(The function to search for in the ACT/API guide/help manual for in order to get nodal displacements is GetNodeValues)
Also dpf results and dpf scripting can do this.
All the best
Erik
May 3, 2022 at 12:46 pmteaxdriv
SubscriberHello ekostson thank you for your advice! I have searched the internet many time, and on top of that, I am using currently the script from the topic which you sent, but I have a problem with implementation of nodal coordinate x y z. I am still getting incorrect results, so I ask for help here.
BR
Michal
May 3, 2022 at 1:06 pmErKo
Ansys EmployeeHi Michal
If you can explain which approach you are using, and also attach the actual script used (inline as text in your next post) ? Finally what is the issue with it, then perhaps someone can be of help and offer some feedback.
Erik
May 3, 2022 at 1:29 pmteaxdriv
SubscriberHello Erik for example if we use APDL script I am not sure how to modify it to export along with UX,UY,UZ,USUM also nodal coordinate and Node ID?
/post1
set,last cmsel,s,!select Named Selection scoped nodes
*get,nmx,node,,num,max
*dim,ndat,array,nmx,4
*vget,ndat(1,1),node,1,nsel
*vmask,ndat(1,1)
*vfill,ndat(1,1),ramp,1,1 ! store node number
*vmask,ndat(1,1)
*vget,ndat(1,2),node,1,u,x
*vmask,ndat(1,1)
*vget,ndat(1,3),node,1,u,y
*vmask,ndat(1,1)
*vget,ndat(1,4),node,1,u,z
*vmask,ndat(1,1)
*cfopen,vwr,csv
*vwrite,ndat(1,1),ndat(1,2),ndat(1,3),ndat(1,4) (f8.0,3(',',g16.9))
*cfclose
May 3, 2022 at 1:51 pmErKo
Ansys EmployeeHi
Look on the *vget command and the node section (LOC ) which will show how to get the location.
(e.g., *vget,ndat(1,5),node,1,loc,x ---- gets the x loc and so on and so forth)
As for the node numbers they are given by ndat(1,1) so the first column in the text file.
for guidance on apdl and look in the help manual (*vget, and all other commands).
All the best
May 5, 2022 at 10:04 amteaxdriv
SubscriberHello ekostson Thank you very much. This works, but also I would like to ask you for setting of format like in the attached text file with the names of columns Node ID X CoordY CoordZ CoordXYZMagnitude. The columns have fixed width of 26.
Can you help me with it?
Best regards
Michal
Viewing 8 reply threads- The topic ‘Export of nodal displacements from Workbench to txt file’ is closed to new replies.
Innovation SpaceTrending discussionsTop Contributors-
5849
-
1906
-
1420
-
1305
-
1021
Top Rated Tags© 2026 Copyright ANSYS, Inc. All rights reserved.
Ansys does not support the usage of unauthorized Ansys software. Please visit www.ansys.com to obtain an official distribution.
-
Ansys Assistant will be unavailable on the Learning Forum starting January 30. An upgraded version is coming soon. We apologize for any inconvenience and appreciate your patience. Stay tuned for updates.
