Extract non zero term from Vector
3 次查看(过去 30 天)
显示 更早的评论
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?
0 个评论
采纳的回答
Guillaume
2017-8-30
编辑:Guillaume
2017-8-30
A quick search for "simulink nonzeros" returns as its first link this find block. If you set the Show output port for nonzero input values to true, then you'll get the nonzeros values.
2 个评论
Guillaume
2017-8-30
As I wrote:
If you set the Show output port for nonzero input values to true, then you'll get the nonzeros values.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Simulink Functions 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!