%
%  This file processes the data from the first order system
%
function data = process_data;
%
%  enter the data as 
%  f (in Hz) Vin (in mV) Vout (in mV); 
%
  measured = [10 1.0 0.20;
              15 1.0 0.281;
              25 1.0 0.446;
              40 1.0 0.656;
              50 1.0 0.748;
              75 1.0 0.898;
              100 1.0 0.997;
              200 1.0 1.062;
              300 1.0 1.036;
              400 1.0 0.983;
              500 1.0 0.925;
              600 1.0 0.846;
              700 1.0 0.786;
              800 1.0 0.734;
              900 1.0 0.682;
              1000 1.0 0.636;
              1500 1.0 0.459;
              2000 1.0 0.373
              ];
%
%  Be sure the rows are sorted by frequency
%
   measured = sortrows(measured,1);
%
%  get the frequency of the measurement
%
  f = measured(:,1); 
%
%  get the magnitude of the transfer function
%
  mag_H = measured(:,3)./measured(:,2);
%
%  put the data into the data array
%
  data = [f mag_H];
%
  return;