mobook / MO-book

Hands-On Optimization with Python
https://mobook.github.io/MO-book/
MIT License
162 stars 47 forks source link

Lingering issues in fit-absolute.ipynb #8

Closed alessandrozocca closed 2 years ago

alessandrozocca commented 2 years ago

Lingering issues in fit-absolute.ipynb:

jckantor commented 2 years ago

I changed the name of the file to lad-regression to reflect the new title and additional content. I cut and pasted the example text from the book, with some edits for markdown. I added a histogram of residuals to provide some visualization for the multivariable case. Should be ready to close.

jckantor commented 2 years ago

Closing this one. Feel free to reopen if there are issues.

alessandrozocca commented 2 years ago

Reopened this due to two minor issues, see top post.

jckantor commented 2 years ago

Good catches. I've fixed the math format issue, and replaced the problem sentence with "In general, the appearance of an absolute value term indicates the problem is nonlinear and, worse, that the objective function is not differentiable when any 𝑒𝑖=0 . However, for this case where the objective is to minimize a sum of absolute errors, one can reformulate the decision variables to transform this into a linear problem. "

alessandrozocca commented 2 years ago

Perfect, I close this now.