Closed kmahajan-cadfem closed 1 year ago
Hello @kmahajan-cadfem,
The issue here is that in the script you provided, you do indeed create a displacement operator disp_op
, to which you connect your nodal scoping of 100 nodes, however when requesting to evaluate results, using model.results.displacement
means you are instantiating another displacement operator, operator to which the nodal scoping is not connected.
What you can thus do is give the nodal scoping to the model.results.displacement
command:
import ansys.dpf.core as dpf
from ansys.dpf.core import examples
model = dpf.Model(examples.download_crankshaft())
nodal_scoping = dpf.mesh_scoping_factory.nodal_scoping(list(range(100, 200)))
disp_fc = model.results.displacement.on_last_time_freq.on_mesh_scoping(nodal_scoping).eval()
last_time_step_disp = disp_fc.get_field(0)
print(last_time_step_disp)
Let me know if you have any further questions.
@PProfizi, Indeed. I am sorry, I overlooked that line :-(. Thanks for spotting it
I will then close the issue if ok with you. You can reopen it if further information is required.
Before submitting the issue
Description of the bug
Steps To Reproduce
use following code
server version is
6.0
dpf version is0.8.1
Which Operating System are you using?
Windows
Which DPF/Ansys version are you using?
DPF Server as standalone
Which Python version are you using?
3.7
Installed packages