From: Antony on
"Bruno Luong" <b.luong(a)fogale.findmycountry> wrote in message <i210ib$en3$1(a)fred.mathworks.com>...
...
> > Thanks Bruno. Yes, I mean positive values of x. But it seems that LSQNONNEG can not work with constraints.
>
> Not sure what you meant by that, LSQNONNEG specific is designed for this constraint.
>
> >I also have no idea of QUADPROG because it targets the form of min_x{x^T Hx + f^T x}. I need to write the 2-norm style of minimization into this form?
>
> Yes you can write you function as quadratic form.
>
> 1/2 | Ax - b | = 1/2 x'*H*x + g'*x + c
>
> with H = A'*A; g' = b'*A; and c = 1/2*|b|^2 (independent of x). You can do the same with regularization and add them together.
>
> Bruno
Thanks Bruno again for your kind help! I will try what you said on how to apply QUADPROG and hope it works, *-*.

For the problem of LSQNONNEG, as far as I know, it works for Cx=d with contraints x>= 0. But in my problem, additional Tikhonov regularization and gradient regularization are added. How can I apply LSQNONNEG to my problem? I have no idea again and could you please show me how to solve the problem using LSQNONNEG if you know? Thank you very much!

By the way, do you know whether there is a MATLAB software or code specified for such non-linear optimization problem? Thanks again!

Antony
From: Bruno Luong on
"Antony " <mutang.bing(a)gmail.com> wrote in message <i215mb$1qt$1(a)fred.mathworks.com>...
> "Bruno Luong" <b.luong(a)fogale.findmycountry> wrote in message <i210ib$en3$1(a)fred.mathworks.com>...

>
> For the problem of LSQNONNEG, as far as I know, it works for Cx=d with contraints x>= 0. But in my problem, additional Tikhonov regularization and gradient regularization are added. How can I apply LSQNONNEG to my problem? I have no idea again and could you please show me how to solve the problem using LSQNONNEG if you know? Thank you very much!

No, the Tikhonov shoult not be considered as constraints, they are penalty/penalization term.

When you minimize
|Ax - b|^2 + lambda | x |^2, you actually transform the system to a linear least-squares problem:

C*x = d, with
C = [A; sqrt(lambda)*eye(n)];
d = [b; zeros(n,1)];
where n is the dimension of x.

So you can use lsqnonneg on C and d to enforce x>=0.

I let you adapt the gradient penalty term.

>
> By the way, do you know whether there is a MATLAB software or code specified for such non-linear optimization problem? Thanks again!
>

Sorry I do know but rarely use them so I can't recommend, I usually write my own code.

Bruno
From: Antony on
"Bruno Luong" <b.luong(a)fogale.findmycountry> wrote in message <i210ib$en3$1(a)fred.mathworks.com>...
....
> > Thanks Bruno. Yes, I mean positive values of x. But it seems that LSQNONNEG can not work with constraints.
>
> Not sure what you meant by that, LSQNONNEG specific is designed for this constraint.
>
> >I also have no idea of QUADPROG because it targets the form of min_x{x^T Hx + f^T x}. I need to write the 2-norm style of minimization into this form?
>
> Yes you can write you function as quadratic form.
>
> 1/2 | Ax - b | = 1/2 x'*H*x + g'*x + c
>
> with H = A'*A; g' = b'*A; and c = 1/2*|b|^2 (independent of x). You can do the same with regularization and add them together.
>
> Bruno

Sorry, Bruno, I have more questions when applying QUADPROG. If my constraints are ||x||^0.8 and ||gradient(x)||^2, how to write them as quadratic forms? I feel it is hard to write them into quadratic form. In this case, I may need other optimization tools.

Thank you very much!

Antony
From: Bruno Luong on
"Antony " <mutang.bing(a)gmail.com> wrote in message <i217a1$c5a$1(a)fred.mathworks.com>...
> "Bruno Luong" <b.luong(a)fogale.findmycountry> wrote in message <i210ib$en3$1(a)fred.mathworks.com>...
> ...
> > > Thanks Bruno. Yes, I mean positive values of x. But it seems that LSQNONNEG can not work with constraints.
> >
> > Not sure what you meant by that, LSQNONNEG specific is designed for this constraint.
> >
> > >I also have no idea of QUADPROG because it targets the form of min_x{x^T Hx + f^T x}. I need to write the 2-norm style of minimization into this form?
> >
> > Yes you can write you function as quadratic form.
> >
> > 1/2 | Ax - b | = 1/2 x'*H*x + g'*x + c
> >
> > with H = A'*A; g' = b'*A; and c = 1/2*|b|^2 (independent of x). You can do the same with regularization and add them together.
> >
> > Bruno
>
> Sorry, Bruno, I have more questions when applying QUADPROG. If my constraints are ||x||^0.8 and ||gradient(x)||^2, how to write them as quadratic forms? I feel it is hard to write them into quadratic form. In this case, I may need other optimization tools.
>

Minimizing ||x||^0.8 is non linear and yes, you do need non-linear optimization tool.

Bruno
From: Bruno Luong on
>
> Minimizing ||x||^0.8 is non linear and yes, you do need non-linear optimization tool.

Btw ||x||^0.8 is not differentiable and it's not convex. This is nasty for the minimizer.

Bruno