-
Dear all, I'm quite new using python, I have a large model of a building. I'm able to plot displacements through the following piece of code: result = mapdl.result
result.plot_nodal_displacement(0,'UZ') However, as it is a large building I'm only interested in some parts of it... when I try to do through a previous selection as: mapdl.nsle('s','node',vmin=14807,vmax=28010)
mapdl.esel('S','elem',vmin=15596,vmax=28627) the plotting is still for the whole building, I'm doing something wrong? is there that capability using mapdl? I've tried the following code (selected_nodes) result = mapdl.result
mask = mapdl.post_processing.selected_nodes.nonzero()[0]+1
result.plot_nodal_displacement(0,'UZ')_ and this version result = mapdl.result
mask = mapdl.post_processing.selected_nodes
result.plot_nodal_displacement(0,'UZ') but neither of them work at all. Thank you for your help, david |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
Hi @peluho Unfortunately, PyMAPDL at the moments only support plotting of the full entity (nodes, or elements) sets. I will plan accordingly to have that feature implemented in the future. Thank you for bringing this up and sorry about the trouble! |
Beta Was this translation helpful? Give feedback.
-
Hi @peluho & @germa89 Peluho the "result" method is using the PyMAPDL Reader which is a stand-alone program. That is also included in PyMAPDL. It is meant to be used outside of MAPDL so it does not respect MAPDL commands...since it is stand alone. Please see the following PyMAPDL example model that shows how to post process part of a model using the "post_processing" method: If you want to stick with the Reader then you can create Components in the MAPDL model prior to solving and those components will be included as definitions in the result file. You can then use those components with the result plotting command: That "result" command can be found about 2/3rd of the was down this documentation page: Mike |
Beta Was this translation helpful? Give feedback.
Hi @peluho
Unfortunately, PyMAPDL at the moments only support plotting of the full entity (nodes, or elements) sets.
I will plan accordingly to have that feature implemented in the future.
Thank you for bringing this up and sorry about the trouble!