Extract non zero term from Vector
古いコメントを表示
Hello, I have a 1 x 9 vector which contains all zeroes apart from one element which will take a +ve or -ve number, it's index will change, how do i extract this non zero number in Simulink? Is there a block for it?
採用された回答
その他の回答 (2 件)
Use it in a Matlab function block?
5 件のコメント
KL
2017 年 8 月 30 日
So fast. Just about when it hit me and came back here to edit :D
Zhenteng Shen
2017 年 8 月 30 日
KL
2017 年 8 月 30 日
You really can do this in Simulink. Check
Zhenteng Shen
2017 年 8 月 30 日
Omur Bas
2017 年 8 月 31 日
0 投票
If all the other elements are zero, and you don't need the index, then Sum of Elements block would do the trick.
カテゴリ
ヘルプ センター および File Exchange で General Applications についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!