One of the systems I want to control with PID is the state space equation with disturbances. Can someone help me to design matlab function of the system? Please

16 次查看(过去 30 天)
I have given the space state parameters I want to use below. Can you help design and control this matlab function with PID?
  3 个评论
veysel burçak
veysel burçak 2023-8-9
Thank you for your answer. I designed a controller by converting space state equaition to transfer function. However, since the transfer function gets initial condition 0, the graph does not give the correct result, the graph value does not start from 300, even though I set the step input, so I have to write this function. @Paul @Sam Chak
function [y,x_out] = fcn(x,u,d)
ny=1;
nx=2;
y = zeros(ny,1);
x = zeros(nx,1);
A=[-0.00446566 0.00445684; 0.00515227 -5.15227];
B=[0.00316315;0];
E=[0.00292761 0;0 -2.0315.10^(-8)]
C=[1;0];
x_out = A*x+B*u+E*d;
y = C*x;
veysel burçak
veysel burçak 2023-8-9
Before attempting to solve the identification problem, we first performed sensitivity estimations with respect to the unknown model parameters (CpW and KW ) and the disturbance variables TI and Wloss by using the known and roughly estimated model parameters as nominal values.
During the measurements, the disturbance variable TI was measurable and constant and the cold water inlet flow rate m was constant. Furthermore, it was assumed that the environmental heat loss Wloss of the system was constant (which is an acceptable approximation of reality, since the outside temperature during the measurements was approximately constant and the temperature variation within the pressurizer was small).
Can you check disturbances vector from this paper please; https://www.sciencedirect.com/science/article/pii/S1474667015353416 @Sam Chak @Paul

请先登录,再进行评论。

采纳的回答

Sam Chak
Sam Chak 2023-8-9
I have fixed the code in the MATLAB Function block. The initial condition is assigned in the Integrator block. It should be working correctly now.
function dx = fcn(w, u, x)
A = [-4.46566e-3 4.45684e-3;
5.15227e-3 -5.15227e-3];
B = [ 3.16315e-3;
0];
E = [ 2.92761e-3 0;
0 -2.03150e-8];
dx = A*x + B*u + E*w;
  5 个评论
veysel burçak
veysel burçak 2023-8-10
Even though I change the parameters, the result does not change. I want the value to remain constant until the 20th second. From 20 to 25 it should be 305. I want to produce a better result than PID control. Thank you. An Bn En are mutable values. I need to produce a better result by changing the KSC and lambda @Sam Chak
Sam Chak
Sam Chak 2023-8-10
I have examined the .slx file and identified some issues with the design methodology. However, I'm not familiar with handling mismatched disturbances. Moreover, no stability proof is provided to demonstrate that the proposed sliding mode controller can effectively track the reference input. If the existing PI controller can solve the tracking problem, perhaps you can apply some modifications to it.
Currently, I don't have a solution for the control design. Therefore, I recommend that you post a new question, and hopefully, experts in the field can offer guidance.

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 PID Controller Tuning 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by