Maple V5 to Maple 18 - How to create a list of variables? -


i used maple v5 in 92 write functions solve problems using groebner basis. since have used maple simple calculations , therefore programming skills long-forgotten. of functions wrote , used @ time no longer work , trying go , update them maple version have, is, maple 18.

questions: a) there automatic tool update old maple functions? b) commands such vars := [x.(1 .. n)] used work not anymore. ideia create list x1,x2,.. xn. know seq(x[i], = 1 .. 5) create list x_1,x_2, ... not same. c) tips , suggestions how smooth out process of updating welcome.

thanks

ed

there changes language between maple v release 5 , maple 6, , replacement of . || 1 of those.

maple 6 (and 7 if recall) shipped additional binary updtsrc act on maple source files , make text replacements. example, if start plaintext file var.mpl containing this,

vars := [x.(1 .. n)]; 

and apply shell command updtsrc var.mpl output,

`.` has been replaced `||`; see ?|| vars := [x||(1 .. n)]; 

i did on ubuntu 14.04.4 lts linux, using (redhat) updtsrc binary downloaded http link linux on this page.

if maple v sources in .mws worksheet file might have export input plaintext file.

i haven't tried in (on plaintext file, in dos window, or powershell) on ms-windows (though zip file page did unpack updtsrc.exe file).

so if have great deal of old codes containing language incompatibilities between maple v , maple 6 try route automate conversion.

there have been commands deprecated betwen maple 6 , maple 18 (eg, lowercase vector) few further language changes (backwards incompatibilities).

i suggest read pages in maple 18 language updates. in particular suggest @ pages these topics (entering these in brower's search bar):

updtsrc  updates,maple6,compatibility 

as second example involving vector, true vector has been deprecated , superceded vector command.

but in maplev r5 should not have been using op(f) on vector f. more correct have been eval(f) or evalm(f). eg,

f:=vector([-x1^2,x2*u]);                                              [   2      ]                                        f := [-x1 , x2 u]  var:=u;                                              var := u  subs(var=cat(var,0), eval(f));                                           [   2       ]                                          [-x1 , x2 u0] 

now, suppose instead use vector in above. in case using op(f) in subs call produce error cited, because unlike vector vector beast not have last-name-eval.

f:=vector([-x1^2,x2*u]);                                                 [   2]                                           f := [-x1 ]                                                [    ]                                                [x2 u]  var:=u;                                              var := u  subs(var=cat(var,0), op(f)); error, invalid input: subs received 2, not valid 2nd argument 

you still use eval(f) here, in fact not necessary.

subs(var=cat(var,0), eval(f));                                              [   2 ]                                             [-x1  ]                                             [     ]                                             [x2 u0]   subs(var=cat(var,0), f);                                               [   2 ]                                              [-x1  ]                                              [     ]                                              [x2 u0] 

lastly, try download , install point-release maple 18.02 rather stick maple 18.00. can find here.


Comments