Units for Time in Simulink

63 ビュー (過去 30 日間)
Walter Franklin
Walter Franklin 2020 年 12 月 3 日
回答済み: Giampiero Campa 2021 年 10 月 29 日
For a continuous model what sets the time(scale?) in a simulink model?
As an example for openExample('simulink_general/sldemo_househeatExample') the scope x axis units are in hours. What sets that?
I know this is likely a trivial question, but my real aplication is to model transients in a physical thermal system without simscape. So far, the only way I have been able to match my hand calculated estimates using (with Q being the energy input each second) has been to use a descrete solver with a timestep of 1s but I know that I am going about things the wrong way.
Thank you for any guidence you can provide!

採用された回答

Jonas
Jonas 2020 年 12 月 3 日
編集済み: Jonas 2020 年 12 月 3 日
Simulation time is always seconds.
In this particular model, they just adjusted the parameters (like heat power) such that 1 second corresponds with 1 hour. For the Heater, I see they multiply the parameter c with 3600. Also, they multiply the heat losses through the windows of the house with 3600. This way, every second the heat corresponding with one hour is generated. The x-axis can then be regarded as being in hours.
Otherwise the simulation would take way too long and would need to run 24*60*60 = 86400 seconds for it to finish just 24 hours. Now it finishes in just 24 seconds.
  2 件のコメント
Walter Franklin
Walter Franklin 2020 年 12 月 3 日
Thank you!
Steven Lord
Steven Lord 2020 年 12 月 3 日
So "by the book" seconds could seem like hours. Regulation 46A.

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

その他の回答 (1 件)

Giampiero Campa
Giampiero Campa 2021 年 10 月 29 日
It is not seconds, it's an "unit of time" that you can relate to time units how you want, depending on your application. See also this: https://stackoverflow.com/questions/18650928/can-simulation-stop-time-in-simulink-be-compared-with-real-time

カテゴリ

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

製品


リリース

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by