- State-Space block: to represent the PMDC motor model (with Matrices A,B,C,D)
- Gain block: to represent the LQR gain (K) , this is computed previously
- Sum block: to compute the control input
- Scope block: to visualize the output
- Step block: for the input voltage
DC 모터에서 전류 제어를 LQR 제어기로 하고싶은데 simulink를 어떻게 만들어야 하나요?
2 ビュー (過去 30 日間)
古いコメントを表示
현재 PMDC까지는 구현을 했고 전류 컨트롤러에서 PID로 하는 방법은 알겠는데 LQR을 어떻게 하는 지 모르겠네요,,,
0 件のコメント
回答 (1 件)
Amish
2024 年 8 月 6 日
Hi 주환 엄,
You can use MATLAB to compute the "LQR gain matrix" (K). The LQR controller minimizes a cost function of the form:
where "Q" and "R" are user-defined weight matrices that penalize the state and control input, respectively. This can be solved using MATLAB as follows:
% Define the state-space matrices
% Your A,B,C,D matrices
A = [..];
B = [..];
C = [..];
D = [..];
% Define the weight matrices
Q = [..];
R = [..];
K = lqr(A, B, Q, R); % Compute the LQR gain
This can then be implemented in Simulink with the help of various blocks. You will need the following:
You can then set your required parameters and run the Simulation.
For more information you can refer to the following documentation:
Hope this helps!
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で 빅 데이터 처리 についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!