Could you please help me know how eig(A), which is inbuild function of matlab, be replaced with Simulink block. Suggest any Tool if required.

2 ビュー (過去 30 日間)
Prachi BHALERAO
Prachi BHALERAO 2021 年 6 月 10 日
回答済み: Manish 2024 年 10 月 18 日
I am working on the project where we need to get the eigen values. Right now it has been implemented as function call shown below:
The requirement is to implement this code in Simulink design.
Could you please help me know how eig(A), which is inbuild function of matlab, be replaced with Simulink block. Suggest any Tool if required.
  1 件のコメント
VIGNESH BALAJI
VIGNESH BALAJI 2023 年 11 月 1 日
Did you find any answer for this ? I am also looking for it. If you find out, please let me know

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

回答 (1 件)

Manish
Manish 2024 年 10 月 18 日
Hi,
I understand that you want to implement ‘eig(A)’ in the Simulink.
In order to achieve this, you can use the ‘MATLAB Function’ block and write the desired code in it.
Here are the steps to implement:
  • Drag and drop the MATLAB Function block into your Simulink model from the Simulink Library Browser.
  • Inside the MATLAB Function block, write a user-defined function called ‘eigen(A)’. This function should calculate the eigenvalues and eigenvectors of the input matrix A using the ‘eig’ function in MATLAB.
  • Connect the input signals to the MATLAB Function block accordingly.
Here is the documentation link for ‘MATLAB Function’ block:
Hope this helps!

カテゴリ

Help Center および File ExchangeModeling についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by