How to visualize displacement feild

Asked by weijy on 2017-02-23

Hi all,

I tried to visualize the displacement field between two stages in triaxial test. It might be achieved by showing arrows starting from the position of a sphere at stage 1, ending at its position at stage 2. It would be better if different colors could be applied on each arrow to indicate the quantity of the displacement vector. Wondering if anyone can offer a smart method, thanks!

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Jan Stránský
Solved:
2017-02-24
Last query:
2017-02-24
Last reply:
2017-02-23
Best Jan Stránský (honzik) said : #1

Hello,

e.g. using export.VTKExporter + Paraview:
vtk = export.VTKExporter(...)
vtk.exportSpheres(useRef=True,what=[('dspl','b.state.displ()')])

In paraview:
Glyph, Glyph Type = Arrow, Vectors = dspl, Scale Mode = vector, Scale
Factor = 1
colored by "GlyphVector"

I got arrows from original to current positions, colored according to arrow
length.

cheers
Jan

weijy (weijy) said : #2

Thank you Jan, that is very helpful. But may I ask how to define the refPos?

weijy (weijy) said : #3

Thanks Jan Stránský, that solved my question.

Jan Stránský (honzik) said : #4

refPos is set when the body is created (refPos=pos)

in case, you can assign it arbitrary value if wanted/needed:
b.state.refPos=whatever

cheers
Jan

2017-02-24 14:48 GMT+01:00 weijy <email address hidden>:

> Question #478212 on Yade changed:
> https://answers.launchpad.net/yade/+question/478212
>
> Status: Open => Solved
>
> weijy confirmed that the question is solved:
> Thanks Jan Stránský, 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 : <email address hidden>
> Unsubscribe : https://launchpad.net/~yade-users
> More help : https://help.launchpad.net/ListHelp
>