Newsgroups: comp.parallel.pvm
From: Donald Krieger <don@neuronet.pitt.edu>
Subject: Re: How to pack just part of a matrix ?
Organization: University of Pittsburgh
Date: 1 Feb 1995 14:02:46 GMT
Message-ID: <3go4a6$ior@usenet.srv.cis.pitt.edu>

Matthias:

	I think this is more of a fortran question than
a pvm one.  The elements of the matrix a(m,n) are organized
in memory as follows:

	1 	m+1	.	.	.	(n-1)m +1
	2	m+2	.	.	.	(n-1)m +2
	.	.
	.	.
	.	.
	m	2m	.	.	.	mn

If you want to send columns x - y, the first element is
a(1,x), there are (y-x+1)m elements and the stride is 1.
In this case you can pack them all at once.

If you want to send rows x - y, you must pack each row
separately.  The first element of row x is a(x,1), there are
n elements and the stride is m.

I hope I got this right.  Good luck.

				Don

