Long NLP evaluation time in Ipopt

Dear all,
I encounter long evaluation times and slow convergence in an AC security constraint optimal power flow (SCOPF) optimization. The problem is modelled with PowerModels and JuMP. The NLP evaluation time is higher than the time for Ipopt itself.

Total seconds in IPOPT (w/o function evaluations)    =     61.769
Total seconds in NLP function evaluations            =     69.785

Are there any suggestions or indications on how to improve the performance of the solving process? Your help is highly appreciated.

Below you will find the Ipopt log:

List of user-set options:

                                    Name   Value                used
                         acceptable_iter = 5                     yes
                          acceptable_tol = 0.1                   yes
            check_derivatives_for_naninf = yes                   yes
                           compl_inf_tol = 0.001                 yes
                         constr_viol_tol = 0.01                  yes
                                  hsllib = \HSL\JuliaHSL\lbt_HSL_jll.jl-2023.5.26\HSL_jll.jl-2023.5.26\override\bin\x86_64-w64-mingw32-libgfortran5\libhsl.dll  yes
                           linear_solver = ma57                  yes
                                max_iter = 700                   yes
                      obj_scaling_factor = 1                     yes
                             print_level = 5                     yes
                 print_timing_statistics = yes                   yes
                      print_user_options = yes                   yes
                                     tol = 0.01                  yes
                   warm_start_init_point = yes                   yes
This is Ipopt version 3.14.13, running with linear solver ma57.

Number of nonzeros in equality constraint Jacobian...:   250815
Number of nonzeros in inequality constraint Jacobian.:    41004
Number of nonzeros in Lagrangian Hessian.............:   371090

Total number of variables............................:    73711
                     variables with only lower bounds:     1584
                variables with lower and upper bounds:    26292
                     variables with only upper bounds:     1584
Total number of equality constraints.................:    70747
Total number of inequality constraints...............:    27608
        inequality constraints with only lower bounds:        0
   inequality constraints with lower and upper bounds:        0
        inequality constraints with only upper bounds:    27608

iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
   0  9.1716842e+01 9.38e+00 3.00e+01  -1.0 0.00e+00    -  0.00e+00 0.00e+00   0
