[Insight-users] Bug in RigidXDTransform

Julien Jomier jjomier@cs.unc.edu
Wed, 20 Nov 2002 10:59:49 -0500


Hi Mark,

Thanks for the bug report, I've checked in a fix on the CVS server.

> Furthermore in the transform->Compose() method 
> m_InverseMatrix is set to m_RotationMatrix.GetTranspose(),
> and not to the inverse matrix.

The rotation matrix should be orthogonal that's why we are using 
the transpose since it should be the same as the inverse.
If something is wrong here, you may need to make your rotation
matrix othogonal.

> A further thing is when using rotation matrices with 
> coefficients greater than 1. My application aborts without an 
> error message. I know that rotation matrices with 
> coefficients graeter than 1 should not apperas, but if 
> happen there should there should be 
> descriptive error message.

Actually, when you set the rotation matrix, the SetRotationMatrix()
function
is checking if the matrix your are passing is orthogonal. If not, it
throws an exception.
I guess that's what's happening.

Let us know if you find other prroblems.

Thanks again !

Julien


> -----Original Message-----
> From: insight-users-admin@public.kitware.com 
> [mailto:insight-users-admin@public.kitware.com] On Behalf Of 
> Mark Hastenteufel
> Sent: Wednesday, November 20, 2002 10:38 AM
> To: ITK Users
> Subject: [Insight-users] Bug in RigidXDTransform
> 
> 
> Hallo Developers!
> 
> I've found a bug in itkRigi3DTranform/itkRigid2DTranform.
> 
> I wanted to use the tranform->Inverse() method. 
> But the result was not the one I've expected. The same 
> when calling transform->BackTransform(). 
> 
> The problem seems to be the internal variable 
> m_InverseTransform, which is never set correctly
> to m_RotationMatrix.GetInverse() but is always 
> the identity. One have to set in transform->SetRotationMatrix()
> m_InverseTransform=m_RotationMatrix.GetInverse() and
> things work.
> 
> Furthermore in the transform->Compose() method 
> m_InverseMatrix is set to m_RotationMatrix.GetTranspose(),
> and not to the inverse matrix.
> 
> A further thing is when using rotation matrices with 
> coefficients greater than 1. My application aborts without an 
> error message. I know that rotation matrices with 
> coefficients graeter than 1 should not apperas, but if 
> happen there should there should be 
> descriptive error message.
> 
> 
> 
> 
> -- 
> Mark Hastenteufel
> Deutsches Krebsforschungszentrum         (German Cancer 
> Research Center)
> Div. Medical and Biological Informatics H0100    Tel: (+49) 
> 6221-42 2353
> Im Neuenheimer Feld 280                          Fax: (+49) 
> 6221-42 2345
> D-69120 Heidelberg              e-mail            
> M.Hastenteufel@DKFZ.de
> Germany                         
> http://www.dkfz.de/mbi/people/markh.html
> 
> _______________________________________________
> Insight-users mailing list
> Insight-users@public.kitware.com 
> http://public.kitware.com/mailman/listinfo/ins> ight-users
>