Jmol/Quaternions
From Proteopedia
(Difference between revisions)
(New page: ==Examples== <StructureSection load='2bna' size='340' side='right' caption='Caption for this structure' scene=''> http://proteopedia.org/wiki/images/7/76/Wobble.spt {{Image:Wobble.spt}} ...) |
|||
Line 4: | Line 4: | ||
http://proteopedia.org/wiki/images/7/76/Wobble.spt | http://proteopedia.org/wiki/images/7/76/Wobble.spt | ||
{{Image:Wobble.spt}} | {{Image:Wobble.spt}} | ||
+ | <jmol><jmolButton><script>script "http://proteopedia.org/wiki/images/7/76/Wobble.spt"</script> | ||
+ | <text>constant speed reset (4 sec for max rotation, but at least 0.1 sec)</text></jmolButton></jmol> | ||
- | == | + | |
+ | <jmol><jmolButton><script>q1 = {0 0 0 1};q2 = quaternion();theta = 2 * acos(q2.w);d = theta / 45 + 0.1;moveto @d quaternion @q1; </script> | ||
+ | <text>constant speed reset (4 sec for max rotation, but at least 0.1 sec)</text></jmolButton></jmol> | ||
+ | |||
+ | |||
+ | ==Preliminaries== | ||
+ | A quaternion is an mathematical object (like a matrix or a complex number) with four parameters x y z w. It is useful to express orientations and rotations, and to do calculations (combining, interpolating, dissecting) on them. Jmol shows structures (e.g. atom positions) on a display and allows the view to be rotated and individual atomic positions to be manipulated. | ||
==Combining two rotations== | ==Combining two rotations== | ||
Line 14: | Line 22: | ||
</StructureSection> | </StructureSection> | ||
- | == | + | ==Resources== |
- | + | http://sacredsoftware.net/tutorials/quaternion.html |
Revision as of 18:25, 24 July 2019
Examples
|