MPS File

223 views
Skip to first unread message

pratimusc

unread,
Aug 3, 2015, 11:40:00 AM8/3/15
to am...@googlegroups.com
Hello,

I have the data and model file written in AMPL for a quadratic optimization
problem. I tried to convert them into MPS files that can be read by Cplex.

I know that MPS file are typically for linear programming files. However,
the cplex solver has MPS built-in extensions that allow it to handle a
quadratic objective function and/or quadratic constraints.

I tried to convert the AMPL files from AMPL into MPS files using the
command:
write mInstance1;

However, I get an error message.
Problem has 14 nonlinear variables. No MPS file written.

Is there a way to circumvent this issue and to automatically write an MPS
file readable by Cplex from AMPL model and data files?

Is there another file format that I could generate from AMPL and that can be
read by Cplex?

Best regards,
Pratim




--
View this message in context: http://ampl.996311.n3.nabble.com/MPS-File-tp11038.html
Sent from the AMPL mailing list archive at Nabble.com.

victor.z...@gmail.com

unread,
Aug 3, 2015, 2:36:18 PM8/3/15
to am...@googlegroups.com
Hello, Pratim.

The standard low-level format used by AMPL for communicating with solvers is the NL format. Unlike MPS, it works with all types of optimization problems AMPL supports. You can generate it with the command:

  write gInstance1;

The NL format is also much more compact and faster to read than MPS, so there is little reason to use MPS. CPLEX can read .nl files via the AMPL driver which is included in the distribution.

HTH,
Victor

--
You received this message because you are subscribed to the Google Groups "AMPL Modeling Language" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ampl+uns...@googlegroups.com.
To post to this group, send email to am...@googlegroups.com.
Visit this group at http://groups.google.com/group/ampl.
For more options, visit https://groups.google.com/d/optout.
--
AMPL Support Services
Reply all
Reply to author
Forward
0 new messages