Alternative to nested Memory blocks for keep track of previous N samples

1 次查看(过去 30 天)
Hi everyone!
I need to calculate the ONLINE windowed median of a signal in Simulink. Let's say that I want to perform the median in a window of 50 samples. 50 nested Memory block is not a good idea :)
To be more specific, right now, I have a MATLAB Function that calculates something like
x(k) = f(u(k))
I want to extend this operation by keeping track of the x and use the last N samples recursively to calculate a windowed median. Something like
x_m(k) = f(x(k), x(k-1), ... , x(k-N))
I don't have any Statistic Toolbox that contain some blocks that do what I want, so any other suggestion?

回答(0 个)

类别

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

Community Treasure Hunt

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

Start Hunting!

Translated by