[Insight-users] Euler3DTransform, Rotation Matrix & Initial Parameters (fwd)

Luis Ibanez luis . ibanez at kitware . com
Mon, 10 Nov 2003 22:45:03 -0500


Hi Anonymous User,


There is a family of RigidTransforms in ITK. Their ultimate
representation is a combiantion of a matrix M and a vector V.
They transform a point P into a point P' by applying the
equation

        P'  = M . P'   +   V

M is a 3x3 matrix with redundancy.
V is a 3 vector.

What make different all the transforms in the family is the
way in which the matrix M and the vector V are computed.

In the case of the Euler3D transform, this matrix is computed
from the specification of rotation angles around the three
coordinates axis.

In the case of the QuaternionRigidTransform, the rotation
is specified as a Quaterion (q0,q1,q2,q3).


The methods SetMatrix() and SetOffset are offered by the
base class of the family of RigidTransforms. This methods
*should not* be called by users because they will not
update the representation parameters used by the specific
transforms.

For example, if you call SetMatrix() in a QuaternionTransform,
that will update the internal representation of the matrix
but will no update the Quaternion representaiton.  Along the
same lines, if you call SetMatrix() in an Euler3DTransform,
that will update the matrix but not the euler angles.

What you should do is to use the natural representation of
your rotation in the terms of one of the RigidTransform
representation. That is, find the euler angles that represent
your rotation, or find the quaternion that represents your
rotation.

Then *Set()* those values using the methods like SetRotation( 
quaternion) (in the QuaternionTransform) or SetAngles() in the
Euler3DTransform. Once your transform is set, you can Get the
parameters from the transform and pass them to the registration
method using SetInitialTransformParameters().


I would strongly suggest you to use the QuaternionRigidTransform
instead of the Euler3DTransform. Quaternions (unit quaternions)
are the appropriate mathematical representation of rotations in
3D space.

Note also that the QuaternionRigidTransform has been enhanced
in the CVS version of ITK and now offers a SetCenter() method.
This center is fixed and does not get modified during the
search performed by the optimizer.


Please let us know if you have further questions.


Regards,


   Luis


--------------------------
Anonymous User wrote:
> Hello,
> 
> I am trying to initialise the Euler3DTransform in order to perform a
> Centered Rigid Registration. I had previously been using the method
> SetTransformParameters for initializing the Registration but would now
> like to set a rotation matrix and an offset to initialise the tranform. I
> do not though understand the relation between the initial Parameters and
> the offset and rotation matrix. Are both to initialize? Is the
> SetTranformParameters the only way to initialize my Registration or can
> both initialize my Registration? I have read the ITK Software Guide on
> the Rotation Matrix and SetTransformParameters. Can anyone help me?
> 
> Thanks,
> Anonymous User
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk . org
> http://www . itk . org/mailman/listinfo/insight-users
>