[vtkusers] matrices.... order of the rows and columns

David Doria daviddoria+vtk at gmail.com
Tue Feb 23 09:53:03 EST 2010


On Tue, Feb 23, 2010 at 9:39 AM, Giancarlo Amati <ilferraresebono at hotmail.it
> wrote:

>  Hello guys,
>
> I would like to know if a vtkMatrix4x4 is allocated by rows or column. I
> mean:
>
> if I have a matrix like:
>
> M =
> a b c d
> e f g i
> j k l m
> n o p q
>
> and I do  loop like:
>
> for(i=0 to 3)
>    for(j=0 to 3)
>       vtkMat.element(i,j,M[i,j]);
>
> is my vtkMat used as the transposed of the original?
>
> kind Regards.
> Giancarlo
>
>
You should be able to determine the ordering quickly simply by looking at
the output. Also, you can use the Transpose function:

http://www.vtk.org/Wiki/VTK/Examples/MatrixTranspose

Thanks,

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100223/34fac1ac/attachment.htm>


More information about the vtkusers mailing list