The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Area under the curve
Replies: 9   Last Post: Nov 29, 2011 5:47 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]

Posts: 16
Registered: 11/18/11
Re: Area under the curve
Posted: Nov 18, 2011 5:12 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

> Dear Claudio,
> Thank you very much for your reply. I would like to know what does 's' means in the line 'peak_value = max( u_abs( pos - 0.5s : pos + 0.5s) )'
> I use Embedded Matlab function block in Simulink so I am trying to figure out how I can implement in it. I see that you have used Matlab code to explain the procedure.
> Prashant

Hi Prashant,

That line searches maximum near the position "pos" of the threshold. I wrote +/- 0.5s because it looks like your peaks are about 1 second wide; you should optimize it for your data.
"s" just stand for "seconds": you should replace 0.5s with the corresponding number of samples (I don't know what sampling frequency you are using)

However I have never used Simulink, so I am not sure on how you could implement it in the Embedded Matlab block, sorry! However, this seems like a good starting point:


Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.