How to load matrix variables as constant on Simulink?

44 ビュー (過去 30 日間)
관웅 윤
관웅 윤 2021 年 8 月 26 日
コメント済み: 관웅 윤 2021 年 8 月 31 日
I am trying to load matrix variables on simulink as constant value from '.mat' file. Is it possible to load MATLAB variables on Simulink and use it as constant block value? All variables are N-d array. I found that there are several ways to load a variable on Simulink such as "From File Block" or "Input Port", but It did not work for my project.

採用された回答

Jonas
Jonas 2021 年 8 月 26 日
Load the .mat file into the Base Workspace of MATLAB, and in Simulink use the From Workspace block to enter the variable name there.
  3 件のコメント
관웅 윤
관웅 윤 2021 年 8 月 31 日
Wow, It works well. Thank you!!

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

その他の回答 (0 件)

製品


リリース

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by