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. Advertisements

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,572
    Brent Hayhoe
    Nov 21, 2003
  2. Stefan Duenser

    Basic shifting question

    Stefan Duenser, Dec 7, 2004, in forum: VHDL
    Replies:
    4
    Views:
    531
    Stefan Duenser
    Dec 8, 2004
  3. Replies:
    1
    Views:
    552
  4. vidhya
    Replies:
    0
    Views:
    565
    vidhya
    Jul 20, 2005
  5. Replies:
    3
    Views:
    419
    Roedy Green
    Dec 18, 2005
  6. Kallen
    Replies:
    0
    Views:
    410
    Kallen
    Feb 21, 2006
  7. lvcargnini

    Matrix composed by two matrix

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

    Matrix*Vector and Vector*Matrix

    Holgerson, Oct 25, 2007, in forum: C++
    Replies:
    3
    Views:
    579
    Holgerson
    Oct 26, 2007
Loading...