Source Coding
The source coding category includes quantization, data
compression, data expander, and differential pulse
code demodulation (DPCM). This toolbox includes a
SIMULINK Source Coding
Library and the following MATLAB functions:
- compand - Source code mu-law or A-law compressor or expander.
- dpcmdeco - Differential pulse code modulation decode computation.
- dpcmenco - Differential pulse code modulation encode computation.
- dpcmopt - Differential pulse code modulation parameter optimization.
- lloyds - Scalar quantization optimization using training data.
- quantiz - Quantization index and quantized output value.
You can view a list of
all SIMULINK blocks in this category.
Example: Using DPCM to quantize a sinusoidal signal.
This example uses the following MATLAB commands:
- t=[0:.1:40];
- sig = sin(t);
- [p_tran,codebook,partition]=dpcmopt(sig,1,8);
- indx = dpcmenco(sig, codebook,partition,p_tran);
- quant = dpcmdeco(indx, codebook, p_tran);
- subplot(211);plot(t,indx);
- title('Quantized digital output.');
- subplot(212);plot(t,[sig,quant]');
- title('Quantization recovery and orginal signal.');
Return to the first page of the tutorial
Return to the functionality listing
This is hcomfrmt.html file.