Question: How to display animation in while loop

I only want to display 'position' in animation while tend <= 12:
This is the trial:

restart:with(plots):
for tend from 0 to 50
while (tend <= 12) do
pos:=animate(textplot3d,[[-1.8,0,alpha*tend, 'position']], tend=0..50,frames=150);
od;
display(pos);


I receive error messages:
error, (in plots/animate) 0=0..50 is an invalid animation range

 

Then I try:

restart:with(plots):
while (tend <= 12) do
pos:=animate(textplot3d,[[-1.8,0,alpha*tend, 'position']], tend=0..50,frames=150);
od;
display(pos);

I receive error message: cannot determine if this expression is true or false: tend<=12

So I try:

restart:with(plots):
tend:=0;
while (tend <= 12) do
pos:=animate(textplot3d,[[-1.8,0,alpha*tend, 'position']], tend=0..50,frames=150);
od;
display(pos);

Same error massage as first try: error, (in plots/animate) 0=0..50 is an invalid animation range

I'm lost. I use wrong loop? Please help?

 

[Excessive blank lines removed.---Carl Love as a Moderator]

Please Wait...