Newsgroups: comp.parallel.pvm
From: Le Goff <legoff@icp.grenet.fr>
Subject: Re: a little problem
Organization: Institut de la Communication Parlee
Date: 30 Nov 1995 07:13:48 GMT
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-ID: <49jljc$aej@cicg-communication.grenet.fr>

s950062@logic.csc.cuhk.hk (fft) wrote:
>Dear all,
>I've a little problem in pvm.
>    float mat[4][4],vec[4];
>    n = 4; nproc=n; int k;
>        r=0;
>        for (k=0; k<nproc ; k++)
>        {        
>	pvm_initsend(PvmDataDefault);
>	pvm_pkint(&nproc, 1, 1);
>	pvm_pkint(tids, nproc, 1);
>	pvm_pkint(&n, 1, 1);
>	pvm_pkfloat(vec, n, 1);
>        pvm_pkfloat(mat[r], 1, 1);   /* anything wrong here? */
                            ^^^
if you send an array of r floats, you must tell it to pvm:
so, the correct line will be : 
		pvm_pkfloat(mat[r], n, 1);
if n is the number of line.

>        pvm_send(tids[k],0);
>        r++;
>        }
>--fft

Hope it helps.

************************************************
*   Bertrand LE GOFF                           * 
*   Equipe SYNTHESE                            * 
*   Institut de la Communication Parlee        *
*   38040 GRENOBLE cedex 9                     *
*   FRANCE                                     *
*   Email : legoff@icp.grenet.fr               *
*   http://ophale.icp.grenet.fr/               *
************************************************