Reallocating memory for MA57: lfact (4602841)
   1  4.3180404e+01 9.38e+00 3.00e+01  -1.0 1.16e+02  -2.0 6.01e-04 1.33e-04f  1
   2  1.8568919e+02 9.36e+00 2.99e+01  -1.0 6.42e+01  -1.6 2.85e-03 2.60e-03f  1
   3  1.1234750e+02 9.32e+00 2.98e+01  -1.0 9.91e+00  -0.2 4.61e-03 4.05e-03f  1
   4  1.1873445e+02 9.27e+00 2.97e+01  -1.0 9.95e+00   0.2 4.28e-03 5.81e-03f  1
   5  1.2573785e+02 9.23e+00 2.95e+01  -1.0 1.02e+01   0.6 8.90e-03 4.07e-03f  1
   6  1.5780528e+02 9.06e+00 2.90e+01  -1.0 1.00e+01   0.1 1.58e-02 1.86e-02f  1
   7  1.6383345e+02 9.03e+00 2.90e+01  -1.0 9.97e+00   0.6 1.59e-02 2.84e-03f  1
   8  1.7170531e+02 9.00e+00 2.89e+01  -1.0 1.00e+01   1.0 1.71e-02 3.39e-03f  1
   9  2.0612521e+02 8.86e+00 2.85e+01  -1.0 9.95e+00   0.5 2.41e-02 1.53e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  10  2.2128040e+02 8.81e+00 2.83e+01  -1.0 9.85e+00   0.9 2.32e-02 6.20e-03f  1
  11  2.8837520e+02 8.55e+00 2.74e+01  -1.0 9.76e+00   0.5 3.33e-02 2.88e-02f  1
  12  3.2302020e+02 8.44e+00 2.70e+01  -1.0 9.52e+00   0.9 9.33e-03 1.40e-02f  1
  13  3.4104303e+02 8.37e+00 2.68e+01  -1.0 9.40e+00   1.3 1.83e-02 7.22e-03f  1
  14  4.1952990e+02 8.11e+00 3.23e+01  -1.0 9.33e+00   0.8 1.02e-01 3.18e-02f  1
  15  5.3188049e+02 7.70e+00 3.32e+01  -1.0 8.98e+00   0.4 1.38e-01 5.05e-02f  1
  16  5.3755905e+02 7.68e+00 5.65e+01  -1.0 8.56e+00   0.8 1.59e-01 2.48e-03f  1
  17  6.3886075e+02 7.30e+00 5.21e+01  -1.0 8.58e+00   0.3 2.03e-01 4.92e-02f  1
  18  6.9565220e+02 7.11e+00 5.44e+01  -1.0 8.25e+00   0.7 5.37e-02 2.65e-02f  1
  19  7.9883169e+02 6.71e+00 5.45e+01  -1.0 8.13e+00   0.2 1.47e-01 5.67e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  20  8.4943970e+02 6.53e+00 5.10e+01  -1.0 7.74e+00   0.7 1.57e-02 2.63e-02f  1
  21  9.1263316e+02 6.27e+00 4.90e+01  -1.0 7.55e+00   0.2 3.79e-02 4.00e-02f  1
  22  9.6314034e+02 6.09e+00 4.62e+01  -1.0 7.28e+00   0.6 1.98e-02 2.87e-02f  1
  23  9.8303312e+02 6.02e+00 5.00e+01  -1.0 7.10e+00   1.0 1.92e-02 1.09e-02f  1
  24  1.0224924e+03 5.88e+00 5.22e+01  -1.0 7.01e+00   0.6 5.63e-02 2.42e-02f  1
  25  1.0379435e+03 5.82e+00 5.12e+01  -1.0 6.84e+00   1.0 8.01e-03 9.19e-03f  1
  26  1.0558877e+03 5.75e+00 5.15e+01  -1.0 6.72e+00   0.5 2.39e-02 1.18e-02f  1
  27  1.1105068e+03 5.56e+00 4.64e+01  -1.0 6.66e+00   0.9 2.39e-02 3.35e-02f  1
  28  1.2114942e+03 5.17e+00 4.11e+01  -1.0 6.43e+00   0.5 1.62e-02 7.08e-02f  1
  29  1.2272061e+03 5.11e+00 5.05e+01  -1.0 6.02e+00   0.9 4.90e-02 1.09e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  30  1.2406552e+03 5.06e+00 5.86e+01  -1.0 5.92e+00   0.4 4.95e-02 1.06e-02f  1
  31  1.2849234e+03 4.89e+00 4.54e+01  -1.0 5.89e+00   0.8 1.77e-02 3.20e-02f  1
  32  1.3198929e+03 4.75e+00 4.43e+01  -1.0 5.66e+00   0.4 1.89e-02 2.93e-02f  1
  33  1.3553176e+03 4.62e+00 4.25e+01  -1.0 5.54e+00   0.8 2.31e-02 2.75e-02f  1
  34  1.4023239e+03 4.42e+00 3.76e+01  -1.0 5.34e+00   0.3 1.12e-01 4.23e-02f  1
  35  1.4079102e+03 4.40e+00 6.36e+01  -1.0 5.16e+00   0.7 4.34e-02 4.61e-03h  1
  36  1.4433519e+03 4.28e+00 3.31e+01  -1.0 5.16e+00   1.2 1.30e-02 2.78e-02h  1
  37  1.4790161e+03 4.15e+00 4.01e+01  -1.0 5.00e+00   0.7 4.51e-02 3.05e-02f  1
  38  1.5041851e+03 4.07e+00 3.86e+01  -1.0 4.86e+00   1.1 2.02e-02 2.06e-02h  1
  39  1.5323190e+03 3.96e+00 5.45e+01  -1.0 4.74e+00   0.6 6.91e-02 2.54e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  40  1.5474848e+03 3.91e+00 5.34e+01  -1.0 4.64e+00   1.1 1.36e-02 1.38e-02h  1
  41  1.5985807e+03 3.71e+00 5.11e+01  -1.0 4.58e+00   0.6 5.34e-02 5.16e-02f  1
  42  1.6230259e+03 3.62e+00 1.12e+02  -1.0 4.37e+00   1.0 5.13e-02 2.42e-02h  1
  43  1.7076968e+03 3.27e+00 1.27e+02  -1.0 4.26e+00   0.5 1.72e-01 9.47e-02f  1
  44  1.7112064e+03 3.26e+00 2.51e+02  -1.0 3.87e+00   1.0 7.43e-02 3.92e-03h  1
  45  1.7593780e+03 3.06e+00 2.34e+02  -1.0 3.85e+00   0.5 1.28e-01 6.04e-02f  1
  46  1.7665410e+03 3.04e+00 2.38e+02  -1.0 3.76e+00   0.9 1.32e-02 8.30e-03h  1
  47  1.7819511e+03 2.98e+00 2.33e+02  -1.0 3.78e+00   0.4 1.62e-02 2.00e-02h  1
  48  1.7985805e+03 2.92e+00 2.72e+02  -1.0 3.56e+00   0.9 4.58e-02 1.96e-02h  1
  49  1.8442748e+03 2.73e+00 2.59e+02  -1.0 3.54e+00   0.4 1.66e-02 6.39e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  50  1.8743367e+03 2.63e+00 2.76e+02  -1.0 3.31e+00   0.8 6.25e-02 3.91e-02h  1
  51  1.9238778e+03 2.42e+00 2.57e+02  -1.0 3.27e+00   0.3 7.01e-02 8.00e-02f  1
  52  1.9828630e+03 2.20e+00 2.10e+02  -1.0 3.02e+00   0.8 5.22e-02 8.74e-02h  1
  53  2.0095513e+03 2.08e+00 1.93e+02  -1.0 2.77e+00   0.3 6.51e-02 5.52e-02f  1
  54  2.0394719e+03 1.97e+00 2.04e+02  -1.0 2.65e+00   0.7 1.07e-01 5.27e-02h  1
  55  2.0851337e+03 1.75e+00 1.53e+02  -1.0 2.48e+00   0.2 1.59e-01 1.11e-01f  1
  56  2.1027078e+03 1.69e+00 1.49e+02  -1.0 2.43e+00   0.7 5.20e-02 3.71e-02h  1
  57  2.1297528e+03 1.60e+00 8.57e+01  -1.0 2.34e+00   1.1 2.07e-02 5.28e-02h  1
  58  2.1464470e+03 1.54e+00 7.32e+01  -1.0 2.23e+00   0.6 1.34e-01 3.91e-02h  1
  59  2.1713332e+03 1.46e+00 4.88e+01  -1.0 2.16e+00   1.0 3.45e-02 5.24e-02h  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  60  2.1868472e+03 1.40e+00 3.97e+01  -1.0 2.04e+00   0.6 2.53e-01 3.96e-02h  1
  61  2.2027337e+03 1.35e+00 3.18e+01  -1.0 1.98e+00   1.0 2.53e-02 3.61e-02h  1
  62  2.2721944e+03 1.08e+00 2.23e+01  -1.0 1.89e+00   0.5 1.81e-01 1.96e-01f  1
  63  2.3057196e+03 9.75e-01 2.35e+02  -1.0 1.55e+00   0.9 3.46e-01 1.01e-01h  1
  64  2.3301365e+03 8.70e-01 1.83e+02  -1.0 1.32e+00   0.5 1.73e-01 1.08e-01h  1
  65  2.3426662e+03 8.28e-01 1.86e+02  -1.0 1.23e+00   0.9 8.38e-02 4.80e-02h  1
  66  2.3862557e+03 6.14e-01 1.92e+02  -1.0 1.08e+00   0.4 1.33e-01 2.58e-01f  1
  67  2.4189419e+03 4.99e-01 1.67e+02  -1.0 8.33e-01   0.8 4.15e-01 1.88e-01h  1
  68  2.4508750e+03 4.02e-01 1.24e+02  -1.0 6.91e-01   1.3 1.85e-01 1.95e-01h  1
  69  2.4941566e+03 2.23e-01 4.80e+01  -1.0 5.20e-01   0.8 5.48e-01 4.45e-01h  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  70  2.5170285e+03 1.43e-01 3.49e+02  -1.0 2.91e-01   1.2 9.42e-01 3.59e-01h  1
  71  2.5153722e+03 4.85e-02 6.93e+01  -1.0 1.92e-01   0.7 5.18e-01 6.61e-01h  1
  72  2.5138413e+03 2.45e-02 4.00e+01  -1.0 7.12e-02   1.2 4.71e-01 4.94e-01h  1
  73  2.4921549e+03 1.43e-02 2.33e+01  -1.0 2.07e-01   0.7 4.16e-01 4.16e-01f  1
  74  2.4809807e+03 5.55e-03 9.09e+02  -1.0 8.69e-02   1.1 8.93e-01 6.13e-01h  1
  75  2.4477302e+03 2.71e-03 1.96e+02  -1.0 5.49e-01   0.6 4.02e-01 5.12e-01f  1
  76  2.4368487e+03 1.43e-03 8.61e+02  -1.0 1.65e-01   1.0 1.56e-01 4.73e-01h  1
  77  2.4051270e+03 7.99e-04 7.38e+02  -1.0 2.40e-01   0.6 7.97e-01 4.58e-01f  1
  78  2.4014757e+03 6.83e-04 2.31e+03  -1.0 8.96e-02   1.0 1.00e+00 1.46e-01f  3
  79  2.3518603e+03 1.20e-03 1.19e+03  -1.0 2.57e-01   0.5 1.00e+00 6.79e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  80  2.3255123e+03 3.64e-04 9.44e+00  -1.0 9.38e-02   0.9 1.00e+00 1.00e+00f  1
  81  2.2740057e+03 1.85e-03 9.76e+02  -1.0 2.50e-01   0.5 1.00e+00 6.91e-01f  1
  82  2.2490742e+03 4.66e-04 1.44e+01  -1.0 1.03e-01   0.9 1.00e+00 1.00e+00f  1
  83  2.2209735e+03 9.21e-04 1.42e+03  -1.0 2.68e-01   0.4 1.00e+00 3.87e-01f  1
  84  2.1973936e+03 6.00e-04 1.99e+02  -1.0 9.67e-02   0.8 1.00e+00 9.11e-01f  1
  85  2.1523808e+03 2.39e-03 6.78e+02  -1.0 2.67e-01   0.4 1.00e+00 6.62e-01f  1
  86  2.1362393e+03 1.08e-03 6.08e+02  -1.0 9.86e-02   0.8 1.00e+00 6.77e-01f  1
  87  2.1059173e+03 3.17e-03 7.12e+02  -1.0 7.30e-01   0.3 8.14e-01 4.77e-01f  1
  88  2.0834791e+03 5.72e-04 8.21e+01  -1.0 1.01e-01   0.7 1.00e+00 1.00e+00f  1
  89  2.0279685e+03 4.02e-03 3.37e+02  -1.0 2.86e-01   0.3 6.68e-01 8.80e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
  90  2.0066359e+03 6.99e-04 2.71e+00  -1.0 1.26e-01   0.7 1.00e+00 1.00e+00f  1
  91  1.9821736e+03 1.33e-03 8.38e+02  -1.0 2.51e-01   0.2 1.00e+00 4.09e-01f  1
  92  1.9608794e+03 8.55e-04 3.41e+00  -1.0 9.39e-02   0.6 1.00e+00 1.00e+00f  1
  93  1.9261799e+03 2.55e-03 3.90e+02  -1.0 3.06e-01   0.2 8.66e-01 5.71e-01f  1
  94  1.9050237e+03 1.03e-03 1.20e+01  -1.0 1.11e-01   0.6 1.00e+00 1.00e+00f  1
  95  1.8590061e+03 6.53e-03 2.45e+02  -1.0 6.92e-01   0.1 5.61e-01 7.61e-01f  1
  96  1.8566815e+03 2.69e-03 9.81e+02  -1.0 1.23e-01   1.4 3.18e-01 1.00e+00f  1
  97  1.8532919e+03 1.53e-03 6.50e+02  -1.0 1.98e-01   1.0 1.00e+00 4.34e-01f  1
  98  1.8300434e+03 1.50e-03 1.12e+02  -1.0 1.53e-01   0.5 1.00e+00 1.00e+00f  1
  99  1.8218076e+03 2.25e-04 1.70e+02  -1.0 5.75e-02   0.9 8.45e-01 1.00e+00f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 100  1.7980477e+03 4.25e-03 7.14e+02  -1.0 3.55e-01   0.4 4.18e-01 1.00e+00f  1
 101  1.7980588e+03 2.81e-03 6.92e+03  -1.0 8.48e-02   2.7 2.72e-01 1.00e+00h  1
 102  1.7979721e+03 2.10e-03 5.34e+03  -1.0 1.94e-01   2.2 1.00e+00 2.41e-01h  1
 103  1.7979089e+03 1.93e-03 5.05e+03  -1.0 2.37e+00   1.7 6.86e-01 5.13e-02f  2
 104  1.7975030e+03 4.63e-04 9.45e+02  -1.0 1.20e-01   2.1 1.00e+00 1.00e+00h  1
 105  1.7962014e+03 6.11e-05 1.10e+01  -1.0 8.56e-03   1.7 1.00e+00 1.00e+00f  1
 106  1.7922792e+03 3.01e-04 5.26e+00  -1.0 8.06e-02   1.2 1.00e+00 1.00e+00f  1
 107  1.7822273e+03 4.33e-04 9.64e+01  -1.0 6.45e-02   0.7 1.00e+00 8.95e-01f  1
 108  1.7573063e+03 3.63e-03 1.37e+02  -1.0 1.85e-01   0.2 1.00e+00 8.47e-01f  1
 109  1.7414203e+03 4.32e-03 4.61e+02  -1.0 8.14e-01  -0.2 7.06e-01 2.30e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 110  1.7225234e+03 4.11e-03 1.87e+02  -1.0 2.39e-01   0.2 1.00e+00 7.88e-01f  1
 111  1.6945314e+03 9.93e-03 1.29e+02  -1.0 6.61e-01  -0.3 5.17e-01 4.72e-01f  1
 112  1.6841097e+03 6.16e-03 3.21e+02  -1.0 2.49e-01   0.1 9.21e-01 5.59e-01f  1
 113  1.6785266e+03 8.63e-04 3.79e-01  -1.0 9.44e-02   0.6 1.00e+00 1.00e+00f  1
 114  1.6265266e+03 5.15e-04 1.34e+01  -2.5 1.66e-01   0.1 6.49e-01 4.10e-01f  1
 115  1.5491916e+03 2.10e-03 1.08e+01  -2.5 5.00e-01  -0.4 4.64e-01 4.25e-01f  1
 116  1.5119139e+03 1.45e-03 7.07e+00  -2.5 1.95e-01   0.0 5.04e-01 4.57e-01f  1
 117  1.5006965e+03 1.02e-03 2.74e+01  -2.5 7.46e-02   0.5 8.12e-01 3.13e-01f  1
 118  1.4762919e+03 8.72e-04 3.20e+01  -2.5 2.18e-01  -0.0 8.97e-01 3.41e-01f  1
 119  1.4468469e+03 2.61e-04 8.77e-01  -2.5 8.37e-02   0.4 1.00e+00 9.90e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 120  1.4300874e+03 3.32e-04 3.86e+01  -2.5 2.41e-01  -0.1 1.00e+00 2.63e-01f  1
 121  1.4165327e+03 4.18e-04 4.12e+01  -2.5 6.62e-01  -0.6 5.38e-01 8.83e-02f  1
 122  1.3956178e+03 6.43e-04 3.13e+01  -2.5 2.63e-01  -0.1 8.12e-01 3.59e-01f  1
 123  1.3737474e+03 1.23e-03 3.34e+01  -2.5 7.06e-01  -0.6 5.43e-01 1.75e-01f  1
 124  1.3551125e+03 1.41e-03 2.73e+01  -2.5 2.69e-01  -0.2 8.32e-01 4.15e-01f  1
 125  1.3498510e+03 1.01e-03 3.47e+01  -2.5 9.26e-02   0.2 1.00e+00 3.35e-01f  1
 126  1.3418493e+03 1.03e-03 3.47e+01  -2.5 2.48e-01  -0.2 7.11e-01 2.38e-01f  1
 127  1.3196772e+03 2.70e-03 2.64e+01  -2.5 6.66e-01  -0.7 3.39e-01 2.72e-01f  1
 128  1.3158288e+03 2.72e-03 2.98e+01  -2.5 1.84e+00  -1.2 1.60e-01 1.89e-02f  1
 129  1.3025329e+03 3.05e-03 2.50e+01  -2.5 6.96e-01  -0.8 1.90e-01 1.76e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 130  1.2965755e+03 2.95e-03 2.63e+01  -2.5 4.34e+00  -1.2 1.14e-01 3.03e-02f  1
 131  1.2866777e+03 2.57e-03 2.09e+01  -2.5 8.25e-01  -0.8 4.58e-02 1.27e-01f  1
 132  1.2777333e+03 2.15e-03 2.25e+01  -2.5 4.05e-01  -0.4 5.41e-01 2.92e-01f  1
 133  1.2711780e+03 1.80e-03 2.25e+01  -2.5 2.34e-01   0.0 1.00e+00 5.69e-01f  1
 134  1.2689198e+03 1.93e-03 3.35e+01  -2.5 8.00e-01  -0.4 5.10e-01 7.77e-02f  1
 135  1.2676457e+03 1.76e-04 1.21e+01  -2.5 1.56e-02   0.9 9.51e-01 9.07e-01f  1
 136  1.2676473e+03 3.87e-05 8.42e+01  -2.5 1.79e-03   4.0 1.00e+00 1.00e+00h  1
 137  1.2676474e+03 1.54e-05 1.50e+02  -2.5 2.96e-03   4.5 5.18e-01 1.00e+00f  1
 138  1.2676448e+03 1.56e-03 1.05e+04  -2.5 3.47e-02   4.0 1.00e+00 1.00e+00f  1
 139  1.2676390e+03 3.20e-04 2.30e+03  -2.5 2.10e-02   3.5 1.00e+00 1.00e+00h  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 140  1.2676265e+03 3.50e-05 6.11e+02  -2.5 1.02e-02   3.0 1.00e+00 1.00e+00h  1
 141  1.2675925e+03 2.36e-05 1.59e+02  -2.5 4.31e-03   2.5 1.00e+00 1.00e+00f  1
 142  1.2674941e+03 3.14e-05 2.62e+01  -2.5 1.07e-03   2.1 1.00e+00 1.00e+00f  1
 143  1.2672142e+03 8.56e-06 2.96e+01  -2.5 3.01e-03   1.6 1.00e+00 1.00e+00f  1
 144  1.2664294e+03 8.89e-06 8.40e+00  -2.5 9.11e-03   1.1 1.00e+00 1.00e+00f  1
 145  1.2642678e+03 5.21e-05 4.07e-01  -2.5 2.70e-02   0.6 1.00e+00 1.00e+00f  1
 146  1.2581090e+03 3.73e-04 1.17e-01  -2.5 7.99e-02   0.2 1.00e+00 1.00e+00f  1
 147  1.2536180e+03 3.81e-04 3.82e+01  -2.5 2.36e-01  -0.3 1.00e+00 2.56e-01f  1
 148  1.2477186e+03 3.94e-04 3.52e+01  -2.5 6.78e-01  -0.8 2.58e-01 1.24e-01f  1
 149  1.2399618e+03 7.15e-04 3.31e+01  -2.5 1.85e+00  -1.3 9.34e-02 7.15e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 150  1.2391203e+03 6.10e-04 3.01e+01  -2.5 8.84e-02   0.1 2.77e-01 1.56e-01f  1
 151  1.2365711e+03 5.73e-04 2.52e+01  -2.5 2.45e-01  -0.4 1.76e-01 1.68e-01f  1
 152  1.2302605e+03 1.83e-03 2.18e+01  -2.5 8.94e-01  -0.9 1.61e-01 1.48e-01f  1
 153  1.2224414e+03 2.69e-03 2.13e+01  -2.5 1.99e+00  -1.4 1.09e-01 7.34e-02f  1
 154  1.2191867e+03 2.76e-03 2.50e+01  -2.5 7.36e-01  -0.9 2.61e-01 7.97e-02f  1
 155  1.2106580e+03 3.70e-03 2.25e+01  -2.5 2.45e+00  -1.4 6.81e-02 8.44e-02f  1
 156  1.2083245e+03 3.63e-03 2.39e+01  -2.5 8.42e-01  -1.0 1.63e-01 6.55e-02f  1
 157  1.2035856e+03 3.94e-03 2.34e+01  -2.5 3.46e+00  -1.5 9.05e-02 5.64e-02f  1
 158  1.1991227e+03 4.57e-03 2.55e+01  -2.5 1.17e+00  -1.0 3.15e-01 1.32e-01f  1
 159  1.1933142e+03 7.42e-03 2.34e+01  -2.5 4.40e+00  -1.5 7.19e-02 7.65e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 160  1.1919710e+03 7.26e-03 2.36e+01  -2.5 1.46e+00  -1.1 9.56e-02 4.90e-02f  1
 161  1.1839303e+03 1.18e-02 2.04e+01  -2.5 3.20e+00  -1.6 1.04e-01 1.18e-01f  1
 162  1.1815940e+03 1.12e-02 1.89e+01  -2.5 1.21e+00  -1.2 1.05e-01 9.26e-02f  1
 163  1.1806864e+03 1.11e-02 2.06e+01  -2.5 3.24e+00  -1.6 7.47e-02 1.60e-02f  1
 164  1.1769223e+03 1.12e-02 1.26e+01  -2.5 1.31e+00  -1.2 2.53e-02 1.75e-01f  1
 165  1.1736637e+03 1.20e-02 1.48e+01  -2.5 3.21e+00  -1.7 1.39e-01 5.97e-02f  1
 166  1.1727945e+03 1.18e-02 1.72e+01  -2.5 1.15e+01  -2.2 7.80e-02 9.72e-03f  1
 167  1.1686713e+03 1.08e-02 1.62e+01  -2.5 3.32e+00  -1.7 1.29e-01 1.07e-01f  1
 168  1.1679248e+03 1.03e-02 1.49e+01  -2.5 8.87e-01  -1.3 2.77e-02 4.43e-02f  1
 169  1.1663288e+03 9.78e-03 1.43e+01  -2.5 2.28e+00  -1.8 5.39e-02 4.89e-02f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 170  1.1652814e+03 8.97e-03 1.94e+01  -2.5 8.56e-01  -1.4 2.50e-01 8.33e-02f  1
 171  1.1642213e+03 6.97e-03 2.06e+01  -2.5 3.07e-01  -0.9 3.93e-01 2.22e-01f  1
 172  1.1609728e+03 5.00e-03 1.30e+01  -2.5 9.49e-01  -1.4 2.25e-01 2.83e-01f  1
 173  1.1574103e+03 4.71e-03 1.09e+01  -2.5 2.80e+00  -1.9 1.21e-01 1.32e-01f  1
 174  1.1540011e+03 5.18e-03 9.23e+00  -2.5 1.04e+00  -1.5 3.35e-01 2.96e-01f  1
 175  1.1523907e+03 3.43e-03 1.55e+01  -2.5 3.35e-01  -1.0 6.51e-01 4.16e-01f  1
 176  1.1504710e+03 3.52e-03 1.99e+01  -2.5 9.50e-01  -1.5 4.22e-01 2.12e-01f  1
 177  1.1475558e+03 2.48e-03 6.14e+00  -2.5 3.61e-01  -1.1 9.62e-01 8.59e-01f  1
 178  1.1430276e+03 8.92e-03 9.87e+00  -2.5 1.10e+00  -1.6 7.28e-01 5.68e-01f  1
 179  1.1428439e+03 1.68e-04 2.47e+01  -2.5 7.48e-02  -0.2 4.02e-01 1.00e+00h  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 180  1.1418173e+03 4.53e-04 2.23e+00  -2.5 1.48e-01  -0.7 9.71e-01 1.00e+00f  1
 181  1.1391057e+03 3.93e-03 2.41e+00  -2.5 4.35e-01  -1.2 1.00e+00 1.00e+00f  1
 182  1.1367858e+03 6.48e-03 2.89e+00  -2.5 1.17e+00  -1.7 4.03e-01 3.75e-01f  1
 183  1.1355444e+03 3.97e-03 7.93e+00  -2.5 4.15e-01  -1.2 4.01e-01 5.74e-01f  1
 184  1.1338700e+03 5.83e-03 3.43e+01  -2.5 1.18e+00  -1.7 1.00e+00 3.26e-01f  1
 185  1.1320604e+03 3.89e-03 2.14e-01  -2.5 4.25e-01  -1.3 1.00e+00 1.00e+00f  1
 186  1.1306842e+03 5.24e-03 1.45e+01  -2.5 1.01e+00  -1.8 6.69e-01 3.83e-01f  1
 187  1.1296041e+03 3.13e-03 9.93e+00  -2.5 4.00e-01  -1.3 1.00e+00 8.71e-01f  1
 188  1.1292183e+03 4.64e-04 1.99e+00  -2.5 1.51e-01  -0.9 1.00e+00 1.00e+00h  1
 189  1.1282366e+03 2.74e-03 4.28e+00  -2.5 4.29e-01  -1.4 1.00e+00 9.16e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 190  1.1266451e+03 1.25e-02 8.10e+00  -2.5 1.19e+00  -1.9 4.95e-01 6.98e-01f  1
 191  1.1260389e+03 1.36e-02 4.19e+01  -2.5 2.92e+00  -2.3 9.81e-01 1.49e-01h  1
 192  1.1244310e+03 5.19e-02 6.62e+00  -2.5 1.26e+00  -1.9 4.24e-01 1.00e+00h  1
 193  1.1244881e+03 3.37e-02 2.20e+03  -2.5 1.03e+00   0.3 1.37e-01 7.38e-01h  1
 194  1.1245189e+03 3.81e-03 5.34e+02  -2.5 2.70e-01   0.7 1.00e+00 1.00e+00h  1
 195  1.1245068e+03 1.17e-03 8.73e+01  -2.5 1.89e-01   0.3 1.00e+00 1.00e+00h  1
 196  1.1244683e+03 2.33e-05 2.30e+00  -2.5 3.20e-02  -0.2 1.00e+00 1.00e+00h  1
 197  1.1243552e+03 1.54e-04 1.71e-02  -2.5 8.42e-02  -0.7 1.00e+00 1.00e+00f  1
 198  1.1190994e+03 6.09e-04 1.51e+00  -3.8 2.82e-01  -1.2 5.92e-01 6.86e-01f  1
 199  1.1180288e+03 8.34e-04 2.92e+00  -3.8 6.39e-01  -1.6 4.57e-01 2.24e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 200  1.1159998e+03 7.95e-03 4.85e+00  -3.8 1.57e+00  -2.1 5.44e-01 3.25e-01f  1
 201  1.1147116e+03 6.52e-03 6.39e+00  -3.8 6.37e-01  -1.7 7.88e-01 4.54e-01f  1
 202  1.1141096e+03 3.62e-03 2.20e+00  -3.8 2.46e-01  -1.3 1.18e-01 5.01e-01h  1
 203  1.1139708e+03 3.40e-03 3.80e+00  -3.8 6.49e-01  -1.7 3.48e-01 9.09e-02h  1
 204  1.1136362e+03 2.51e-05 6.03e-01  -3.8 3.60e-02  -0.4 1.00e+00 1.00e+00h  1
 205  1.1133723e+03 2.70e-04 2.79e-02  -3.8 1.02e-01  -0.9 1.00e+00 1.00e+00f  1
 206  1.1133151e+03 3.71e-05 3.43e-02  -3.8 3.74e-02  -0.5 1.00e+00 1.00e+00h  1
 207  1.1131350e+03 3.29e-04 2.78e-01  -3.8 1.09e-01  -0.9 1.00e+00 1.00e+00f  1
 208  1.1127639e+03 1.69e-03 5.67e+00  -3.8 3.05e-01  -1.4 4.09e-01 7.62e-01f  1
 209  1.1124053e+03 3.18e-03 1.36e+00  -3.8 8.06e-01  -1.9 5.54e-01 3.11e-01f  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 210  1.1118494e+03 8.48e-03 5.05e+00  -3.8 1.95e+00  -2.4 4.87e-01 2.16e-01f  1
 211  1.1114165e+03 1.22e-02 4.92e+00  -3.8 4.02e+00  -2.9 1.21e-01 9.06e-02f  1
 212  1.1111748e+03 1.31e-02 5.94e+00  -3.8 8.10e+00  -3.3 1.38e-01 3.23e-02f  1
 213  1.1109347e+03 1.32e-02 7.87e+00  -3.8 6.67e+00  -2.9 2.79e-01 5.54e-02h  1
 214  1.1104649e+03 1.65e-02 7.34e+00  -3.8 7.56e+00  -3.4 9.00e-02 7.91e-02f  1
 215  1.1103271e+03 1.65e-02 1.07e+01  -3.8 4.06e+00  -3.0 4.62e-01 4.32e-02h  1
 216  1.1098444e+03 2.77e-02 9.93e+00  -3.8 7.43e+00  -3.4 1.62e-01 1.01e-01h  1
 217  1.1098538e+03 1.90e-02 1.18e+01  -3.8 5.39e-02  -0.3 3.23e-01 3.16e-01h  1
 218  1.1098809e+03 1.10e-05 5.82e+00  -3.8 1.11e-02   0.1 1.00e+00 1.00e+00h  1
 219  1.1098622e+03 1.08e-05 1.06e+00  -3.8 1.90e-02  -0.4 1.00e+00 1.00e+00h  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 220  1.1098107e+03 5.25e-05 2.18e-01  -3.8 5.49e-02  -0.8 1.00e+00 1.00e+00h  1
 221  1.1096817e+03 4.04e-04 1.06e+00  -3.8 1.64e-01  -1.3 1.00e+00 9.34e-01h  1
 222  1.1095749e+03 6.50e-04 1.10e+01  -3.8 4.73e-01  -1.8 1.00e+00 3.17e-01f  1
 223  1.1095621e+03 8.31e-06 1.21e+00  -3.8 2.29e-02  -0.5 7.63e-01 1.00e+00h  1
 224  1.1095140e+03 7.70e-05 1.21e-01  -3.8 6.81e-02  -0.9 1.00e+00 1.00e+00h  1
 225  1.1093825e+03 6.62e-04 1.60e-01  -3.8 2.01e-01  -1.4 1.00e+00 1.00e+00h  1
 226  1.1093364e+03 6.74e-04 1.37e+01  -3.8 5.66e-01  -1.9 1.00e+00 1.44e-01h  1
 227  1.1092690e+03 5.38e-04 7.05e+00  -3.8 2.20e-01  -1.5 1.00e+00 5.60e-01h  1
 228  1.1090343e+03 3.55e-03 5.58e-01  -3.8 6.20e-01  -1.9 5.37e-01 7.49e-01f  1
 229  1.1087697e+03 8.51e-03 3.15e+00  -3.8 1.59e+00  -2.4 6.12e-01 4.12e-01h  1
iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
 230  1.1087608e+03 3.38e-03 6.31e+00  -3.8 8.48e-02  -1.1 1.00e+00 6.07e-01h  1
 231  1.1087556e+03 1.19e-05 3.16e-01  -3.8 3.19e-02  -0.7 1.00e+00 1.00e+00h  1
 232  1.1087186e+03 1.25e-04 1.24e-02  -3.8 9.27e-02  -1.1 1.00e+00 1.00e+00h  1

Number of Iterations....: 232

                                   (scaled)                 (unscaled)
Objective...............:   1.1087186343198964e+03    1.1087186343198964e+03
Dual infeasibility......:   1.2357098800516109e-02    1.2357098800516109e-02
Constraint violation....:   1.2474641167337097e-04    1.2474641167337097e-04
Variable bound violation:   6.5439683696740520e-09    6.5439683696740520e-09
Complementarity.........:   1.5237086683517976e-04    1.5237086683517976e-04
Overall NLP error.......:   5.0040582267332004e-03    1.2357098800516109e-02


Number of objective function evaluations             = 238
Number of objective gradient evaluations             = 233
Number of equality constraint evaluations            = 238
Number of inequality constraint evaluations          = 239
Number of equality constraint Jacobian evaluations   = 233
Number of inequality constraint Jacobian evaluations = 233
Number of Lagrangian Hessian evaluations             = 232
Total seconds in IPOPT (w/o function evaluations)    =     61.769
Total seconds in NLP function evaluations            =     69.785


