Simulink Multiport switches with value ranges as inputs?

6 次查看(过去 30 天)
Hello, I have three signals that each correspond to a certain value range. For example:
Signal 1: input value <350
Signal 2: 350<= input value < 500
Signal 3: 500 <= input value
I would like to implement this with a multiport switch block, is this possible? I am currently using two relational operator blocks and two switches, and I feel that there should be a better way to do this. Any help would be appreciated!

采纳的回答

Pranjal Kaura
Pranjal Kaura 2021-11-22
Hey Cory,
You can use the MATLAB funcion block, in which you can specify mutiple conditonal statements.
You can also use the 'If' block, paired with the 'If Action Subsystem' block.
Hope this helps!
  2 个评论
Cory Dinkle
Cory Dinkle 2021-11-22
Thank you. This is helpful, but I suppose I was hoping that there was a block to do this. It seems to me that this should be possible with a Switch block, as remaining within an upper and lower bounds is often a criteria for code.
Pranjal Kaura
Pranjal Kaura 2021-11-24
Thank you for bringing this up Cory. I have brought this issue to the notice of our developers. They will investigate the matter further.

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Simulink 的更多信息

产品


版本

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by