%THis is a simple matlab program to read the Z.DATA
%file written by the 2D circ program. m is the
%counter that loops through the timesteps;
% note that at the moment the program expects 240 timesteps
%in the output file. Note also that this is written
%for a imax= 10 and jmax=22. If you change these you must
%change lines: 3,7,8,9,11,20, and 23, where line 1 is the
%first executable line below. --RSling, 1996
fid = fopen('Z.DATA','r');
for m=1:240;
F=fscanf(fid,'%e %e %e %e %e %e %e', 220);
p=1;
q=7;
k=0;
for l=1:4;
if q>=22;
   q=22;
end;
for i=1:10;
for j=p:q;
k=k+1;
Z(i,j)=F(k);
end;
end;
p=q+1;
q=q+7;
end;
A=Z(2:10,2:22);

mesh(A);
axis([1 22 1 10 -1 1]);
drawnow;
end;
