[Maxima] Draw victor list?
Thomas Widlar
twidlar at yahoo.com
Sat May 19 11:11:56 CDT 2007
I would have to create a gr3d object with the rest of the window dressing
for the plot and apply that object at the same time, right?
Mario Rodriguez wrote:
>El vie, 18-05-2007 a las 17:54 -0500, Thomas Widlar escribió:
>
>
>>I've installed maxima 5.12 with gnuplot 4.2 and share/draw/draw.lisp.
>>
>>I see from draw.lisp that I can draw 3d vectors (x,y,z,dx,dy,dz).
>>How can I pass draw a list of 3d such vectors? (I'm still learning maxima.)
>>
>>Thanks.
>>
>>
>
>The syntax is:
>
>draw3d(vector([x1,y1,z1],[dx1,dy1,dz1]),
> vector([x2,y2,z2],[dx2,dy2,dz2]),
> .........
> vector([xn,yn,zn],[dxn,dyn,dzn]));
>
>If you have a small set of vectors:
>
>v1:[5, 5, 5, 2*sin(5), 2*cos(5), 2*log(5)]$
>v2:[5, 5, 10, 2*sin(5), 2*cos(5), 2*log(10)]$
>v3:[5, 5, 15, 2*sin(5), 2*cos(5), 2*log(15)]$
>v4:[5, 5, 20, 2*sin(5), 2*cos(5), 2*log(20)]$
>v5:[5, 10, 5, 2*sin(5), 2*cos(10), 2*log(5)]$
>v6:[5, 10, 10, 2*sin(5), 2*cos(10), 2*log(10)]$
>v7:[5, 10, 15, 2*sin(5), 2*cos(10), 2*log(15)]$
>v8:[5, 10, 20, 2*sin(5), 2*cos(10), 2*log(20)]$
>v9:[5, 15, 5, 2*sin(5), 2*cos(15), 2*log(5)]$
>v10:[5, 15, 10, 2*sin(5), 2*cos(15), 2*log(10)]$
>
>make a list with them and construct the list of vector objects:
>mylist:[v1,v2,v3,v4,v5,v6,v7,v8,v9,v10];
>vectobj: makelist(vector([k[1],k[2],k[3]],[k[4],k[5],k[6]]),k,mylist);
>
>And finally apply draw3d to the list:
>apply(draw3d,vectobj);
>
>
>
>Try the code in my previous post if you have to work with automatically
>(many) generated vectors.
>
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.math.utexas.edu/pipermail/maxima/attachments/20070519/023eb979/attachment.htm
More information about the Maxima
mailing list