Program_2_3.m
资源名称:speech.rar [点击查看]
上传用户:ay_070428
上传日期:2014-12-04
资源大小:11427k
文件大小:0k
源码类别:
语音合成与识别
开发平台:
Matlab
- % Program_2_3
- % Illustration of Signal Generation
- %
- clf;
- % Random noise generation
- R = 51;
- d = rand(R,1) - 0.5;
- % Generate the uncorrupted signal
- for m = 1:1:R;
- s(m) = 2*(m-1)*((0.9)^(m-1));
- end
- k = 0:R-1;
- % Plot the signal and the noise
- subplot(2,1,1);
- stem(k,s)
- xlabel('Time index n'); ylabel('Amplitude');
- title('Original uncorrupted sequence');
- subplot(2,1,2);
- stem(k,d)
- xlabel('Time index n'); ylabel('Amplitude');
- title('Noise');