Re: Compute area between curves [message #62913 is a reply to message #62821] |
Sun, 12 October 2008 18:31   |
frankosuna
Messages: 31 Registered: February 2008
|
Member |
|
|
On Oct 12, 3:17 pm, James Kuyper <jameskuy...@verizon.net> wrote:
> frankosuna wrote:
>> Dear IDLers,
>
>> How can I compute the area between two curves given two functions?
>
> Are the curves closed? That is, do you create the complete curve by
> drawing a line from the final <x,y> pair to the first <x,y> pair?
>
> Are the x values the same for the two curves? Are they evenly spaced?
>
> Note: you don't need to post the same question multiple times, this is a
> newsgroup, not a chat room. Your message will stay up indefinitely. As a
> general rule, you might have to wait 24 hours or more before getting an
> answer.
The curves are not closed... I posted some images of the actual rings
I am trying
to compare. They look like parabolas. The rings might differ in shift
and slight rotation from each other. So because the rings might be
shifted, they probably have different x-values. Also the x-values are
continuous..meaning that once the ring starts.. there is an (x,y)
value until the end of the ring. When I was extracting the (x,y)
location of every pixel that makes up the rings I noticed that a lot
of x values had multiple y's. To fix this I used the MIN x value for
that group in order to be able to compute the area. I'm not sure if
that's bad or good.
I am using INT_TABULATED and TSUM currently and get very close values
for the most part. I compute the area under the curve for both rings
and then subtract but I'm not sure if that is correct either.
Thanks,
Frank
|
|
|