Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

% Error for 2 curves

  1. Oct 13, 2015 #1

    joshmccraney

    User Avatar
    Gold Member

    Hi PF!

    Can anyone tell me what you think the best method is to calculate the % error between two curves?

    My thoughts were to take $$100\frac{ \sqrt{\int_a^b (f-g)^2 \, dx}}{\int_s f \, ds}$$

    where the integral in the denominator is a line integral. What are your thoughts? Thanks for looking!
     
  2. jcsd
  3. Oct 13, 2015 #2

    Orodruin

    User Avatar
    Staff Emeritus
    Science Advisor
    Homework Helper
    Gold Member

    It is impossible to answer this question unless you specify what you mean by "% error between two curves".
     
  4. Oct 13, 2015 #3

    joshmccraney

    User Avatar
    Gold Member

    I'm trying to find a good way to see how different two curves are from each other given a domain. I don't want the measure to be domain dependent, where perhaps two curves over a large domain are in fact very close to the same but since the domain is large it may appear as if both graphs are less unrelated than they actually are.

    Does this clarify or am I still being too vague?
     
  5. Oct 13, 2015 #4

    jim mcnamara

    User Avatar

    Staff: Mentor

    Are the data from a normally distributed population? Or 'what are you testing?' -- state your hypothesis and then explain the data sources. As is I cannot help either.
     
  6. Oct 13, 2015 #5

    joshmccraney

    User Avatar
    Gold Member

    I have two curves, call them ##f(x,t)## and ##g(x,t)##. Given some point in time, call it ##t_0##, I want to see how "close" ##f(x,t_0)## and ##g(x,t_0)## are. Whatever scheme is proposed, I am hoping that scheme will account for a growing domain, because as time increases the ##x## domain expands.

    Is this clear, or still poorly described?
     
  7. Oct 13, 2015 #6

    Mark44

    Staff: Mentor

    No, not clear. The graphs of z = f(x, t) and z = g(x, t) are not curves, but are surfaces in three dimensions. If you fix t = ##t_0## you get traces (which are curves) on the two surfaces. Does that agree with what you're thinking?

    I don't understand this part. The domains of f and g are subsets of the plane. How are the domains supposed to be changing?
     
  8. Oct 13, 2015 #7

    joshmccraney

    User Avatar
    Gold Member

    Sorry, this is exactly what I was thinking, but obviously didn't do a great job wording it.

    Sorry again. So as you consider different traces for different values of ##t## the domain in the ##z-x## plane apparently changes.
     
  9. Oct 14, 2015 #8

    Mark44

    Staff: Mentor

    I'm starting to understand your question, which involves level curves or traces on two surfaces. Instead of talking about the "% error" it seems that what you want is the distance between the two curves. At least that's what I infer from the ##(f - g)^2## business in the integral of post #1.It looks sort of like you're trying to find the average distance between the two curves.
     
  10. Oct 14, 2015 #9

    joshmccraney

    User Avatar
    Gold Member

    Yes, the average distance sounds like what I'm looking for. Any ideas? After talking to a friend, I believe the proposition I first posed would only be valid if the traces for ##f## and ##g## share the same concavity (otherwise the line integral in the denominator could be very large).
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook