coin-or / SHOT

A solver for mixed-integer nonlinear optimization problems
https://shotsolver.dev
Eclipse Public License 2.0
119 stars 25 forks source link

creating a optimization problem with SHOT #144

Closed jbensabat closed 2 years ago

jbensabat commented 2 years ago

Hello I managed to build SHOT with (IPOPT, CBC) under windows MSVC and Intel Fortran. I ran the examples with the OSIL format and it seems that it works. I would like now to create a real problem and I see that doing so with OSIL is challenging because of the syntax and the apparent lack of documentation. What could be the simplest way to create a problem ? using AMPL ? Is there a way to create an OSIL file with a suitable programming (with expressions and a suitable parser) ? thanks jac

andreaslundell commented 2 years ago

There are some options for creating models for SHOT, instructions at https://shotsolver.dev/shot/using-shot/getting-started.

It is also possible to create the problem using SHOT's API in C++, instruction at https://github.com/coin-or/SHOT/blob/e225a002500a4826d8dd575799bf3486967d57f1/test/ModelTest.cpp

OSiL is unfortunately not a really good language for creating optimization models, and I do not really know of any software that can create this type of format. GAMS can convert to OSiL format using its CONVERT "solver" https://www.gams.com/34/docs/S_CONVERT.html.

If you have any further questions, please reopen this issue.

jbensabat commented 2 years ago

hi thanks will try either with ampl or hard-coding then