Timing Statistics:

OverallAlgorithm....................:    131.553 (sys:      0.000 wall:    131.553)
 PrintProblemStatistics.............:      0.001 (sys:      0.000 wall:      0.001)
 InitializeIterates.................:      0.140 (sys:      0.000 wall:      0.140)
 UpdateHessian......................:     41.388 (sys:      0.000 wall:     41.388)
 OutputIteration....................:      0.348 (sys:      0.000 wall:      0.348)
 UpdateBarrierParameter.............:      0.155 (sys:      0.000 wall:      0.155)
 ComputeSearchDirection.............:     57.473 (sys:      0.000 wall:     57.474)
 ComputeAcceptableTrialPoint........:     23.227 (sys:      0.000 wall:     23.227)
 AcceptTrialPoint...................:      0.155 (sys:      0.000 wall:      0.155)
 CheckConvergence...................:      8.666 (sys:      0.000 wall:      8.666)
PDSystemSolverTotal.................:     57.125 (sys:      0.000 wall:     57.125)
 PDSystemSolverSolveOnce............:     53.360 (sys:      0.000 wall:     53.361)
 ComputeResiduals...................:      3.091 (sys:      0.000 wall:      3.091)
 StdAugSystemSolverMultiSolve.......:     52.663 (sys:      0.000 wall:     52.664)
 LinearSystemScaling................:      0.000 (sys:      0.000 wall:      0.000)
 LinearSystemSymbolicFactorization..:      0.129 (sys:      0.000 wall:      0.129)
 LinearSystemFactorization..........:     44.336 (sys:      0.000 wall:     44.336)
 LinearSystemBackSolve..............:      5.916 (sys:      0.000 wall:      5.918)
 LinearSystemStructureConverter.....:      0.000 (sys:      0.000 wall:      0.000)
  LinearSystemStructureConverterInit:      0.000 (sys:      0.000 wall:      0.000)
