Dursun Bulutoglu
--
View this message in context: http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-Field-of-Rational-Numbers-tf3167622.html#a8787137
Sent from the AMPL mailing list archive at Nabble.com.
ampl: model diet2.mod;
ampl: data diet2.dat;
ampl: option relax_integrality 1;
ampl: write mdiet;
ampl:
Then enter the resulting file diet.mps in the form on the above page of the
NEOS Solver, and wait for the output:
mpq_ILLlp_add_logicals ...
Time for SOLVER_READ: 0.00 seconds.
starting mpq_ILLsimplex on scaled_lp...
Problem has 17 rows and 80 cols
starting primal phase I
(0): primal infeas = 5179.8211382 637118/123
starting primal phase II
completed mpq_ILLsimplex
scaled_lp: time = 0.120, pI = 14, pII = 22, dI = 0, dII = 0, opt = 7.798354
starting mpq_ILLsimplex on diet...
Problem has 17 rows and 80 cols
completed mpq_ILLsimplex
diet: time = 0.010, pI = 0, pII = 0, dI = 0, dII = 0, opt = 7.798354
LP Value: 7.798354, status 1
Time for SOLVER: 0.14 seconds.
Solution Values
C0001 = 2
C0002 = 23765960070/22282172849
C0023 = 15198945227/22282172849
C0024 = 15198945227/22282172849
C0030 = 15198945227/22282172849
C0040 = 28898532528/22282172849
C0044 = 7771548482/22282172849
C0048 = 32536163082/22282172849
C0051 = 9060787642/22282172849
C0063 = 25249567823/22282172849
It's up to you to connect these values to the variables in the AMPL model,
though. This solver also accepts "LP format" which can be derived from the
output of the AMPL "expand" command, but only by means of some nontrivial
transformations.
Bob Fourer
4...@ampl.com
Thanks a lot for pointing out this solver.
Dursun.
--
View this message in context: http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-Field-of-Rational-Numbers-tf3167622.html#a8795790
On Feb 4, 11:43 am, dbulutog <dursun.buluto...@afit.edu> wrote:
> This is great!
> I have another related question. The parameter values in my problems may be
> integers as large as than 10^10. When read such integers into AMPL AMPL
> truncates them. For example 1036474564667 can be read as 1036474560000 or
> even 1.0364*10^12. Is there a way read such large integers as exactly what
> they are from a .dat file. I will use AMPL to create the necessary MPS files
> for qsopt to solve. I will be solving integer programming problems but would
> like the Branch and Bound algorithm to use the exact solutions to the LP
> relaxations on the nodes of the Branch and Bound tree.
>
> Thanks a lot for pointing out this solver.
>
> Dursun.
>
>
>
> Robert Fourer-2 wrote:
>
> > Seehttp://neos.mcs.anl.gov/neos/solvers/lp:qsopt_ex/LP.html.
> View this message in context:http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-F...
On Feb 4, 11:43 am, dbulutog <dursun.buluto...@afit.edu> wrote:
> This is great!
> I have another related question. The parameter values in my problems may be
> integers as large as than 10^10. When read such integers into AMPL AMPL
> truncates them. For example 1036474564667 can be read as 1036474560000 or
> even 1.0364*10^12. Is there a way read such large integers as exactly what
> they are from a .dat file. I will use AMPL to create the necessary MPS files
> for qsopt to solve. I will be solving integer programming problems but would
> like the Branch and Bound algorithm to use the exact solutions to the LP
> relaxations on the nodes of the Branch and Bound tree.
>
> Thanks a lot for pointing out this solver.
>
> Dursun.
>
>
>
> Robert Fourer-2 wrote:
>
> > Seehttp://neos.mcs.anl.gov/neos/solvers/lp:qsopt_ex/LP.html.
> View this message in context:http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-F...
Dursun Bulutoglu.
--
View this message in context: http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-Field-of-Rational-Numbers-tf3167622.html#a8800196
> View this message in context:http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-F...
On Feb 4, 7:34 pm, dbulutog <dursun.buluto...@afit.edu> wrote:
> View this message in context:http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-F...
Regarding the handling of large integers by AMPL, you state: "The parameter
values in my problems may be integers as large as than 10^10. When read such
integers into AMPL, AMPL truncates them. For example 1036474564667 can be read
as 1036474560000 or even 1.0364*10^12." If you use "display" on a large
integer, it may appear to be truncated:
ampl: param a = 1036474564667;
ampl: display a;
a = 1.03647e+12
But this is because the default display precision is 6 significant digits. If
you change the option display_precision to zero, it is specially interpreted to
mean that display should show as many significant digits as possible:
ampl: option display_precision 0;
ampl: display a;
a = 1036474564667
So in this case there is not actually any truncation of the value, only of the
way it is chosen to be displayed. (Note also that "print a;" gives maximum
possible precision by default.)
The precision for numbers written by the "expand" statement is similarly given
by expand_precision, whose default is 6 like that of display_precision.
Unfortunately the MPS form standard allows for only 12 characters to represent
each number, so parameter a above cannot be represented any more precisely than
1.036475E+12. There is an unofficial free-format version of MPS form that
allows longer numbers, but not all solvers recognize it.
Bob Fourer
4...@ampl.com
> Programming-Problems--Over-the-Field-of-Rational-Numbers-
> tf3167622.html#a8800196
Professor Fourer and the AMPL forum,
I was wondering how easy it is to use AMPL to generate LP files using the
expand command.
If those non-trivial transformations that you suggested are easy to
implement I will take this course otherwise I may have to program in GAP to
produce my LP files. If there are any references in this regard I would
appreciate them.
Thanks alot again for your responses. They have been very helpful.
Dursun.
Dursun,
ampl: option display_precision 0;
Bob Fourer
4...@ampl.com
--
View this message in context: http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-Field-of-Rational-Numbers-tf3167622.html#a8814361
Dursun.
--
View this message in context: http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-Field-of-Rational-Numbers-tf3167622.html#a8819014
I also work as a researcher at RAND. I formulated a problem as a QP
with some binary variables. It is my understanding that CPLEX can solve
these. I want to try a small sample before investing in a full license
for my research project.
I tried using my student edition and I get an error message about a
licensing problem (CPLEX error # 0).
Is it the case that the student edition of CPLEX does not support QP's
with binary variables?
Is there some way that I can test a small problem (maybe using the web
interface)?
If I can show that the small problem can be solved, then I can convince
my project leader to buy me a license so I can use it for my research :)
Thanks in advance,
Brien
--------------------
This email message is for the sole use of the intended recipient(s) and
may contain privileged information. Any unauthorized review, use,
disclosure or distribution is prohibited. If you are not the intended
recipient, please contact the sender by reply email and destroy all copies
of the original message.
I suspect the student edition is an older, much older, version of cplex.
Steven Harrod
--
Steven Harrod
Lexington, KY
859 225 1572
Actually, I apologize for sending that email prematurely. Indeed it
does appear to solve QP's with binary variables. I must have had an
error in my objective function!
Thanks for offering to solve it for me.
Hopefully I can interest my project leader enough to purchase a full
version. That will depend on the size of the problem, and I am
uncertain of that yet. If it is too large (too many binary variables) I
may attempt to use GA.
-Brien
-----Original Message-----
From: am...@googlegroups.com [mailto:am...@googlegroups.com] On Behalf Of
Steven Harrod
Sent: Monday, February 05, 2007 6:24 PM
To: am...@googlegroups.com
CPLEX 10.1.0: unrecoverable failure or licensing problem: CPLEX error # 0.
when the objective is not positive semi-definite. If that's the case then
the fault is in the error message, which should be more specific. The
methods in CPLEX are not capable of optimizing over indefinite quadratic
terms.
Bob Fourer
4...@ampl.com
> View this message in context:http://www.nabble.com/Solving-Linear-Programming-Problems--Over-the-F...
It's easy enough to use the expand command; it's just "expand;" to get the
expansion before AMPL's presolve, or "solexpand;" to get the expansion of what
would be sent to a solver after AMPL's presolve. The output can be redirected
to a file by use of something like "expand >filename;" or "expand >filename;".
If you try an example you'll see pretty quickly how the output differs from LP
form and what would be involved in the transformation.
Dursun.
-----Original Message-----
From: Robert Fourer [mailto:4...@ampl.com]
On Feb 7, 6:09 pm, "Bulutoglu Dursun A Civ AFIT/ENC"
> ...
>
> read more ยป
I think this was introduced for 9.1(10.0?) or something in that range.
They can fix the model when only binary variables to make it run.
Possibly you have variables that are non-binary.
Best wishes, Marcus
Tomlab Optimization Inc.
http://tomopt.com/ampl/
> > of the original message.- Hide quoted text -
>
> - Show quoted text -