Question: numeric dsolve in for loop

Hi, 

I'm new to maple and have a problem when using the dsolve in a for loop. I get the error message Error, (in dsolve/numeric/process_input) the independent variable (t in phi(t)) cannot be a procedure name and I dont now why. 

The code design is 

for k to kk do
vars := x(t), y(t), phi(t);
ic := x(0) = xx, y(0) = yy, phi(0) = zz;
sys := diff(x(t), t) = y(t),
diff(y(t), t) = -2*gamma*y(t)-alpha*x(t)-beta*x(t)^3+F*cos(phi(t)),
diff(phi(t), t) = 1;
sol := dsolve({ic, sys}, {vars}, numeric, output = listprocedure, numeric = -1);
assign(sol);
x := x(t);
y := y(t);
phi := phi(t);
numpts := 50;
pts := seq([x(2*Pi*i), y(2*Pi*i)], i = 1 .. numpts);
plt(k) := plot([pts], view = [-1.5 .. 1.5, -.5 .. 1], color = black);
xx := 'xx'; yy := 'yy'; zz := 'zz';
xx := x(2*Pi*numpts);
yy := y(2*Pi*numpts);
zz := phi(2*Pi*numpts);
unassign(x, y, phi);
c := x(0) = xx, y(0) = yy, phi(0) = zz
end do

Please Wait...