[Insight-users] Composition of two versor transforms

Patrik Brynolfsson patrik.brynolfsson at gmail.com
Fri Nov 27 07:23:09 EST 2009


Hello Luis,

Thanks for the answer and sorry for the double post, I had some problems
with my mail account.

I'm using "versorRigid3DTransform", and from what I've gathered all i need
is to save the versor (1x6) and center of rotation (1x3) to perform the same
transform again. A while back I tried to extract the rotation matrix and use
that with the versorRigid3DTransform but from what I recall that was not
allowed. Perhaps I misremember. Anyway was wondering if there is a way to
only use the versors and center of rotation to combine the two transforms,
without the extra step of dealing with matrices?

Thanks for the detailed explanation in your answer!

Regards, Patrik

2009/11/26 Luis Ibanez <luis.ibanez at kitware.com>

> Hi Patrik,
>
> Each Versor Transform does the equivalent of:
>
>                     P'  = Transform(P) = M x P + T
>
> Where M is a rotation matrix computed from the Versor parameters,
> and T is the Translation vector.
>
> to be more precise,
> this Transform also has a Center of rotation "C",
> so the actual computation is:
>
>    P' = Transform(P) = M x ( P - C ) + T + C
>
> Now, when you compose two Versor Transforms you should do:
>
>   P" = Transform2( P' ) = Transform2( Transform1( P ) )
>
> This leads to:
>
>  P" = M2 x ( P' - C2 ) + T2 + C2
>  P" = M2 x ( M1 x ( P - C1 ) + T1 + C1  - C2 ) + T2 + C2
>
> which leads to
>
>  P" =  M2 x M1 x ( P - C1 )  + M2x(T1+C1-C2)  + (T2+C2)
>
> You can get the matrix M from each transform by calling the
> method: GetMatrix(); the translation by calling GetTranslation();
> and the center C by calling the method GetCenter().
>
>
>
>    Regards,
>
>
>         Luis
>
>
> --------------------------------------------------------
> On Thu, Nov 26, 2009 at 4:05 AM, Patrik Brynolfsson
> <patrik.brynolfsson at gmail.com> wrote:
> > Hello everyone,
> > I have a question I hope someone can clarify for me. I want to combine
> the
> > result from two versor transforms. From what I've gathered I shouldn't
> add
> > the elements of the two, but how then? Can someone please explain?
> > Thanks in advance!
> > --
> > Patrik Brynolfsson
> >
> >
> > _____________________________________
> > Powered by www.kitware.com
> >
> > Visit other Kitware open-source projects at
> > http://www.kitware.com/opensource/opensource.html
> >
> > Kitware offers ITK Training Courses, for more information visit:
> > http://www.kitware.com/products/protraining.html
> >
> > Please keep messages on-topic and check the ITK FAQ at:
> > http://www.itk.org/Wiki/ITK_FAQ
> >
> > Follow this link to subscribe/unsubscribe:
> > http://www.itk.org/mailman/listinfo/insight-users
> >
> >
>



-- 
Patrik Brynolfsson
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20091127/112e8548/attachment.htm>


More information about the Insight-users mailing list