function [rba]=rowblock(a,m,n)
%------------------------------------------------------------------------------
% Usage: [rba]=rowblock(a,m,n) - Row block form of matrix 'a'
%------------------------------------------------------------------------------
% a: (m x n) block matrix, all the blocks should have the same dimension r x t
% rba: (r x t*n*m) matrix 
%------------------------------------------------------------------------------
% Juan Carlos Gomez - 12/10/2001.
%------------------------------------------------------------------------------
[ma,na]=size(a);
r=ma/m;
t=na/n;
rba=[];
for i=1:m,
  rba=[rba,a(r*(i-1)+1:r*(i-1)+r,:)];
end; 