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

Best fit MIN/MAX line through data.

  1. May 22, 2008 #1
    Best fit MIN/MAX line through data.


    I’m working with mechanical fatigue test data. Generally this data falls in a logarithmic curve relating load to number of fatigue cycles. This data tends to be somewhat erratic so there need to be a lot of samples at multiple different loads to achieve anything resembling reasonable predictions.

    With that said, the purpose of this fatigue data is to establish a maximum acceptable load/cycle curve rather then a mean load/cycle curve. All of the techniques I can find for establishing best-fit curves specifically work for establishing a mean curve through the center of the data. I want to establish a curve for the minimum least square error where all of the data points are on or ABOVE the line.

    Presently I am doing this by re-distributing the data as load/log(10)cycles so I can work with a straight line, selecting a data point by hand, generating a line through this point parallel to the least square line, calculating the least square error and manually playing with the slope to see if this is reasonable. Then I need to reverse this line back into a Log(10) formula.

    Every time the data changes I need to manually re-adjust everything. Even this is OK but I’m about to get hit with a LOT more data. Does anyone have a better automated way to do this? Are there any simple formulas for minimum or maximum trend lines? I’m out of college too long for this sort of stuff.

    Thanks in advance,
  2. jcsd
  3. May 22, 2008 #2


    User Avatar
    Science Advisor

    Here's a quick idea that I have no idea will work or not. Do the same thing you've been doing creating a mean load/cycle curve. Then discard all points which lie on or below the line. For the rest of the points, subtract the mean from it to determine the "error", or how much it's above the mean.

    Create a line of best fit through this error data, then add to two lines of best fit together.

    edit: This will still leave some points above the max error line. However, if you are a decent programmer, you could write a program which keeps looping over this procedure until a point is reached where the max error is negligible.
    Last edited: May 22, 2008
  4. May 22, 2008 #3


    User Avatar
    Science Advisor
    Gold Member

    You might look into "confidence intervals". They usually relate to levels like 95% (that is, the intervals that enclose 95% of occurences), but I don't see why you couldn't take some canned routine and set it to 100% instead.
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?

Similar Discussions: Best fit MIN/MAX line through data.