Re: [Yade-users] [Question #706506]: How to output volumetric strain (micro strain field) in vtk file
Question #706506 on Yade changed: https://answers.launchpad.net/yade/+question/706506 Status: Answered => Solved Leonard confirmed that the question is solved: Thanks Karol Brzezinski, that solved my question. -- You received this question notification because your team yade-users is an answer contact for Yade. ___ Mailing list: https://launchpad.net/~yade-users Post to : yade-users@lists.launchpad.net Unsubscribe : https://launchpad.net/~yade-users More help : https://help.launchpad.net/ListHelp
Re: [Yade-users] [Question #706506]: How to output volumetric strain (micro strain field) in vtk file
Question #706506 on Yade changed: https://answers.launchpad.net/yade/+question/706506 Status: Open => Answered Karol Brzezinski proposed the following answer: Hi, MWE would be appreciated [1]. Using the' calculator filter', you can always compute anything in ParaView from matrix components. Load the VTK file, and then use the calculator filter. You can type the formula: "Strain_matrix_0"+"Strain_matrix_4"+"Strain_matrix_8" or select other components using the "Scalar" button. Next, you can visualize the 'Result'. The MWE that I used to generate the file is as follows: centers = [] for x in range(2): for y in range(2): for z in range(2): centers.append((x,y,z)) O.bodies.append([ sphere(center=center,radius=1,) for center in centers ]) sp = SpherePack() sp.fromSimulation() TW=TesselationWrapper() TW.triangulate() TW.computeVolumes() TW.setState(0) shiftBodies([4,5,6,7],(1,0,0)) # move spheres without engines (I am just being lazy) shiftBodies([2,3,6,7],(0,1,0)) shiftBodies([1,3,5,7],(0,0,1)) TW.setState(1) TW.defToVtk("strain.vtk") ### Cheers, Karol [1]https://www.yade-dem.org/wiki/Howtoask -- You received this question notification because your team yade-users is an answer contact for Yade. ___ Mailing list: https://launchpad.net/~yade-users Post to : yade-users@lists.launchpad.net Unsubscribe : https://launchpad.net/~yade-users More help : https://help.launchpad.net/ListHelp
[Yade-users] [Question #706506]: How to output volumetric strain (micro strain field) in vtk file
New question #706506 on Yade: https://answers.launchpad.net/yade/+question/706506 Hi, Referring to [1], we can use defToVtkFromPositions() to write a vtk file to visualise the deviatoric strain filed in paraview. For example: defToVtkFromPositions(position1.txt,position2.txt,"output_deviatoricStrain.vtk"). In this vtk file, it can show: solid color, strain_deviator and strain_matrix. It seems that no volumetric strain field from this vtk file. I would like to ask how to write a vtk file to visualise the volumetric strain field. Thanks. Leonard [1]https://yade-dev.gitlab.io/trunk/yade.wrapper.html?highlight=deftovtkfrompositions#yade.wrapper.TesselationWrapper.defToVtkFromPositions -- You received this question notification because your team yade-users is an answer contact for Yade. ___ Mailing list: https://launchpad.net/~yade-users Post to : yade-users@lists.launchpad.net Unsubscribe : https://launchpad.net/~yade-users More help : https://help.launchpad.net/ListHelp