How to use matlab function output variable as a simscape block input variable?

3 ビュー (過去 30 日間)
Youri Miessen
Youri Miessen 2021 年 2 月 25 日
回答済み: Juan Sagarduy 2021 年 2 月 25 日
Hi! I made a matlab function which delivers an output variable "cp". I'm trying to use this output variable as an input variable for a simscape block (Thermal Mass). Is there a way to do this? Can I just write "cp" in the input parameters of the thermal mass block or is there a way to add an extra input to the thermal mass block so that I can connect it with the output of the Matlab function? It is important that the thermal mass block reveives the input from the matlab function during the running of the simulation.

回答 (1 件)

Juan Sagarduy
Juan Sagarduy 2021 年 2 月 25 日
Hi Youri,
You need to create a custom thermal mass where cp is no longer a parameter but an input.
Once you have created this ssc file, the output of the function is connected to the thermal mass input through a Simulink-PS Converter.
Let me know if you need more help.
Regards Juan

カテゴリ

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

製品


リリース

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by