[Gate-users] Rotation of Daughter Volume inside rotated mother volume

Etienne Auger Etienne.Auger at USherbrooke.ca
Tue Dec 17 16:40:23 CET 2019


Hello Tom,

First of all, your two assumptions are correct I think.

So both the WaterCylinder and the TungstenWire start along the z axis before any rotations are applied to any of them. Now, as you said, the daughter (TungstenWire) is rotated alone before its mother (WaterCylinder) gets also rotated, but with its daughters following the same rotation (mother and daughters move together).

Basically, the TungstenWire (parallel to the z axis at the beginning) has to rotate 0 deg around x axis, 90 deg around y axis and 23 deg around z axis. So now, it is parallel to the x-y plane and has an angle of 23 deg with respect to the x axis.

Finally, when the WaterCylinder gets rotated of 90 deg around its y axis, the Tungsten Wire follows and becomes parallel to the y-z plane, and everything is oriented as you wished, I think.

So I've redone the calculations for the rotation (axis and angle) that the TungstenWire has to do before being rotated with the WaterCylinder, and I get these values:

/gate/TungstenWire/placement/setRotationAxis -0.3907  1.921  0.3907
/gate/TungstenWire/placement/setRotationAngle 92.28 deg

As you can see, we have the same angle value, but the axis values I get are two times yours, plus the sign is opposite. It is hard to tell where your calculations went wrong, but rotations are always tricky to conceptualize I find.

Therefore, I have attached the small python script (.txt extension because Outlook would not let me send a .py) that I used to generate these values, so you can see for yourself what I did, and maybe reuse it later.

Do not hesitate if you have any questions,

√Čtienne


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opengatecollaboration.org/pipermail/gate-users/attachments/20191217/3b1191a5/attachment.html>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: rotation.txt
URL: <http://lists.opengatecollaboration.org/pipermail/gate-users/attachments/20191217/3b1191a5/attachment.txt>


More information about the Gate-users mailing list