Re: A89: Re: 3D rotation of plots
[Prev][Next][Index][Thread]
Re: A89: Re: 3D rotation of plots
>around x-axis:
>x'=1*x + 0*y + 0*z
>y'=0*x + cosT*y + sinT*z
>z'=0*x + -sinT*y + cosT*z
>
>around y-axis:
>x'=cosT*x + 0*y + sinT*z
>y'=0*x + 1*y + 0*z
>z'=-sinT*x + 0*y + cosT*z
>
>around z-axis:
>x'=cosT*x + sinT*y + 0*z
>y'=-sinT*x + cosT*y + 0*z
>z'=0*x + 0*y + 1*z
To rotate around two or more axes just apply the rotation to a set of rotated
points. If you did the rotations in one equation, it would be large. If you
wanted to make an equation to do so, define a function on the calc as the
rotation and do a combination of functions to get the final points
For Example
define yx(x,z,t)=cos(t)x+sin(t)z // rotation of x part around y t°
and
zx(x,y,t)=cos(t)x+sin(t)y // rotation of x around z t°
and so on
now, to see the equation for x with a rotation of t1° around y and t2° around
z type in
zx(yx(x,z,t1),y,t2)
Matt Ross