function tone = note(keynum, dur,fs)
%fs = 11025;
tt = 0:1/fs:dur;
freq = 440*2^((keynum-40)/12);
tone = cos(2*pi*freq*tt);
