How to get the cell number with the maximum value of a vector with Simulink

조회 수: 2 (최근 30일)
Hello everybody!
I am trying to get the number of the cell with the maximum value of a vector.
I know to do this in matlab using the command [value, cell_number] = max(vector(1,:)).
I need the "cell_number" value.
How to get it in Simulink?
Many thanks, Daniel.

채택된 답변

Pedro Villena
Pedro Villena 2012년 11월 5일
편집: Pedro Villena 2012년 11월 14일
Convert virtual bus to vector.
Simulink >> Signal Atributes >> Bus to Vector Block
Find maximum values in input or sequence of inputs http://www.mathworks.es/es/help/dsp/ref/maximum.html
DSP System Toolbox >> Stadistics >> Maximum Block

추가 답변 (1개)

Dani Tormo
Dani Tormo 2012년 11월 5일
Thanks man! I couldn't find this box.

카테고리

Help CenterFile Exchange에서 Signal Generation에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by