m4ustp.m

来自「Gives all the matlab codes for dynamic s」· M 代码 · 共 20 行

M
20
字号
% M-file for the second part of Project 4 on linearized analysis
%  in Chapter 6 to obtain the unit step response of the motor 
%  transfer function, numG/denG. 
% It can only be used after the transfer function has been
% determined by m4.m, that is numG/denG must be already 
% defined in the MATLAB workspace. 

% M4USTEP.M computes the step response using the step function
% and plots the unit step response of the transfer function
% numG/denG.
% Requires MATLAB Control System Toolbox function step

%
t =[0:0.0005:0.25]; % set up the regularly spaced time points
% Obtain the step response of the transfer function 
[y,x,ti]=step(numG,denG,t); 	% step is a Control System Toolbox
				% function
plot(ti,y);
title('step response of numG/denG')

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?