Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have function looks like this:

enter image description here

So, the point is after it comes to steady state, it slowly goes down. How can I describe such a behaviour?

The datapoints are:

x        y
1        10
2        60
3        72
4        70
5        69,8
6        69,6
7        69,4
8        69,2
9        69
10        68,8
11        68,6
12        68,4
13        68,2
14        68
15        67,8
16        67,6
share|cite|improve this question
up vote 3 down vote accepted

I don't think there's a one-word name for such a situation.

Depending on exactly what you want to do with the data when you are done, you might be looking for Segmented (Piecewise) Regression. It is clear that after a "breakpoint" in your model1, you experience completely linear behavior ($x > 3$). The first part looks quadratic.

Let's split our database into two separate lists:

    1        10
    2        60
    3        72

    4         70
    5         69,8
    6         69,6
    7         69,4
    8         69,2
    9         69
    10        68,8
    11        68,6
    12        68,4
    13        68,2
    14        68
    15        67,8
    16        67,6

Run regression on the first data set, receiving $f_1(x) = -19x^2 + 107x - 78$.

Run regression on the second data set, receiving $f_2(x) = -0.2x + 70.8$.

Now create the piecewise function: $$ f(x) = \left\{ \begin{array}{lr} -19x^2 + 107x - 78 & (x \le 3)\\ -0.2x + 70.8 & (x > 3)\\ \end{array} \right. $$

Perhaps we want such a function to be continuous. If you want, you can set the two function equal to each other, and you will find they intersect2 at $3 \le \dfrac{268+2\sqrt{286}}{95} \approx 3.17708 \le 4 $. So you could write: $$ f(x) = \left\{ \begin{array}{lr} -19x^2 + 107x - 78 & (x \le 3.17708)\\ -0.2x + 70.8 & (x > 3.17708)\\ \end{array} \right. $$

Now your function is continuous as well.

I would definitely recommend the piecewise regression method, but by using symbolic regression and the software Eureqa, I was able to find a quite interesting formula:

$$ 70.8 \cdot \mathrm{logistic}(3.541x - 5.323) - 0.2x $$

Where $\mathrm{logistic}(x) = \dfrac{1}{1 + e^{-x}}$, which is a quite common function, so you should have no trouble describing it.

If I was describing it to a friend, I would probably say "a logistic function followed by a linear decrease" or perhaps "a logistic function".

Some stats:

  • $ R^2 \approx 0.999 $
  • Maximum error at $x=3$ with $\approx 2.151$
  • $\mathrm{MSE} \approx 0.309 $

1 There are varying algorithms for determining breakpoints, one such algorithm is listed briefly here.

2 Is this allowed? Will this always be the case? Perhaps an algorithmic approach would be better.

share|cite|improve this answer
Thank you for such detailed solution! It is quite simple and easy-to-use, so, I guess it is the best way to solve the problem. But I was actually wondering whether it is possible to describe it using just one equation. I'm just curious, are there any techniques to build one equation from the system of equations? – Igor Jan 3 '13 at 8:08
@Igor, I tried to run symbolic regression on it (guess regression type using genetic programming), but I was unable to come up with anything useful. I'll try a longer run later and get back to you, but I would seriously doubt it. Therefore I think it is unlikely that there is a way to make it one equation, short of the Iverson Bracket (which is kind of cheating). – George V. Williams Jan 3 '13 at 22:32
thank you very much! If you will find anything promising, please let me know. Actually I'm also interested in genetic programming, therefore your information is going to be quite useful for me! – Igor Jan 3 '13 at 22:44
@Igor, I ran my symbolic regression test using Eureqa, which is quite a useful piece of software for symbolic regression (I tried using my own software, but the results were horrendous). Regardless, it looks like what you are looking for is a logistic function with some slight modifications. I'll update my answer to show this new function. – George V. Williams Jan 4 '13 at 0:08
@George-V-Williams, that is wonderful! I appreciate your help. This is what I was looking for. And thank you for the links - they will be useful for me! – Igor Jan 4 '13 at 9:09

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.