Synthesize and Channelize Audio in Simulink
Synthesize a series of four stereo signals into a broadband signal by using the Channel Synthesizer block. At the receiving end of the model, split this broadband signal back into the individual narrowband signals by using the Channelizer block.
The inputs to the model are four stereo signals.
FunkyDrums.mp3
SoftGuitar.ogg
RockDrums.mp3
RockGuitar.wav
Each signal has a size of 1024-by-2 samples. The two columns (channels) represent the left channel and the right channel of the stereo signal. To store the stereo channels, the 'Convert to Complex and Mux' block converts each signal into complex signals. It then multiplexes the complex signals by a Matrix Concatenate block to form a 1024-by-4 matrix. The Channel Synthesizer block synthesizes these four signals into a single broadband signal of size 4096-by-1. The Channelizer block that follows splits this broadband signal back into narrow subbands. The Channelizer block has 4 outputs, each output is a 1024-by-1 vector representing a narrow band.
Open the channelizer_synthesizer.slx
model.
Select the audio signal you want to listen to and play this signal using the Audio Device Writer block.
Run the model. View the spectra of the input, muxed, and output signals.
The Muxed Spectrum window shows the spectrum of the broadband signal. The Channelized Spectrum window shows the spectra of the four narrowband signals. The input and output spectra match for any selected signal.
Increase the oversampling ratio of the Channelizer block to 2, which means the M/D ratio described in Algorithm is now 2. You can do this by decreasing the decimation factor to 2, so that M/D = 4/2, which equals 2.
As you can see in the Output Spectrum plot, the output sample rate of the polyphase filter bank has increased by a factor of 2.
Save and close the model.