0

I want to write the mathematical equation that represents these data points in the given graph below.

enter image description here

Knowing that this is not a linear regression, I want to continue the solution with $y = ax^2 + bx + c$, but I need to create a matrix-vector form using linear regression from the red line.

What exactly should I try? What is the mathematical equation that represents these data? Could it be about absolute value?

  • I think that quadratic function won’t give a good fit, since your data looks like graph of absolute value. Try transforming data, so it will look more like straight line, and apply linear regression to transformed data. – Yalikesifulei Jan 24 '21 at 16:17
  • Thank you @Yalikesifulei, I know to write absolute value functions in a |x-h| + k form, how can I write it in the form you mentioned? – imageprocessingproblem Jan 24 '21 at 16:23
  • Subtract minimum $y$ value (approx -1 from your picture) from all $y$ values, so new minimum will be 0, and then apply transformation $(x, y) \mapsto (x, -y)$ for points where $x<0$. Transformed data will look like straight line. – Yalikesifulei Jan 24 '21 at 16:54
  • So @Yalikesifulei, I basically had 2 seperate equations to give me two different graphs such as y-1 = a|x| where for x>0, y-1 = ax and for x<0, y-1 = -ax. Should I apply linear regression to both of these seperate equations? – imageprocessingproblem Jan 24 '21 at 17:59
  • No, you have to apply linear regression to transformed data, get some line equation and apply reverse transformation. – Yalikesifulei Jan 24 '21 at 18:28
  • I spent hours on this question @Yalikesifulei and I found the equation for the red line as y=a|x-m| and I also found a=0.1 , b=2.93 and m=0, no matter how hard I tried I still couldn't get the equation that would represent these blue data points. Could you help a little more, please? – imageprocessingproblem Jan 24 '21 at 21:37

0 Answers0