While using default medain function in simulink for calculating median i am facing overflow design error . Why is it so ?
1 view (last 30 days)
Show older comments
I have used a matlab function block in simulink for calculating median. It is simple function defined as below
function y = medianC(u)
y = median(u);
Now using sldv I am trying to find design errors then i am facing overflow error. Why is it so ?
0 Comments
Answers (1)
Akshat Dalal
on 21 Mar 2025
Hi Poorna,
I believe since SLDV is a static analysis tool, it does not analyse the possible value of the input 'u' unless you explicitly specify it. Thus, it considers that the median can potentially large values which will cause overflow. If that's not the case, you need to explicity specify the bounds for your inputs after which the overflow design error should get removed.
Thanks,
Akshat.
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!