📄 u2.m
字号:
function u2
%%%%%%%%%%%% 创建图形框 %%%%%%%%%
h_figure=figure('Units' , 'characters' ,...
'position',[5 5 180 40]);
%%%%%%%%%%%% 创建坐标 %%%%%%%%%%%
h_axes1=subplot(231);
set(gca,'box','on','xlim',[0 2],'ylim',[0 2]);
h_axes2=subplot(232);
set(gca,'box','on','xlim',[0 2],'ylim',[0 2]);
h_axes3=subplot(233);
set(gca,'box','on','xlim',[0 2],'ylim',[0 2]);
%%%%%%%%%%%%%%%% 控制按钮 %%%%%%%%%%%%%%
h_frame1=uicontrol(h_figure, 'style' , 'frame' ,...
'Units' , 'characters' ,...
'position' ,[63,3.5,58,15], ...
'horizontal' , 'center' ,...
'fontsize' ,10,...
'backgroundcolor',[0.5 0.5 0.5],....
'ForegroundColor','black');
h_text=uicontrol(h_figure, 'style' , 'text' , ...
'Units' , 'characters' ,...
'position' ,[70,6,4,9], ...
'string' ,' 控制按钮', 'fontsize' ,12);
h_push1=uicontrol(h_figure, 'style' , 'push' , ...
'Units' , 'characters' ,...
'position' ,[82 14 20 3], ...
'string' , '去循环前缀' ,...
'backgroundcolor',[0.8 0.8 0.8], 'callback' , [...
'run;',...
'subplot(231),stem(h),hold on,ylabel(''cyclic pad removed''),title(''去循环前缀''),grid on,axis([0 300 -0.1 0.1]);',...
'hold off'] );
h_push2=uicontrol(h_figure, 'style' , 'push' , ...
'Units' , 'characters' ,...
'position' ,[82 10 20 3], ...
'string' , '接收端的16-QAM星座图' ,...
'backgroundcolor',[0.8 0.8 0.8], 'callback' , [...
'run;',...
'subplot(232),plot(real(o),imag(o),''*r''),hold,plot(real(M(:,length(M(1,:)))),imag(M(:,length(M(1,:)))),''.b''),title(''接收端的16-QAM星座图''),grid,axis([-1.5 1.5 -1.5 1.5]);',...
'hold off'] );
h_push3=uicontrol(h_figure, 'style' , 'push' , ...
'Units' , 'characters' ,...
'position' ,[82 6 20 3], ...
'string' , '接收到的输出序列' ,...
'backgroundcolor',[0.8 0.8 0.8], 'callback' , [...
'run;',...
'subplot(233),stem(q);ylabel(''received/quantized speech''),axis([1 60 -1 2]),hold on,grid on,title(''接收到的输出序列'');',...
'hold off,'] );
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -