Simulink Switch doesn't propagate rate transition

4 ビュー (過去 30 日間)
John
John 2023 年 5 月 11 日
コメント済み: Paul 2023 年 6 月 1 日
How can I make a Simulink Switch to propagate rate transition?
Right now I have two signal paths, of variable rates, with the rate determined by some condition:
However, the rest of the chain doesn't work, because the switch doesn't maintain the rate (or so SL thinks)
Also, there isn't a way to have a rate block with an input pin that defines the rate, so I can't adjust the rate via a dynamic input instead.
What's the right way to switch rates while the sim is running?

回答 (1 件)

Fangjun Jiang
Fangjun Jiang 2023 年 5 月 12 日
Not sure what you exactly mean, but a Signal Specification block can specify any rate you want.
  7 件のコメント
John
John 2023 年 5 月 30 日
@Paul "Question: Do these signals derive from the same source signal? If so, what is the sample time of that source signal?"
Yes. That source is continuous-time. The rate transitions are shown in the OP.
"Question: What determines the middle input to the switch, i.e., the selection of the top or bottom signal?"
A separate logic block that computes certain statistics further down the chain (branching off of the output port), and switches based on a threshold.
Paul
Paul 2023 年 6 月 1 日
What is the concern at the output of the switch? That signal as has an FiM sample time, but will still obey the sample time of the selected signal at the times when the output signal from the switch is used, won't it?

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

カテゴリ

Help Center および File ExchangeDiscrete Events and Mode Charts についてさらに検索

製品


リリース

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by