Errors about rigid body rotation

62 views
Skip to first unread message

Yulin Luo

unread,
Sep 2, 2021, 8:14:46 AM9/2/21
to hoomd-users
Hi , Dear HOMMD-blue users,.
I am trying to use   hoomd.group.rigid() to simulate my systems, As you suggested,  I translate the constituent particles so that they are centered on the rigid center. 

As you can see from the test.gif,  these five rigid bodies only move in translation, but do not rotate. I don't know why?
In addition, the orientations of these five rigid bodies are the same, but they are different  in my initialization xml file(you can see it in xml_png). It's so weird.


My script is in attachment "new.py".

Could you please help me with this issue? Thanks in advance.


new.py
test.gif
xml.png

Joshua Anderson

unread,
Sep 7, 2021, 3:37:09 PM9/7/21
to hoomd...@googlegroups.com
Yulin,

The orientation of each rigid body is set by the central particle's "orientation" attribute. The positions of constituent particles (if they exist) will be overwritten. You set the to [1,1,1,1] in your script which is why all bodies have the same orientation in your image.

Note that [1,1,1,1] is not a valid rotation quaternion. That may or may not explain why your bodies do not rotate.
------
Joshua A. Anderson, Ph.D.
Research Area Specialist, Chemical Engineering, University of Michigan
> --
> You received this message because you are subscribed to the Google Groups "hoomd-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to hoomd-users...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/hoomd-users/7f7b58f8-3b05-49f0-94aa-339e45d3dbd9n%40googlegroups.com.
> <new.py><test.gif><xml.png>

Reply all
Reply to author
Forward
0 new messages