How to draw a tangent line on a step response diagram

26 ビュー (過去 30 日間)
Yubin ZHONG
Yubin ZHONG 2019 年 11 月 27 日
回答済み: Ng 2025 年 11 月 29 日 15:17
微信截图_20191128012715.png
When I get the step response by sisotool like pic 1m how can I get the tangent line and the value of L, T in pic 2?

回答 (2 件)

Samatha Aleti
Samatha Aleti 2020 年 1 月 29 日
You can draw a tangent to a step response curve at a particular point as follows:
sys = tf([8 18 32],[1 6 14 24]); % Transfer function
[y,t] = step(sys); % Step response
plot(t,y);
hold on
slope = diff(y)./diff(t);
k = 100; % To draw tangent at (100)th point
yTangent = (t-t(k))*slope(k)+y(k); % Equation of tangent
plot(t,yTangent);
scatter(t(k),yTangent(k));
hold off

Ng
Ng 2025 年 11 月 29 日 15:17
Based on this Simulink diagram, how to create a graph with a tangential line?

カテゴリ

Help Center および File ExchangeDynamic System Models についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by