Question: use of map and map2

Hi all,

#####################################
myp:=proc(a,b,c)

local ans;

ans:=zip(`+`,a,b);

ans:=ans*c;

return ans;

end proc;
myp([$1..4],[x,y,z,w],2);
map2(myp,[$1..4],{[x,y,z,w],[x2,y2,z2,w2],[x3,y3,z3,w3]},4);

map2(myp,[$1..4],{[x,y,z,w],[x2,y2,z2,w2],[x3,y3,z3,w3]},10);
map2(myp,[$1..4],{[x,y,z,w],[x2,y2,z2,w2],[x3,y3,z3,w3]},0.5);

#####################################

Is it possible to use something like
#map2(myp,[$1..4],{[x,y,z,w],[x2,y2,z2,w2],[x3,y3,z3,w3]},[4,10,0.5]);
to achieve this?

Or should I just use a loop?

Is there a document I can read apart from the ?map to look for some general tips to 'simutanous' computing? both symbolically and numerically in Maple. And is there any documentation on using multicore CPUs?

 

Many thanks,

 

Casper

Please Wait...