yade-users team mailing list archive
Mailing list archive
[Question #681160]: How to change the refPos of spheres to current position of consolidation stage, and not particle generation stage, to extract vtk files for plotting of displacement field in Paraview
New question #681160 on Yade:
This question is a continuation from  which I had asked a few days before, as I face new problem when I try to plot the displacement field of particles in Paraview (from my direct shear test simulation in Yade).
This time, I'm planning to extract vtk files (to plot particle displacement field later in Paraview) from my direct shear test simulation which had around 200K - 400K particles. The true height of my shear box to be simulated should be only 27mm, but because I need to generate so many particles using "makeCloud" command, I had to increase the height of shear box to 3 times during particle generation stage, to allow for particles to generate and fall down by gravity to the bottom of shear box. I adjust the height of shear box back to 27mm later during consolidation stage.
So the sequence of my direct shear test simulation is like this:
1) Run 1st script for particle generation
2) Save state for particle generation
3)Run 2nd script > load particle generation saved state > consolidation process> shearing process
+ Extract vtk files for particle displacement from consolidation process to shearing process
***My problem is when I plot the displacement field vector plot in ParaView, I notice all my arrows actually start from 3 times of my true shear box height (i.e. 3 x 27mm = 81mm), and the arrows becomes very big with scale factor 1 (recommended value from ). I understand that this is because the refPos of particles is when they are being generated, that's why my displacement field looks like this.
***However, this is not what I intended. My goal is to plot displacement field for particle only during consolidation stage and shearing stage, and I guess the refPos of sphere should be the position during consolidation stage, and not particle generation stage. From , the comment did mention we can just change the refPos of spheres to the value we intended, so in my 2nd script, I use following commands to extract vtk files as follow:
b.state.refPos= b.state.pos # to change the refPos of spheres from particle generation stage to current position of consolidation stage
However, even after I change try to change the refPos of spheres to that of consolidation stage, it doesn't seem to work, because when I plot my displacement field in Paraview, the arrows still start at 3 times shear box height.
I hope someone can give me some suggestion on how to tackle this problem of mine.
Thank you and Regards,
You received this question notification because your team yade-users is
an answer contact for Yade.