YALMIP have some issue sending plog to global solver

38 views
Skip to first unread message

JackJack

unread,
Oct 22, 2025, 10:46:47 PMOct 22
to YALMIP
Dear Professor Johan 

This program cannot work with Baron, but it can work well with bmibnb.

x = sdpvar(1);
y = sdpvar(1);
t = sdpvar(1);
obj = -t;
cons = [];
cons = [cons, 100 <= x <= 200];
cons = [cons, 300 <= y <= 400];
cons = [cons, t <= plog(y, x + y)];
optsB = sdpsettings('solver','baron', ...
'verbose',1, ...
'savesolveroutput',1, ...
'savesolverinput',0);
tic;
solB = optimize(cons, obj, optsB); The error is as follows: Optimization Status: 9 (Unknown problem (learn to debug) (Unknown problem (learn to debug) (Error using baron
There was an error evaluating a user supplied function. Please examine the below error and correct your function.

Error using "plog" (line 55)
PLOG called with weird argument

Error Trace:
- Error in "@(x)[1*x(3)-plog(x(4))]" (line 0)
- Error in "baron" (line 0)
- Error in "baron" (line 0)
- Error in "baron" (line 0)
- Error in "callbaron" (line 78)
- Error in "solvesdp" (line 423)
- Error in "optimize" (line 31)
- Error in "your_program" (line 100)
)))


Is there any way to overcome this?

Johan Löfberg

unread,
Oct 28, 2025, 2:50:30 AMOct 28
to YALMIP
Right, I will have to clean away those. Until then, simply don't use plog but write the function explicitly. I've raised a bug to remember

Johan Löfberg

unread,
Oct 29, 2025, 8:00:45 AMOct 29
to YALMIP
Fixed in develop

On Thursday, 23 October 2025 at 04:46:47 UTC+2 JackJack wrote:

JackJack

unread,
Oct 30, 2025, 2:35:12 AMOct 30
to YALMIP
I hope that this fix also fix the problem with the following 

  1. exppexp
  2. loglog2log10slogplog
  3. entropylogsumexpkullbackleibler

Johan Löfberg

unread,
Oct 30, 2025, 3:24:26 AMOct 30
to YALMIP
kullbackleibler and crossentropy added (not tested though as my license was broken)
Reply all
Reply to author
Forward
0 new messages