1 of 16

Audio Equalizer

EGCP 371 - Signals and Systems

Group 4:Omar Garcia, Hovaness Karamanian, Eduardo Lopez, Peter Ottens

2 of 16

Introduction

  • Our group was tasked with making a Song/Audio Equalizer using MatLab to pull audio from a song of our choice and manipulate it to pass through a filter to change how the audio comes out. The basic functions of a real life equalizer where you should be able to change the audio to have the sound you please.
  • We would try and get a waveform of the desired song and see the original while it’s not altered. We will use MatLab functions to manipulate it and get a different waveforms that would display what filter we pass through it. We can get a high pass filter run, low pass filter run, basically anything we want or can manage to code within MatLab to have the function of altering audio. In our code we only made these two filters so you can visually see where the lows and highs would sample out.

3 of 16

Low Pass Filter

  • Is a filter that passes signals with a frequency which are lower than the selected cutoff frequency, and deteriorates signals with frequencies that are higher than the cutoff frequency.
  • In other words noise is a high frequency signal, when passed through a low pass filter most of the noise is removed and a clear sound is produced.
  • An ideal low pass filter would eliminate all frequencies above the cutoff frequency, and can mathematically be arrived to by multiplying a signal by the rectangular function in the frequency domain, or the convolution with its impulse response in the time domain. Unfortunately for real time applications we would approximate the ideal filter by truncating and windowing the infinite impulse response to make a finite impulse response.

4 of 16

High Pass Filter

  • Is a filter which does the opposite and passes frequencies with higher then certain cutoff frequencies and diminishes signals with frequencies lower than the cutoff frequency.
  • High pass filters are great to clean up unwanted deep signals and tighten up arrangements, they are also known as a bass-cut filters and usually modeled as a time invariant system.
  • High pass filters are used as a part of an audio crossover to direct high frequencies to a treble speaker while eliminating bass signals which could interfere or even damage the speaker.

5 of 16

What we did/ Our approach

  • Beginning
    • Complicated UI
    • 16 bands
      • Amount of frequencies you can manipulate
    • Online Tutorials
    • Multiple Songs
    • Live Demo
    • Individual Roles
  • End
    • Simple UI
    • 1 Band
    • Few Songs
    • Blending of Roles

6 of 16

Code Challenges

  • We wanted to make a customizable equalizer that would mimic a studio equalizer with dials/ buttons where you can shift the audio in real time but trying to find resources and putting the code into practice was too long and a majority of our code would be 200 lines of code just for the GUI.
  • We had to make it a preset equalizer within our code and change values as we please to get the desired results.
  • We also had to find values that would display the waveforms visually pleasing since the numbers were too big or too small where you would need to go into the 10^(24) and zoom in to see any change at all.

7 of 16

Code

Audio files:

  • We don’t talk about Bruno - Encanto
  • Mozart - Requiem
  • Five Finger Death Punch - The Pride

8 of 16

Code

This code writes a .wav audio file to an array. Then a lowpass or highpass filter is applied to the signal. In order to see the effects these have on the signal fourier is used to find the frequency domain of the signal. This will show you visually what frequencies have been cut from the original. The new fft arrays are then cut to remove reflections and focus the majority of frequencies used.

9 of 16

Code

This code displays the plots showing the fourier transform of the original and with a lowpass or highpass filter applied to it.

Additionally commented out is code to generate an audio file with a filter applied to it.

10 of 16

Results / Discoveries

The original signal has a large amount of low frequencies so most other frequencies are dwarfed by it

The lowpass filter cuts higher frequencies on the plot you can see it flattens the tail.

The highpass filter cuts lower frequencies so by removing some of the most common frequencies you can see the other frequencies more prominently.

  • Bruno.wav

11 of 16

Results / Discoveries

  • Bruno_lowpass.wav

12 of 16

Results / Discoveries

  • Bruno_highpass.wav

13 of 16

Results / Discoveries

Other examples:

  • Pride.wav

14 of 16

Results / Discoveries

Other examples:

  • Requiem.wav

15 of 16

What we learned/ Conclusion

  • Constructing an Equalizer is a relatively simple task to do in matlab
  • Implementing professional grade EQ is extremely time and hardware intensive (Expensive)
    • Depends on how much control of the signal you desire
  • Audio Engineering Iceberg

16 of 16

References

“Audio Signal Processing in MATLAB.” Section, https://www.section.io/engineering-education/audio-signals-processing-using-matlab/.

“Fast Fourier Transform.” Fast Fourier Transform - MATLAB, https://www.mathworks.com/help/matlab/ref/fft.html.

“How Can I Get Proper Length of FFT.” How Can I Get Proper Length of FFT -, Mathworks, https://www.mathworks.com/matlabcentral/answers/435508-how-can-i-get-proper-length-of-fft.

“Low-Pass Filter.” MATLAB & Simulink, https://www.mathworks.com/discovery/low-pass-filter.html.

“Design Parametric Equalizer.” Design Parametric Equalizer - MATLAB, Mathworks, https://www.mathworks.com/help/audio/ref/designparameq.html.

“Highpass-Filter Signals.” Highpass-Filter Signals - MATLAB, Mathworks, https://www.mathworks.com/help/signal/ref/highpass.html.

“Lowpass-Filter Signals.” Lowpass-Filter Signals - MATLAB, Mathworks, https://www.mathworks.com/help/signal/ref/lowpass.html.