Linearize and Transfer Function

11 ビュー (過去 30 日間)
Daniel Pérez Gutiérrez
Daniel Pérez Gutiérrez 2023 年 3 月 30 日
編集済み: Paul 2023 年 4 月 3 日
Hi! I want to Linearize a Matlab Function in Simulink and then get its transfer function to control the process.
How can I do that? This is the Simulink model: (The Matlab Function has 13 inputs and 7 outputs)
Thanks in advance!

回答 (1 件)

Paul
Paul 2023 年 4 月 3 日
Does linearize do what you need? It can be used to linearize a model or a specific block in a model. Not sure how well it works on models that contain Matlab Function blocks or on that type of block itself. Might depend on what's actually going on inside the Matlab Function block.
  2 件のコメント
Daniel Pérez Gutiérrez
Daniel Pérez Gutiérrez 2023 年 4 月 3 日
Yes It does, and I'm getting this matrix D of 7 rows and 13 columns:, that I believe it is because of the inputs and outputs of the Matlab Function Block.
With that, how can I get its transfer function?
The Matlab Function has the differential equations of a non-linear model of a yeast bioreactor.
Paul
Paul 2023 年 4 月 3 日
編集済み: Paul 2023 年 4 月 3 日
From the looks of the model, it seems like the block is actually computing the right-hand side of a vector difference equation of the form
x(k+1) = f(x(k),w(k))
and the vector input to the Matlab Function is
u = [w(k);x(k)]
with vector w being the first six inputs of u
If that's the case, then the output of linearize just for that block would be an ss object, call it sys, with sys.A = sys.B = sys.C = 0, and sys.D is the Jacobian of f evaluated at the linearization point. In this case the linearized model would be
x(k+1) = sys.D(:,1:6)*u(k) + sys.D(:,7:13)*x(k).
Therefore, in Matlab an LTI system of that model could be created as
Psys = ss(sys.D(:,7:13),sys.D(:,1:6),eye(7),0,Ts);
Psys assumes that the outputs of the model are x(k). However, the signals going in to Graficas are x(k+1). If x(k+1) is really the desired output, then I think we'd have
Psys = ss(sys.D(:,7:13),sys.D(:,1:6),sys.D(:,7:13),sys.D(:,1:6),Ts);

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeArray and Matrix Mathematics についてさらに検索

製品


リリース

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by