Matrix Shifting

Discussion in 'VHDL' started by a_Conan, Aug 23, 2005.

  1. a_Conan

    a_Conan Guest

    Hello,
    I have this code:
    ---------------------
    package ACONSTANTS is
    constant N : integer := 3;
    constant M : integer := 3;
    type NM is array(0 to N, 0 to M) of integer; --Matrix N by N end
    ACONSTANTS;
    ..
    ..
    ..
    signal Matrix_in : NM := ((0 , 1 , 2 , 3 ),
    (4 , 5 , 6 , 7 ),
    (8 , 9 , 10, 11),
    (12, 13, 14, 15));

    ---------------
    The question can I Rotate the matrix in VHDL to represent it as below:

    Matrix_in := ((0 , 1 , 2 , 3 ),
    (5 , 6 , 7 , 4 ),
    (10, 11, 8 , 9 ),
    (15, 12, 13, 14));


    Thank you
     
    a_Conan, Aug 23, 2005
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. walala
    Replies:
    3
    Views:
    5,334
    Brent Hayhoe
    Nov 21, 2003
  2. lvcargnini

    Matrix composed by two matrix

    lvcargnini, Jul 4, 2006, in forum: VHDL
    Replies:
    3
    Views:
    2,675
    Jonathan Bromley
    Jul 5, 2006
  3. Holgerson

    Matrix*Vector and Vector*Matrix

    Holgerson, Oct 25, 2007, in forum: C++
    Replies:
    3
    Views:
    409
    Holgerson
    Oct 26, 2007
  4. Terry Reedy
    Replies:
    0
    Views:
    556
    Terry Reedy
    Apr 2, 2009
  5. Robert Kern
    Replies:
    0
    Views:
    596
    Robert Kern
    Apr 2, 2009
Loading...

Share This Page