Clear Filters
Clear Filters

levenberg-marquardt with linear constraints

9 views (last 30 days)
Eze Far
Eze Far on 8 Aug 2023
Commented: Eze Far on 8 Aug 2023
Hi, I just see the the box constraints are now allowed for the levenberg-marquardt algorithm in lsqnonlin. However it seems that linear constraints are still not implemented. Is that correct? Are there any plans to implement that in future realeases?
Cheers
  6 Comments
Bruno Luong
Bruno Luong on 8 Aug 2023
Edited: Bruno Luong on 8 Aug 2023
AFAIK (As Far As I Know) it is not trivial to introduce constraints in LM algorithm. There are few papers on the topic but probably not mature enough to be implemented at the presence time.
Eze Far
Eze Far on 8 Aug 2023
ok I see. Thanks for the answer. Cheers

Sign in to comment.

Answers (2)

Torsten
Torsten on 8 Aug 2023
Edited: Torsten on 8 Aug 2023
A,b,Aeq,beq define the linear constraints.
  1 Comment
Eze Far
Eze Far on 8 Aug 2023
Yes, that's what I thought, but in https://nl.mathworks.com/help/optim/ug/lsqnonlin.html one can read:
"The 'interior-point' algorithm is the only algorithm that can solve problems with linear or nonlinear constraints. If you include these constraints in your problem and do not specify an algorithm, the solver automatically switches to the 'interior-point' algorithm."
I also tried myself and it switches automatically to interior-point when the linear constraints are enabled. That doesn't happen when only box constraints are set.

Sign in to comment.


John D'Errico
John D'Errico on 8 Aug 2023
Edited: John D'Errico on 8 Aug 2023
I'm sorry, but nobody can tell you IF there are any plans to introduce some behavior in a future release, until it is released.
If someone does know, then they will be under a non-disclosure agreement. If they don't know, well what do you expect them to be able to tell you?
At best, you can submit a feature request to MathWorks. DIRECTLY TO THEM, NOT THROUGH ANSWERS. Answers is not technical support. Ask for this feature to be included in a future release. Remember that TMW will generally not write code that nobody ever wants or hopes to use. Instead, they will direct their efforts at things for which people have shown a need.
The nice thing is, I have always found them to be responsive to reasonable requests. In fact, if they do add the idea as a feature request, they will also attach your e-mail to it, so when it does come alive, you will be notified directly.
  3 Comments
John D'Errico
John D'Errico on 8 Aug 2023
Edited: John D'Errico on 8 Aug 2023
Geez, RELAX!
  1. TMW employees will be under an NDA. How can you not expect that?
  2. I put it in caps, since far too many people seem to think Answers is indeed official tech support, so I wanted to make that part clear, drawing explicit attention to it. I could have made it bold face or italicized it instead. Would that seriously have made you happier? Really? Did my use of caps truly upset you? relax. relax. Do those make you happier?
  3. I did not say that nobody will need that option, only that they may not have decided to expend the effort to add that option to the LM codes. Mybe they did not think it was necessary. Remember that every hour spent on one option is an hour not invested in development of other tools. And since they only have so many employees, this is a tradeoff they must always make. If they already offered a capability under one sub-optimizer in lsqnonlin, I can easily understand they might have chosen not to put it into all sub-optimzers in lsqnonlin. Honestly, it has been too many years since I worked seriously with Levenberg-Marquardt and writing optimization codes, that I don't know if there may be some explicit reason why they did not put it into the LM code. That they did not is a suggestion there was some reason not to do so, if it were easy.
Please develop a thicker skin, and don't get all upset when someone gives you some information that you clearly needed. As for your advice, I don't give a tinker's damn. In fact, I felt I was being quite reasonably polite. My feelings towards you are not so much anymore, but I doubt you care anymore than I care about yours. The fact is, you obviously learned several things from my response.

Sign in to comment.

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Products


Release

R2023a

Community Treasure Hunt

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

Start Hunting!