QualityFunctionSearch...............:      0.000 (sys:      0.000 wall:      0.000)
TryCorrector........................:      0.000 (sys:      0.000 wall:      0.000)
Task1...............................:      0.000 (sys:      0.000 wall:      0.000)
Task2...............................:      0.000 (sys:      0.000 wall:      0.000)
Task3...............................:      0.000 (sys:      0.000 wall:      0.000)
Task4...............................:      0.000 (sys:      0.000 wall:      0.000)
Task5...............................:      0.000 (sys:      0.000 wall:      0.000)
Task6...............................:      0.000 (sys:      0.000 wall:      0.000)
Function Evaluations................:     69.785 (sys:      0.000 wall:     69.785)
 Objective function.................:      0.010 (sys:      0.000 wall:      0.010)
 Objective function gradient........:      0.096 (sys:      0.000 wall:      0.096)
 Equality constraints...............:     21.362 (sys:      0.000 wall:     21.362)
 Inequality constraints.............:      0.029 (sys:      0.000 wall:      0.029)
 Equality constraint Jacobian.......:      0.172 (sys:      0.000 wall:      0.172)
 Inequality constraint Jacobian.....:      6.962 (sys:      0.000 wall:      6.962)
 Lagrangian Hessian.................:     41.154 (sys:      0.000 wall:     41.154)

