Question: How to use "seq" with a variable number of elements

How do I create a symbolic sequence with a variable number of elements, so that later I can come back and set the number of elements to an integer? Maple has inert forms for many functions (e.g. Sum and sum), but there does not appear to be anything like "Seq" which would be the inert analogue of "seq".

Here are some of my attempts

  Ls:='seq'(a[j],j=2..p);
eval(Ls,p=5);
subs(p=5,Ls);
Ls:=seq(a[j],j=2..5);
Ls:='seq'(a[j],j=2..5);
eval(%);

 The first line simply echos;

The second and third line give me an error message saying "unable to execute seq"

The last three lines work, but they are not what I need.

Thanks for any insight.

 

PS: Can someone please tell me how to past Maple output to this forum?

Please Wait...