Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo
Close
From: Paulo Cortes <cortes@as...>  20041014 21:19:49

Hi I am using plplot to plot a vector field, but am having problems. I get the vector field, but I also get a line that goes from the lower left corner to the upper right corner of the plot, I can't get rid of it. any ideas? Thanks!!!!! Paulo 
From: Andrew Ross <andrewross@us...>  20041014 22:09:49

On Thu, Oct 14, 2004 at 04:20:53PM 0500, Paulo Cortes wrote: > Hi > > I am using plplot to plot a vector field, but > am having problems. I get the vector field, but I also > get a line that goes from the lower left corner to the > upper right corner of the plot, I can't get rid of it. > any ideas? Could it possibly be your array size is not quite right? Otherwise it is hard to tell from your description. Can so provide us with a simple example code? Andrew 
From: Paulo Cortes <cortes@as...>  20041015 01:25:13

Hi thanks for the reply I wasn't that explicit because I wasn't sure if the list was alive :). Here is little piece of my code. PMap(i,j).getDensity() is an angle (polarization angle). I get the shape that I should; except for a line like this:  *  *  * * _ _ _ _ in front of the vector field. Thanks!!! Paulo ps. Is it politically correct to include an image as an attachment? so I can include my problem? nx=33;ny=33;nz=33; for (j = 0; j<ny; j++) { for (i = 0; i<nx; i++) { x = (inx/2)*dx; y = (jny/2)*dy; cgrid2.xg[i][j] = (inx/2); cgrid2.yg[i][j] = (jny/2); printf("y=%3.1f z=%3.1f Qmap=%3.8f Umap=%3.8f\n",y,z, QMap(i,j).getDensity(),UMap(i,j).getDensity()); fpol = sqrt(QMap(i,j).getDensity()*QMap(i,j).getDensity()+ UMap(i,j).getDensity()*UMap(i,j).getDensity())/ IMap(i,j).getDensity(); u[i][j]= fpol*cos(PMap(i,j).getDensity()); v[i][j]= fpol*sin(PMap(i,j).getDensity()); pp = sqrt(u[i][j]*u[i][j] + v[i][j]*v[i][j]); } } pls>env(xmin, xmax, ymin, ymax, 0, 0); pls>lab("(x)", "(y)", "#frPLplot B field"); pls>col0(2); pls>vect(u,v,nx,ny,1.0,plstream::tr2,(void *)&cgrid2); pls>col0(1); Andrew Ross wrote: > On Thu, Oct 14, 2004 at 04:20:53PM 0500, Paulo Cortes wrote: > >>Hi >> >>I am using plplot to plot a vector field, but >>am having problems. I get the vector field, but I also >>get a line that goes from the lower left corner to the >>upper right corner of the plot, I can't get rid of it. >>any ideas? > > > Could it possibly be your array size is not quite right? Otherwise it > is hard to tell from your description. Can so provide us with a simple > example code? > > Andrew > > >  > This SF.net email is sponsored by: IT Product Guide on ITManagersJournal > Use IT products in your business? Tell us what you think of them. Give us > Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more > http://productguide.itmanagersjournal.com/guidepromo.tmpl > _______________________________________________ > Plplotgeneral mailing list > Plplotgeneral@... > https://lists.sourceforge.net/lists/listinfo/plplotgeneral > 
From: Arjen Markus <arjen.markus@wl...>  20041015 07:23:38

Paulo Cortes wrote: > > Hi > > thanks for the reply I wasn't that explicit because I wasn't sure if the > list was alive :). Here is little piece of my code. > PMap(i,j).getDensity() is an angle (polarization angle). I get the shape > that I should; except for a line like this: > >  * >  * >  * > * > _ _ _ _ > > in front of the vector field. Thanks!!! > > Paulo > > ps. Is it politically correct to include an image as an attachment? > so I can include my problem? > Hm, I can not see anything obviously wrong with your code. Perhaps the data have something strange about them? Very large values perhaps? (As internally the float coordinates are translated to integer pixel coordinates, you could be suffering from integer overflows) (If you want to send a single picture related to the problem at hand :), I guess it will not be considered rude) Regards, Arjen 