public static void main(String[] args) {

    String filename = args[0];
    double frame_size = Double.parseDouble(args[1]);
    double hanning_window_size = Double.parseDouble(args[2]);

    WavReader reader = new WavReader();
    try {
      WavData wav = reader.read(filename);

      SpectrumExtractor extractor = new SpectrumExtractor(wav);

      Spectrum spectrum = extractor.getSpectrum(frame_size, hanning_window_size);

      for (int i = 0; i < spectrum.numFrames(); ++i) {
        for (int j = 0; j < spectrum.numFreqs(); ++j) {
          System.out.print(spectrum.get(i, j) + " ");
        }
        System.out.println("");
      }
    } catch (UnsupportedAudioFileException e) {
      e.printStackTrace();
    } catch (IOException e) {
      e.printStackTrace();
    } catch (AuToBIException e) {
      e.printStackTrace();
    }
  }