Iteration info is not displaying in Matlab

33 views
Skip to first unread message

asiny...@nes.ru

unread,
Apr 20, 2020, 10:14:27 AM4/20/20
to Artelys Knitro forum
Hi all,

I'm using knitro with matlab. Iteration information is not showing up during solution process, only after computation is over. I'm using these options: options=knitro_options('algorithm',1,'outlev',4,'ftol',1e-10,'maxit',3,'maxfevals',30,'hessopt',3,'outmode',0); Any ideas how to fix it? Thanks

Richard Waltz

unread,
Apr 20, 2020, 10:20:04 AM4/20/20
to kni...@googlegroups.com
Hi,

Putting an empty display command:

  disp '';

in your objective function callback routine passed to Knitro should fix this issue.  See, for instance, the beginning of the "objfun" function in "exampleNLP1.m"  provided in the Knitro 12.1 distribution under "knitromatlab/examples".

Regards,
-Richard


Richard WALTZ
Senior Scientist
 
Artelys USA
 


From: kni...@googlegroups.com [kni...@googlegroups.com] on behalf of asiny...@nes.ru [asiny...@nes.ru]
Sent: Monday, April 20, 2020 1:57 AM
To: Artelys Knitro forum
Subject: [Knitro] Iteration info is not displaying in Matlab

Hi all,

I'm using knitro with matlab. Iteration information is not showing up during solution process, only after computation is over. I'm using these options: options=knitro_options('algorithm',1,'outlev',4,'ftol',1e-10,'maxit',3,'maxfevals',30,'hessopt',3,'outmode',0); Any ideas how to fix it? Thanks

--
You received this message because you are subscribed to the Artelys "Knitro Nonlinear Optimization Solver" google group.
To post to this group, send email to kni...@googlegroups.com
To unsubscribe from this group, send email to knitro-un...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/knitro?hl=en
Thank You,
Artelys
http://www.artelys.com/en/optimization-tools/knitro
---
You received this message because you are subscribed to the Google Groups "Artelys Knitro forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to knitro+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/knitro/617ee055-3368-44f3-a872-69cc1e070749%40googlegroups.com.

Alexey Sinyashin

unread,
Apr 20, 2020, 1:13:06 PM4/20/20
to Artelys Knitro forum
Great, thanks!

李佳旭

unread,
Apr 7, 2021, 1:55:35 PM4/7/21
to Artelys Knitro forum
Thanks for your advice.
I notice that the " disp ''; " has been put in  the Knitro 12.3 distribution under "knitromatlab/examples" but the iteration information is still not showing up before the computation is over.
Do you have any ideas how to fix it? 

Thanks

richard.waltz

unread,
Apr 7, 2021, 1:58:59 PM4/7/21
to Artelys Knitro forum
We have not been able to reproduce the issue you report.  We tested using Knitro 12.3 on the latest MATLAB R2021a and using the disp''; command seems to flush the iteration output to the screen every iteration as expected.  If you can tell us what operating system you are using, what version of MATLAB you are using, and provide us an example to reproduce the issue, we will investigate further.

Jiaxu Li

unread,
Apr 9, 2021, 10:41:40 AM4/9/21
to Artelys Knitro forum
Thanks a lot.
The problem is solved by updating the Matlab version and simplifying the model.
^_^

Reply all
Reply to author
Forward
0 new messages