next | previous | forward | backward | up | top | index | toc | Macaulay2 web site
NCAlgebra :: transpose(NCMatrix)

transpose(NCMatrix) -- Transposes an NCMatrix

Synopsis

Description

This command transposes an NCMatrix

i1 : A = QQ{a,b,c,d}

o1 = A

o1 : NCPolynomialRing
i2 : M = ncMatrix {{a,b,c,d},{b,c,d,a}}

o2 = | a  b  c  d |
     |            |
     | b  c  d  a |

o2 : NCMatrix
i3 : N = M || 2*M || -3*M

o3 = |  a    b    c    d  |
     |                    |
     |  b    c    d    a  |
     |                    |
     |  2a   2b   2c   2d |
     |                    |
     |  2b   2c   2d   2a |
     |                    |
     | -3a  -3b  -3c  -3d |
     |                    |
     | -3b  -3c  -3d  -3a |

o3 : NCMatrix
i4 : transpose N

o4 = | a  b  2a  2b  -3a  -3b |
     |                        |
     | b  c  2b  2c  -3b  -3c |
     |                        |
     | c  d  2c  2d  -3c  -3d |
     |                        |
     | d  a  2d  2a  -3d  -3a |

o4 : NCMatrix