[Insight-users] RE: Versor components

Andrew Li andrew.li at synarc.com
Fri May 12 15:28:49 EDT 2006


Hi, Luis:

I would like to share what I have learnt with other ITK users.

ITK versor decomposition {Rx, Ry, Rz} of a (3D) rotation matrix R can be
calculated easily in the following way:

	typedef itk::VersorRigid3DTransform< double  > TransformType;
	...
	TransformType::Pointer transform = TransformType::New();
	
	transform->SetMatrix (R);

	double Rx = transform->GetParameters()[0];	
	double Ry = transform->GetParameters()[1];	
	double Rz = transform->GetParameters()[2];	


Thanks.

-Andrew

> -----Original Message-----
> From: Luis Ibanez [mailto:luis.ibanez at kitware.com]
> Sent: Tuesday, May 09, 2006 12:32 PM
> To: Andrew Li
> Cc: Insight Users
> Subject: Re: Versor components
> 
> 
> Hi Andrew,
> 
> Yes, the Versor is intended to represent a rotation in 3D space.
> 
> Currently only some of the rigid transform provide a GetVersor()
> method. Those are the transforms that actually use a Versor internally
> in order to represent the rotation.
> 
> An example on how to get the rotational component out of a rotaion
> matrix is presented in file
> 
>         Insight/
>           Examples/
>               Registration/
>                   ImageRegistration9.cxx
> 
> 
> in lines 117-125.
> 
> 
> Note that if you know the rotations around specific axes, you
> could use Versor composition in order to get the Versor equivalent
> to the sequence of rotations.
> 
> You just need to be careful with the order in which the rotations
> are applied, since Versor composition is not commutative.
> 
> 
>     Regards,
> 
> 
>         Luis
> 
> 
> 
> ===============
> Andrew Li wrote:
> > Hi, Luis:
> >
> > I assume that any strictly-rotational transform (in 3D space) can be
> > uniquely specified by a versor component set {Rx, Ry, Rz}. Is it
> > correct?
> >
> > If it is the case, does ITK lib support this decomposition? Like:
> > 	Transform->GetVersorComponents()
> > Provided that the transform is orthonormal and its determinant= 1;
> >
> > If it has not been implemented yet, do you know the formula?
> > In fact, what I am interested is a special case:
> >
> > 	we know M = RzRyRx,
> > 	what is inv(M) = ?
> >
> > Thank you very much for your help!
> >
> >
> > -Andrew
> >
>
 
--------------------------------------------------------

This email message is for the sole use of the intended recipient(s) and may contain confidential and privileged information.Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message. If you are the intended recipient, please be advised that the content of this message is subject to access, review and disclosure by the sender's Email System Administrator.
--------------------------------------------------------


More information about the Insight-users mailing list