tutdpcm.m
来自「数字通信第四版原书的例程」· M 代码 · 共 23 行
M
23 行
function tutdpcm
%TUTDPCM Shows a source coding example.
% This function is called by the commhelp.html
%
% See also: hmodem.
% Wes Wang 11/20/95.
% Copyright (c) 1995-96 by The MathWorks, Inc.
% $Revision: 1.1 $ $Date: 1996/04/01 18:04:05 $
figure
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 vs. orginal signal.');
%---end of tutdpcm---
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?