Looking for a metric to express difference between two curves

Click For Summary

Discussion Overview

The discussion revolves around finding a metric to quantify the difference between two curves, specifically an ellipse and an interpolated curve representing a discontinuity in a material. Participants explore various mathematical approaches and metrics, including concepts from Riemannian geometry and integral calculus, to express this difference effectively.

Discussion Character

  • Exploratory
  • Mathematical reasoning
  • Debate/contested

Main Points Raised

  • One participant suggests using the formula \(\frac{Area_{actual} - Area_{ellipse}}{Area_{actual}}\) to measure the difference, but notes its limitations in conveying how closely the curves match.
  • Another participant proposes a method involving the areas of the interiors of the curves, defined as \((X\setminus Y) \cup (Y\setminus X)\), as a potential metric.
  • A different approach is introduced, suggesting the use of polar coordinates and the integral \(\int_{\theta_1}^{\theta_2} (r_{ellipse} - r_{interp})^2 d\theta\) to quantify the difference between the curves.
  • A participant mentions using "Dodo's equation" and references "interpolation error" to measure the deviation between the curves as the square of the distance difference.
  • There is a clarification regarding the purpose of Dodo's formula, with a participant asserting it is meant for a continuous sum of squares rather than calculating the area between the curves.
  • Another participant expresses a preference for established metrics from the literature over self-defined metrics, while acknowledging the potential effectiveness of the area formula discussed earlier.

Areas of Agreement / Disagreement

Participants present multiple competing views on how to quantify the difference between the curves, with no consensus reached on a single method. Various approaches are debated and refined throughout the discussion.

Contextual Notes

Some participants express uncertainty about transitioning from set-based definitions to actual equations. Additionally, there are unresolved aspects regarding the integration limits and the specific forms of the curves in polar coordinates.

meldraft
Messages
280
Reaction score
2
Hi all,

I am trying to argue that an ellipse is a good approximation for some discontinuity in a material. The ellipse and the interpolated curve I get from the photo look very much alike, but I need an actual number to show how much the two curves differ from each other. I thought of

[tex]\frac{Area_{actual} - Area_{ellipse}}{Area_{actual}}[/tex]

but it doesn't really give any information about how much the curves match (a square with the same area as the ellipse would give 0 deviation).

I'm kind of new to Riemannian geometry, but I thought that maybe I could use the Riemann curvature tensor, although I don't really know how to do it yet :P . I would appreciate any suggestions you are able to give!
 
Physics news on Phys.org
Here is a possibility:

Let X be the interior of the first curve and let Y be the interior of the second curve. Then you can make

[tex](X\setminus Y) \cup (Y\setminus X)[/tex]

The area of that should be a good (pseudo)metric to describe what you want.
 
If the curves can be expressed in polar form [itex](r(\theta), \theta)[/itex], perhaps using as origin of coordinates the center of your suggested ellipse, then maybe you could use
[tex]\int_{\theta_1}^{\theta_2} (r_{ellipse} - r_{interp})^2 d\theta[/tex]
(Am I making sense?)
 
Thank you both for your answers!

Micromass, I really like your suggestion, but I had trouble going from sets to actual equations.

The solution I used eventually was Dodo's equation: I also looked up "interpolation error".

http://en.wikipedia.org/wiki/Interpolation

There, the deviation of one curve from the other is measured as the square of the distance difference (just as in Dodo's equation).
 
Just a correction: Dodo if I'm not mistaken, your formula is meant to calculate the area between the curves correct? If so, shouldn't it be:

[tex]|\int_0^{2 \pi}{(r_1(θ)^2-r_2(θ)^2)}{dθ}|[/tex]
 
Hi, Meldraft, sorry for the delay, I was travelling.

The formula was not intended to calculate the area in-between. I was intended to be a continuous sum (an integral) of squares... just as when you add the squares of residuals after you fit a curve to data. (I couldn't avoid the multiplication by a delta-angle... but I'm open to suggestions.) Hope this makes some sense now.

Edit: [itex]\theta_1[/itex] and [itex]\theta_2[/itex] are supposed to be the initial and final "sweep angle". Your approximation as an arc of ellipse, when written in polar form, has, as any arc of ellipse, an initial angle and an ending angle. presumably the interpolated curve, if it can be expressed in polar coordinates from the ellipse's center, is also some form of strange arc, with an initial and a final sweep angle.
 
Last edited:
Ohhh, so you meant like RSS?

Both my curves are closed, since I'm describing a physical hole, so if I understand correctly, I could use:

theta1 = 0, theta2 = 2*pi

I haven't really used this, I'm just familiar with the term, so I'll have to look into it. The area formula (which I am now realising has essentially been micromass' suggestion all along :P) seems to be yielding good results, although I'm a little hesitant on including a self-defined metric. I'd rather use something that is in the literature.

Thank you for your feedback! I'll let you know how it works out!
 

Similar threads

  • · Replies 6 ·
Replies
6
Views
4K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 15 ·
Replies
15
Views
2K
  • · Replies 2 ·
Replies
2
Views
1K
Replies
7
Views
3K
  • · Replies 16 ·
Replies
16
Views
3K
  • · Replies 6 ·
Replies
6
Views
4K
  • · Replies 8 ·
Replies
8
Views
4K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K