L1 minimisation for a specific function

10 visualizzazioni (ultimi 30 giorni)
shaon0
shaon0 il 5 Giu 2013
Hi, I'm trying to code up the following linear program:
min norm(f(x)-d,1)
So essentially, I'm just trying to minimise the 1-norm of a function, f(x) minus the actual data, y. I've seen online that this problem can be reduced to:
min sum(i=1 to n) g(x[i]) s.t g(x[i])>=f(x[i])-d[i] and -g(x[i])>=f(x[i])-d[i]
So it reduces to a linear program. I'm very new to matlab and I know how to write out the function f(x), I can load the data d vector. But I'm not sure how I would be able to write the linear program in matlab.
Is there a sample code that anyone could provide?
Thank you in advanced.
  1 Commento
Matt J
Matt J il 5 Giu 2013
Modificato: Matt J il 5 Giu 2013
The reformulation you show is the right idea, but I don't know why you would have g(x[i]). I think you would just have new variables g(i) independent of x and you would minimize over the combined parameter vector [x;g]. Also, it's not a linear program unless f(x) is linear, because otherwise the constraints are still nonlinear with respect to x. Are you saying that your f(x) is linear?

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Creating and Concatenating Matrices in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by