clear
close

fig=figure('Units','inches','Position',[0.0 0.0 8.5 11.0]...
,'PaperUnits','inches','PaperPosition',[0.0 0.0 8.5 11.0]);

load amp_dat;
n=size(amp_dat,1)

for i=1:n,
 f(i)=amp_dat(i,1)/6.283185307;
 xr(i)=amp_dat(i,2);
 xi(i)=amp_dat(i,3);
 yr(i)=amp_dat(i,4);
 yi(i)=amp_dat(i,5);
 zr(i)=amp_dat(i,6);
 zi(i)=amp_dat(i,7);
end
amax(1)=max(abs(xr));
amax(2)=max(abs(yr));
amax(3)=max(abs(zr));
amax(4)=max(abs(xi));
amax(5)=max(abs(yi));
amax(6)=max(abs(zi));
amx=max(amax)*1.1
fmx=max(f)

subplot(3,1,1)
plot(f,xr,'-',f,xi,'--')
axis([0 fmx -amx amx])
title('Velocity Fourier Amplitude (Solid and Dashed lines: Real and Imaginary Parts)')
ylabel('Velocity_X Amplitude (cm)')
xlabel('Frequency (Hz)')

subplot(3,1,2)
plot(f,yr,'-',f,yi,'--')
axis([0 fmx -amx amx])
ylabel('Velocity_Y Amplitude (cm)')
xlabel('Frequency (Hz)')

subplot(3,1,3)
plot(f,zr,'-',f,zi,'--')
axis([0 fmx -amx amx])
ylabel('Velocity_Z Amplitude (cm)')
xlabel('Frequency (Hz)')

print p.ps