EXIT: Optimal Solution Found.

Hi @tso-martin, welcome to the forum.

Can you provide a reproducible example? What happens if you use a different linear solver?

Is something special about the equality constraints?

Is there any chance you can provide a good starting point that satisfies most (or all) of the constraints?

From a quick glance at the Ipopt log, the number of iterations to convergence seems high (but not clearly unreasonable). I would say around 50-100 is more typical (in my experience) for a well posed AC OPF type of problem.

Given that you said you are doing SCOPF, my first thought is do you have a lot of equality constraints of the form x_{first stage} == x_{contingency stage} in the model? This can slow down Ipopt’s convergence a lot because it does not have a pre-solver to eliminate variables. You would want to do the variable replacement in your optimization modeling layer.

Another thought is the quality of the network data you are using. Very small or very large values on any of the power components (e.g., shunts, branches) can be problematic. I would do some data analysis on your network model to see if there any parameters can the be cleaned up.

1 Like

Thank you for the first hints. You can checkout the “minimal” working example in https://github.com/tso-martin/example_scopf.git. The problem itself is a multiperiod SCOPF for an adapted case39 network modelled with PowerModels (ACPPowerModel).

The equality constraints are special in way, that they contain non-linear sine and cosine terms (constraint_ohms_y_pst_from).

JuMP.@NLconstraint(pm.model, p_fr ==  (g+g_fr)/tm^2*vm_fr^2 + (-g)/tm*(vm_fr*vm_to*cos(va_fr-va_to-ta)) + (-b)/tm*(vm_fr*vm_to*sin(va_fr-va_to-ta)) )
JuMP.@NLconstraint(pm.model, q_fr == -(b+b_fr)/tm^2*vm_fr^2 - (-b)/tm*(vm_fr*vm_to*cos(va_fr-va_to-ta)) + (-g)/tm*(vm_fr*vm_to*sin(va_fr-va_to-ta)) )

I checked with linear solvers MUMPS, MA57 and MA97. They all require more than 150 iterations.

I warm-start the primal values by using single-period OPF results.

Concerning the equality constraints, I will have a look into that.

I would recommend a flat start instead (i.e., vm = 1; va, pg, qg = 0.0). This tends to have the best behavior in AC-OPF with Ipopt.

Thanks again for your help. I tested the flat start and got slight performance improvements.

1 Like