




已阅读5页,还剩15页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
DSP上机作业M2.22.30(b)n=0:1:40;x=sin(0.8*pi*n+0.8*pi);stem(n,x);xlabel(n);ylabel(x(n)(c) n=0:1:40;x=real(exp(i*pi*n*0.2)+imag(exp(i*pi*n*0.1);stem(n,x);xlabel(n);ylabel(x(n) (d)n=0:1:40;x=3*cos(1.3*pi*n)-4*sin(0.5*pi*n+0.5*pi);stem(n,x);xlabel(n);ylabel(x(n)(e)n=0:1:40;x=5*cos(1.5*pi*n+0.75*pi)+4*cos(0.6*pi*n)-sin(0.5*pi*n);stem(n,x);xlabel(n);ylabel(x(n)(分析:此题着重用到了stem函数,n的取值本应是一个基本周期,但为了仿真以及图形清晰易辨,n取140)M2.4t=0:0.001:1;f=input(Frequency of sinusoid in Hz=);FT=input(Sampling frequency in Hz=);g1=sin(2*pi*f*t);plot(t,g1,-);xlabel(time);ylabel(Amplitude);hold on n=0:1:FT;g2=sin(2*pi*f*n/FT);plot(n/FT,g2,o);hold offFrequency of sinusoid in Hz=10Sampling frequency in Hz=50(分析:此题表明了正弦信号与其采样信号的关系)M2.5t=0:0.001:0.5;g1=cos(3*pi*t);g2=cos(17*pi*t);g3=cos(23*pi*t);plot(t,g1,-,t,g2,-,t,g3,:);xlabel(time);ylabel(Amplitude);holdn=0:1:5;gs=cos(0.3*pi*n);plot(n/10,gs,o);hold off(分析:此题验证了公式(2.57),说明同样的采样信号有可能对应不止一个原信号,由此引出the Nyquist sampling theorem)M2.6Number of input samples = 5Number of input samples = 7Number of input samples = 9As the length of the moving average filter is increased,the output of the filter gets more smoother.However,the delay between the input and the output sequences also increases.(分析:长度越大,曲线越平滑,可是越远离原有曲线,即延时越大了。如取长度20,则得下图此时确实很平滑了,可是延时之大也可见一斑)M3.1(1)r=0.8,=0.5Number of frequency points = 513Numerator coefficients = 1 0 0Denominator coefficients = 1 -1.4042 0.64(2)r=0.9,=0.9Number of frequency points = 513Numerator coefficients = 1 0 0Denominator coefficients = 1 -1.1189 0.81(分析:(1)对应,(2) 对应,语句h = freqz(num, den, w)中num,den分别为传递函数分子和分母多项式系数向量,w为复频率响应计算点数,不同的r,值对应着不同的传递函数)M3.2(a)Number of frequency points = 513Numerator coefficients = 1 zeros(1,20) -1Denominator coefficients = zeros(1,10) 1 -1(b)Number of frequency points = 513Numerator coefficients = 1 zeros(1,10) -1Denominator coefficients = 1 -1 (c)Number of frequency points = 513Numerator coefficients = 1 zeros(1,9) -2 zeros(1,9) 1Denominator coefficients = zeros(1,9) 10 -20 10(d)Number of frequency points = 513Numerator coefficients = 100 -99 zeros(1,9) -2 zeros(1,9) -99 100Denominator coefficients = zeros(1,10) 10 -20 10(e)Number of frequency points = 513Numerator coefficients = 0.3129 zeros(1,19) 0.3129 0.3129Denominator coefficients = zeros(1,9) 2 -3.9508 1(分析:此题较为复杂,首先要把3.19题中的式子进行DTFT,然后化成与M3.1相同的形式,再运用Program3-1才可以得到答案,虽然思路很清楚,可是错综复杂,运算很繁琐。)M5.2(a) g=5 -2 2 0 4 3;h=3 1 -2 2 -4 4;Y=fft(g).*fft(h);y=ifft(Y)y =-6 9 -16 20 -4 45(b) x=2-i -1-3i 4-3i 1+2i 3+2i;v=-3 2+4i -1+4i 4+2i -3+i;Y=fft(x).*fft(v);y=ifft(Y)y = 11.0000 +25.0000i -9.0000 +48.0000i 3.0000 +17.0000i 29.0000 + 0.0000i -10.0000 +12.0000i(c) n=0:4;x=cos(pi*0.5*n);y=3.n;H=fft(x).*fft(y);h=ifft(H)h = -23.0000 -69.0000 35.0000 105.0000 73.0000(分析:用circonv程序验证:(a) x1=5 -2 2 0 4 3;x2=3 1 -2 2 -4 4; 3 4 -4 2 -2 1 1 3 4 -4 2 -2 -2 1 3 4 -4 2 2 -2 1 3 4 -4 -4 2 -2 1 3 4 4 -4 2 -2 1 3ans =-6 9 -16 20 -4 45(b)x1=2-i -1-3i 4-3i 1+2i 3+2i;x2=-3 2+4i -1+4i 4+2i -3+i; -3.0000 -3.0000 + 1.0000i 4.0000 + 2.0000i -1.0000 + 4.0000i 2.0000 + 4.0000i 2.0000 + 4.0000i -3.0000 -3.0000 + 1.0000i 4.0000 + 2.0000i -1.0000 + 4.0000i -1.0000 + 4.0000i 2.0000 + 4.0000i -3.0000 -3.0000 + 1.0000i 4.0000 + 2.0000i 4.0000 + 2.0000i -1.0000 + 4.0000i 2.0000 + 4.0000i -3.0000 -3.0000 + 1.0000i -3.0000 + 1.0000i 4.0000 + 2.0000i -1.0000 + 4.0000i 2.0000 + 4.0000i -3.0000 ans = 11.0000 +25.0000i -9.0000 +48.0000i 3.0000 +17.0000i 29.0000 -10.0000 +12.0000i(c)n=0:4;x1=cos(pi*0.5*n);x2=3.n; 1 81 27 9 3 3 1 81 27 9 9 3 1 81 27 27 9 3 1 81 81 27 9 3 1ans = -23.0000 -69.0000 35.0000 105.0000 73.0000通过核实与题目中计算结果一样,本题所作的是离散傅里叶变换()的时域循环卷积定理,即时域循环卷积,频域相乘)M5.3 m=0:9;x=exp(-0.6*m);X=fft(x)X = Columns 1 through 5 2.2109 1.3423 - 0.7788i 0.8611 - 0.5412i 0.7112 - 0.3174i 0.6580 - 0.1470i Columns 6 through 10 0.6441 0.6580 + 0.1470i 0.7112 + 0.3174i 0.8611 + 0.5412i 1.3423 + 0.7788i X1=fft(conj(x);G1=conj(X(1) X(10:-1:2)G1 = Columns 1 through 5 2.2109 1.3423 - 0.7788i 0.8611 - 0.5412i 0.7112 - 0.3174i 0.6580 - 0.1470i Columns 6 through 10 0.6441 0.6580 + 0.1470i 0.7112 + 0.3174i 0.8611 + 0.5412i 1.3423 + 0.7788i X1X1 = Columns 1 through 5 2.2109 1.3423 - 0.7788i 0.8611 - 0.5412i 0.7112 - 0.3174i 0.6580 - 0.1470i Columns 6 through 10 0.6441 0.6580 + 0.1470i 0.7112 + 0.3174i 0.8611 + 0.5412i 1.3423 + 0.7788i(G1=X1说明) x2=conj(x(1) x(10:-1:2);X2=fft(x2)X2 = Columns 1 through 5 2.2109 1.3423 + 0.7788i 0.8611 + 0.5412i 0.7112 + 0.3174i 0.6580 + 0.1470i Columns 6 through 10 0.6441 0.6580 - 0.1470i 0.7112 - 0.3174i 0.8611 - 0.5412i 1.3423 - 0.7788i conj(X)ans = Columns 1 through 5 2.2109 1.3423 + 0.7788i 0.8611 + 0.5412i 0.7112 + 0.3174i 0.6580 + 0.1470i Columns 6 through 10 0.6441 0.6580 - 0.1470i 0.7112 - 0.3174i 0.8611 - 0.5412i 1.3423 - 0.7788i(X2=conj说明)x3=real(x);X3=fft(x3);G3=0.5*(X+conj(X(1) X(10:-1:2)G3 = Columns 1 through 5 2.2109 1.3423 - 0.7788i 0.8611 - 0.5412i 0.7112 - 0.3174i 0.6580 - 0.1470i Columns 6 through 10 0.6441 0.6580 + 0.1470i 0.7112 + 0.3174i 0.8611 + 0.5412i 1.3423 + 0.7788i X3X3 = Columns 1 through 5 2.2109 1.3423 - 0.7788i 0.8611 - 0.5412i 0.7112 - 0.3174i 0.6580 - 0.1470i Columns 6 through 10 0.6441 0.6580 + 0.1470i 0.7112 + 0.3174i 0.8611 + 0.5412i 1.3423 + 0.7788i(X3=G3说明) x4=j*imag(x);X4=fft(x4);G4=0.5*(X-conj(X(1) X(10:-1:2)G4 = 0 0 0 0 0 0 0 0 0 0 X4X4 = 0 0 0 0 0 0 0 0 0 0(X4=G4说明) x5=0.5*(x+conj(x(1) x(10:-1:2);X5=fft(x5)X5 = 2.2109 1.3423 0.8611 0.7112 0.6580 0.6441 0.6580 0.7112 0.8611 1.3423 real(X)ans = 2.2109 1.3423 0.8611 0.7112 0.6580 0.6441 0.6580 0.7112 0.8611 1.3423(X5=real(X)说明) x6=0.5*(x-conj(x(1) x(10:-1:2);X6=fft(x6)X6 = Columns 1 through 5 0 0 - 0.7788i 0 - 0.5412i 0 - 0.3174i 0 - 0.1470i Columns 6 through 10 0 0 + 0.1470i 0 + 0.3174i 0 + 0.5412i 0 + 0.7788i j*imag(X)ans = Columns 1 through 5 0 0 - 0.7788i 0 - 0.5412i 0 - 0.3174i 0 - 0.1470i Columns 6 through 10 0 0 + 0.1470i 0 + 0.3174i 0 + 0.5412i 0 + 0.7788i(X6=j*imag(X)说明)M6.1Type in the numerator coefficients = 2 -5 13.48 -7.78 9Type in the denominator coefficients = 4 7.2 20 -0.8 8Numfactors = 1.000000000000000 -2.100000000000000 5.000000000000004 1.000000000000000 -0.400000000000000 0.899999999999995Denfactors = 1.000000000000000 2.000000000000000 4.999999999999990 1.000000000000000 -0.199999999999999 0.400000000000009Numerator factors 1.000000000000000 -2.100000000000000 5.000000000000004 1.000000000000000 -0.400000000000000 0.899999999999995Denominator factors 1.000000000000000 2.000000000000000 4.999999999999990 1.000000000000000 -0.199999999999999 0.400000000000009Gain constant 0.500000000000000Thus,The pole-zero plot of it is given below:There are 3 ROCS associated with it:R1:|z|,R2:|z|.The inverse z-transform corresponding to the ROC R1 is a left-sided sequence,the inverse z-transform corresponding to the ROC R2 is a two-sided sequence,and the inverse z-transform corresponding to the ROC R3 is a right-sided sequence.(b)Type in the numerator coefficients = 5 3.5 21.5 -4.6 18Type in the denominator coefficients = 5 15.5 31.7 22.52 4.8Numfactors = 1.000000000000000 1.200000000000000 3.999999999999996 1.000000000000000 -0.500000000000000 0.900000000000004Denfactors = 1.000000000000000 2.100000000000003 4.000000000000012 1.000000000000000 0.600000000000037 0 1.000000000000000 0.399999999999960 0Numerator factors 1.000000000000000 1.200000000000000 3.999999999999996 1.000000000000000 -0.500000000000000 0.900000000000004Denominator factors 1.000000000000000 2.100000000000003 4.000000000000012 1.000000000000000 0.600000000000037 0 1.000000000000000 0.399999999999960 0Gain constant 1Thus,The pole-zero plot of it is given below:There are 4 ROCS associated with it:R1:|z|0.4,R2:0.4|z|0.6,R3:0.6|z|2.The inverse z-transform corresponding to the ROC R1 is a left-sided sequence,the inverse z-transform corresponding to the ROC R2 is a two-sided sequence,the inverse z-transform corresponding to the ROC R3is a two-sided sequence,and the inverse z-transform corresponding to the ROC R4 is a right-sided sequence.(分析:此题通过MATLAB实现了传递函数由多项式形式到因式分解形式之间的转换,且由因式分解形式可清楚地看出零极点,进而分析左序列,右序列,双边序列与收敛域的关系)M6.3(a)Type in the residues = 3 -0.8 -7/6Type in the poles = 0 -1/5 -1/6Type in the constants = 0Numerator polynomial coefficients 1.033333333333333 0.733333333333333 0.100000000000000 0Denominator polynomial coefficients 1.000000000000000 0.366666666666667 0.033333333333333 0Hence,(b)Type in the residues
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2025年福建林业职业技术学院公开招聘工作人员23人考前自测高频考点模拟试题(含答案详解)
- 2025广东茂名市电白区霞洞镇公益性岗位招聘2人(第一批)考前自测高频考点模拟试题及一套答案详解
- 2025贵州贵阳观山湖区选聘责任督学10人考试参考试题及答案解析
- 2025教师面试题型及答案
- 2025福建纺织服装福建省高校工程研究中心招聘非事业编制工作人员1人备考考试题库附答案解析
- 2025天津泰达热电能源管理有限公司及所属企业招聘12人考试参考题库及答案解析
- 2025年甘肃省武威市凉州区九墩滩生态建设指挥部选聘专业化管理大学生村文书考试模拟试题及答案解析
- 猎头合同补充协议模板(3篇)
- 2025年电气工程师执业资格考试试题及答案
- 2025年车工技师实操试题及答案
- 2025年西藏公开遴选公务员笔试试题及答案(A类)
- 急性重症胰腺炎个案护理
- 护理敏感质量指标解读2025
- 隧道机电考核管理办法
- 移动学习期刊论文
- 2024小学科学教师职称考试模拟试卷及参考答案
- 农村房产放弃协议书
- 装卸设备安全管理制度
- 做有温度的护理人
- 贵州文物调查研究-从文物看中华民族共同体历史的区域实践知到智慧树章节测试课后答案2024年秋贵州民族大学
- 2024−2025学年高二上学期第一次月考数学试题含答案
评论
0/150
提交评论