![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/211707/image.jpeg)
Simulink (switch)
조회 수: 2 (최근 30일)
이전 댓글 표시
I built 2 differential equations in Simulink (see attachment). How can I combine both of them using the switch block?
If x>-0.1, the upper one has to be my output and if x<-0.1, the lower one has to be my output.
Thanks in advance
댓글 수: 0
답변 (1개)
Jim Riggs
2019년 4월 2일
편집: Jim Riggs
2019년 4월 2일
This problem may be complicated since you have 2 different definitions of x. However, based on what you asked for, this should work.
The upper signal is passed through whenever f1(x) is greater than -0.1. If f1(x) <= -0.1, the lower signal is passed through.
Note that the switch will always use the value of f1(x) to determine which value to pass.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/211707/image.jpeg)
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!