[Coin-ipopt] IPOPT needs many iterations for some problem of dimension 4
Andreas Waechter
andreasw at watson.ibm.com
Thu Dec 7 18:29:21 EST 2006
Hi Stefan,
I just tried the problem from your email; I copied it into a file and used
it from AMPL. You have a term with "x24" in there, which I guess is a
typo, and I tried all of "x2*x4", "x2", and "x4". I tried it with AMPL's
presolve and without, but I cannot reproduce the behavior you describe.
For me, the problems converge in 9 iterations.
In order to proceed, could you please send me the AMPL file (directly to
me), and tell me if you are using any particular options, and how you
configured Ipopt (which linear solver etc). It could be a problem with
the linear solver...? Are you using MA27 or something else? (I tried it
with MA27...)
By the way, one option that might sometimes speed up convergence is
mu_strategy adaptive
which often leads often to fewer iterations (but cost per iteration is
slightly more). But this has nothing to do with the behavior you
describe.
Cheers
Andreas
On Sun, 3 Dec 2006, Stefan Vigerske wrote:
> Hi,
>
> in my code, I'm using IPOPT so solve some subproblems. It's working very
> fine and fast for most cases :-), but there are a few examples where it
> seem to have a problem.
> What I'm doing is that I'm minimizing a function p(x)-f(x) over a box
> where p(x) is some quadratic function and f(x) can be anything.
> In one of my examples IPOPT needs very many iterations (around 2800) for
> minimizing p(x)-f(x) with x having dimension 12.
> To isolate the problem, I followed a suggestion from Arnold Neumaier: I
> stopped IPOPT after 1000 iterations, and fixed those variables that were
> active (z_L oder z_U > 0) and were very close to the bounds.
> Then the problem reduces to dimension 4, so I can post it here.
> When I run it with the ampl-version of Ipopt 3.2.2 it still takes IPOPT
> around 900 iterations to converge to a local optima.
>
> var x1 := 0.945031, >= 0.9, <= 1.05;
> var x2 := 1.0241, >= 0.9, <= 1.05;
> var x3 := 1.03214, >= 0.9, <= 1.05;
> var x4 := 7723.33, >= -10000, <= 10000;
> minimize obj: 0.864506005768817*x1 - 9.09006295233917e-5*x4*x1 -
> 7.08063848069429e-5*x4 - 1.03973134163199e-5*x4 +
> 0.000460593359671313*x42 - 0.9*(-0.864296115364742*cos((-10000) + x4) -
> 6.06886185353939*sin((-10000) + x4))*x1 + 0.812060804378798*x2 +
> 1.40432467266548*x3 - 343160.616325042;
>
> I agree that with a proper reformulation, everything will simplify. But
> since this is what appear somewhere deep inside my code, it cannot be
> reformulated by hand.
>
> The IPOPT output with print_level 4 looks like that (I removed the
> inf_pr column which is always 0.00e+00):
> iter objective inf_du lg(mu) ||d|| lg(rg) alpha_du alpha_pr ls
> 0 -3.1568920e+05 4.87e+00 -1.0 0.00e+00 - 0.00e+00 0.00e+00 0
> 1 -3.1569229e+05 1.54e+00 -1.0 9.75e-01 - 6.97e-01 8.74e-01f 1
> 2 -3.1569485e+05 4.34e+00 -1.0 1.19e+00 - 2.88e-01 1.00e+00f 1
> 3 -3.1569525e+05 5.06e+00 -1.0 5.07e-02 2.0 9.90e-01 1.00e+00f 1
> 4 -3.1569601e+05 4.78e+00 -1.0 1.46e-01 1.5 9.93e-01 8.84e-01f 1
> ...
> 910 -3.2544949e+05 6.81e+00 -2.5 4.57e-01 1.2 1.00e+00 1.00e+00f 1
> 911 -3.2586980e+05 4.96e+00 -2.5 7.23e+01 0.7 7.04e-02 1.00e+00f 1
> 912 -3.2587059e+05 4.91e+00 -2.5 1.76e+00 - 4.13e-03 8.14e-02f 1
> 913 -3.2587192e+05 1.18e+00 -2.5 7.15e-01 - 1.00e+00 1.00e+00f 1
> 914 -3.2587213e+05 2.47e-01 -2.5 3.24e-01 - 1.00e+00 1.00e+00f 1
> 915 -3.2587216e+05 5.31e-02 -2.5 3.12e-02 0.2 1.00e+00 1.00e+00f 1
> 916 -3.2587216e+05 2.21e+00 -2.5 4.55e-01 - 1.00e+00 1.07e-01f 2
> 917 -3.2587216e+05 3.48e-03 -2.5 3.56e-02 - 1.00e+00 1.00e+00f 1
> 918 -3.2587218e+05 6.33e-02 -3.8 5.30e-02 - 9.73e-01 7.55e-01f 1
> 919 -3.2587218e+05 6.87e-05 -3.8 4.90e-03 - 1.00e+00 1.00e+00f 1
> 920 -3.2587218e+05 9.40e-07 -5.7 5.46e-04 - 1.00e+00 1.00e+00f 1
> 921 -3.2587218e+05 1.19e-10 -8.6 6.13e-06 - 1.00e+00 1.00e+00f 1
> (scaled) (unscaled)
> Objective...............: -3.2587217749721e+05 -3.2587217749721959e+05
> Dual infeasibility......: 1.1859351865773e-10 1.1859351865773223e-10
> Constraint violation....: 0.0000000000000e+00 0.0000000000000000e+00
> Complementarity.........: 2.5335012268450e-09 2.5335012268450292e-09
> Overall NLP error.......: 2.5335012268450e-09 2.5335012268450292e-09
>
> Maybe you have some idea which parameter to adjust. The function seem to
> have many local minima. I do not need a very good one, just one that is
> close to the starting point would be sufficient.
>
> Many thanks,
> Stefan
> _______________________________________________
> Coin-ipopt mailing list
> Coin-ipopt at list.coin-or.org
> http://list.coin-or.org/mailman/listinfo/coin-ipopt
>
More information about the Coin-ipopt
mailing list