[chimerax-users] A question about model position matrix

Elaine Meng meng at cgl.ucsf.edu
Thu Mar 31 09:40:27 PDT 2022


Hi Zheng,
My mistake, instead of "center #1" I should have said "center 0,0,0" ... try that:

turn z 90 models #1 center 0,0,0

Then the translation should be all zero.
Best,
Elaine
-----
Elaine C. Meng, Ph.D.
UCSF Chimera(X) team
Department of Pharmaceutical Chemistry
University of California, San Francisco

> On Mar 31, 2022, at 9:30 AM, Zheng Ruan via ChimeraX-users <chimerax-users at cgl.ucsf.edu> wrote:
> 
> Hi Elaine,
> 
> Thank you for the reply. However, I don't see a large translation of my map after I type the "turn" command. I only have one map loaded in ChimeraX and the map is rotated about its own z-axis.
> 
> I also tried to specify the "center" option as suggested, but I still see a large translation value. For example,
> 
> open volume.mrc format mrc
> 
> view matrix
> camera position: 1,0,0,345.63,0,1,0,343.7,0,0,1,1042.6
> model positions: #1,1,0,0,0,0,1,0,0,0,0,1,0,#1.1,1,0,0,0,0,1,0,0,0,0,1,0
> 
> turn z 90 models #1 center #1
> 
> view matrix
> camera position: 1,0,0,345.63,0,1,0,343.7,0,0,1,1042.6
> model positions: #1,1.1102e-16,-1,0,689.33,1,1.1102e-16,0,-1.9358,0,0,1,0,#1.1,1,0,0,0,0,1,0,0,0,0,1,0
> 
> I also tried to change the center of rotation, but the result remains the same.
> 
> Best,
> Zheng
> 
> 
> On Thu, Mar 31, 2022 at 11:20 AM Elaine Meng <meng at cgl.ucsf.edu> wrote:
> Dear Zheng,
> I believe it is because the center of rotation from your command is not the same as the center of the model.  If the center of rotation is far from the model, it might be translated a large distance in addition to being rotated.  You can specify the center of rotation for the "turn" command with the "center" option.  I believe that if you use
> 
> turn z 90 models #1 center #1
> 
> ...the translation of the model would then be zero or close to zero.
> 
> See help for "turn"
> <https://rbvi.ucsf.edu/chimerax/docs/user/commands/turn.html>
> 
> I hope this helps,
> Elaine
> -----
> Elaine C. Meng, Ph.D.                       
> UCSF Chimera(X) team
> Department of Pharmaceutical Chemistry
> University of California, San Francisco
> 
> 
> > On Mar 30, 2022, at 8:18 PM, Zheng Ruan via ChimeraX-users <chimerax-users at cgl.ucsf.edu> wrote:
> > 
> > Dear ChimeraX users,
> > 
> > I'm trying to understand the model position matrix. According to the documentation, "Each matrix is reported as 12 comma-separated numbers, corresponding to a 3x3 rotation matrix and a translation vector in the fourth column. Ordering is row-by-row, such that the translation vector is given as the fourth, eighth, and twelfth numbers."
> > 
> > When I load a model into ChimeraX and use "view matrix" command to check the model position, I got "#1,1,0,0,0,0,1,0,0,0,0,1,0,#1.1,1,0,0,0,0,1,0,0,0,0,1,0". The rotation matrix for #1 is an identity matrix with translation vector to be 0 for all directions.
> > 
> > However, if I rotate the model using the command "turn z 90 models #1" and then check the model position using "view matrix", I got something like "#1,1.1102e-16,-1,0,689.33,1,1.1102e-16,0,-1.9358,0,0,1,0,#1.1,1,0,0,0,0,1,0,0,0,0,1,0". The translation vector for #1 becomes (689.33, -1.9358, 0).
> > 
> > Since I only applied a simple rotation of the model along z-axis, why the translation vector becomes non-zero in this case? I hope to have a better understanding of how ChimeraX handles the model position matrix to describe model positions.
> > 
> > Thank you so much!
> > Best,
> > Zheng
> 
> _______________________________________________
> ChimeraX-users mailing list
> ChimeraX-users at cgl.ucsf.edu
> Manage subscription:
> https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users




More information about the ChimeraX-users mailing list