IEA Wind Task 55¶
This notebook applies OptiWindNet to design collector system networks for the two offshore wind plants described in the IEA Wind TCP Task 55 report (740 MW, 10 MW turbines). Using both regular and irregular turbine layouts in WindIO format, we use HGSRouter for warmstarting and MILPRouter (OR-Tools solver) for final optimization.
For more info about IEA Wind TCP Task 55: The IEA Wind 740-10-MW Reference Offshore Wind Plants read: https://www.osti.gov/biblio/2333634/
Load required data¶
Import required modules¶
[1]:
import numpy as np
from optiwindnet.api import WindFarmNetwork, HGSRouter, MILPRouter, ModelOptions
[2]:
# Display figures as SVG in Jupyter notebooks
%config InlineBackend.figure_formats = ['svg']
Cable data¶
[3]:
cables = [(2, 1500.0), (5, 1800.0), (7, 2000.0)]
Load turbine layouts¶
Load turbine layouts from windIO yaml files (Regular and Irregular turbine layouts)
[4]:
wfn_reg = WindFarmNetwork.from_windIO(filepath='data/IEA37_Borssele_Regular_System.yaml', cables=cables)
[5]:
wfn_irr = WindFarmNetwork.from_windIO(filepath='data/IEA37_Borssele_Irregular_System.yaml', cables=cables)
Plot locations’ geometry.¶
[6]:
wfn_reg
[6]:
[7]:
wfn_irr
[7]:
Choose the warmstart and main router¶
[8]:
warmstart_router = HGSRouter(time_limit=1, verbose=True)
solver_options=dict(
num_workers = 8,
)
model_options = ModelOptions(
topology='branched',
feeder_limit='unlimited',
feeder_route='segmented',
)
milp_router = MILPRouter(solver_name='ortools.cp_sat', time_limit=5, mip_gap=0.005, solver_options=solver_options, model_options=model_options, verbose=True)
For a detailed explanation about model_options and solver_options of MILP routers see Model Options and OR-Tools example Notebooks.
Regular turbine layout¶
Warmstart¶
[9]:
res_reg_warm = wfn_reg.optimize(router=warmstart_router)
Check the total length of the warm-start solution:
[10]:
wfn_reg.length()
[10]:
139656.4789599965
Optimize with MILP router¶
[11]:
res_reg = wfn_reg.optimize(router=milp_router, verbose=True)
IntegerBoundsPreprocessor 2374 rows, 1536 columns, 8830 entries with magnitude in [1.000000e+00, 7.000000e+00]
BoundPropagationPreprocessor 2374 rows, 1536 columns, 8830 entries with magnitude in [1.000000e+00, 7.000000e+00]
ImpliedIntegerPreprocessor 2374 rows, 1536 columns, 8830 entries with magnitude in [1.000000e+00, 7.000000e+00]
IntegerBoundsPreprocessor 2374 rows, 1536 columns, 8830 entries with magnitude in [1.000000e+00, 7.000000e+00]
ReduceCostOverExclusiveOrConstraintPreprocessor 2374 rows, 1536 columns, 8830 entries with magnitude in [1.000000e+00, 7.000000e+00]
Scaling to pure integer problem.
Num integers: 1536/1536 (implied: 0 in_inequalities: 0 max_scaling: 0) [IP]
Maximum constraint coefficient relative error: 0
Maximum constraint worst-case activity error: 0
Constraint scaling factor range: [1, 1]
Starting CP-SAT solver v9.15.6755
Parameters: max_time_in_seconds: 5 log_search_progress: true catch_sigint_signal: false relative_gap_limit: 0.005 num_workers: 8
Initial optimization model 'optiwindnet': (model_fingerprint: 0xb655863d792c57be)
#Variables: 1'536 (#bools: 694 in floating point objective) (1'388 primary variables)
- 768 Booleans in [0,1]
- 694 in [0,6]
- 74 in [0,7]
#kLinear2: 1'883
#kLinear3: 2
#kLinearN: 489 (#terms: 5'058)
Starting presolve at 0.00s
The solution hint is complete and is feasible.
[Scaling] Floating point objective has 694 terms with magnitude in [2.68679e-05, 12860.2] average = 1324.72
[Scaling] Objective coefficient relative error: 0.00889319
[Scaling] Objective worst-case absolute error: 8.61506e-05
[Scaling] Objective scaling factor: 1.04858e+06
4.04e-04s 0.00e+00d [DetectDominanceRelations]
1.23e-02s 0.00e+00d [PresolveToFixPoint] #num_loops=2 #num_dual_strengthening=1
3.95e-05s 0.00e+00d [ExtractEncodingFromLinear] #potential_supersets=340
1.79e-04s 0.00e+00d [DetectDuplicateColumns]
1.54e-04s 0.00e+00d [DetectDuplicateConstraints]
[Symmetry] Graph for symmetry has 5'793 nodes and 11'060 arcs.
[Symmetry] Symmetry computation done. time: 0.000747763 dtime: 0.00135785
[SAT presolve] num removable Booleans: 0 / 768
[SAT presolve] num trivial clauses: 0
[SAT presolve] [0s] clauses:347 literals:694 vars:694 one_side_vars:694 simple_definition:0 singleton_clauses:0
[SAT presolve] [1.6957e-05s] clauses:347 literals:694 vars:694 one_side_vars:694 simple_definition:0 singleton_clauses:0
[SAT presolve] [2.9706e-05s] clauses:347 literals:694 vars:694 one_side_vars:694 simple_definition:0 singleton_clauses:0
1.84e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
2.09e-02s 1.03e-02d [Probe] #probed=3'072 #new_binary_clauses=768
7.96e-04s 5.67e-04d [MaxClique] Merged 613 constraints with 1'918 literals into 303 constraints with 1'298 literals
3.46e-04s 0.00e+00d [DetectDominanceRelations]
3.99e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
1.14e-03s 0.00e+00d [ProcessAtMostOneAndLinear] #num_changes=768
1.62e-04s 0.00e+00d [DetectDuplicateConstraints]
1.46e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
2.42e-04s 1.32e-05d [DetectDominatedLinearConstraints] #relevant_constraints=151 #num_inclusions=75
3.53e-05s 0.00e+00d [DetectDifferentVariables]
2.46e-03s 3.03e-04d [ProcessSetPPC] #relevant_constraints=379 #num_inclusions=377
1.23e-04s 0.00e+00d [TransformClausesToExactlyOne] #num_amos=303
4.63e-04s 0.00e+00d [DetectEncodedComplexDomains]
2.45e-05s 0.00e+00d [FindAlmostIdenticalLinearConstraints]
2.22e-04s 2.40e-04d [FindBigAtMostOneAndLinearOverlap]
1.58e-04s 2.83e-04d [FindBigVerticalLinearOverlap]
2.03e-05s 1.15e-05d [FindBigHorizontalLinearOverlap] #linears=148
1.00e-05s 0.00e+00d [MergeClauses]
3.67e-04s 0.00e+00d [DetectDominanceRelations]
4.67e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=2 #num_dual_strengthening=1
5.09e-04s 0.00e+00d [DetectDominanceRelations]
2.99e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
1.02e-04s 0.00e+00d [DetectDuplicateColumns]
2.70e-04s 0.00e+00d [DetectDuplicateConstraints]
[Symmetry] Graph for symmetry has 5'168 nodes and 9'048 arcs.
[Symmetry] Symmetry computation done. time: 0.000518133 dtime: 0.00121763
[SAT presolve] num removable Booleans: 0 / 768
[SAT presolve] num trivial clauses: 0
[SAT presolve] [0s] clauses:37 literals:74 vars:74 one_side_vars:74 simple_definition:0 singleton_clauses:0
[SAT presolve] [8.717e-06s] clauses:37 literals:74 vars:74 one_side_vars:74 simple_definition:0 singleton_clauses:0
[SAT presolve] [2.4613e-05s] clauses:37 literals:74 vars:74 one_side_vars:74 simple_definition:0 singleton_clauses:0
3.45e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
9.75e-03s 3.41e-03d [Probe] #probed=1'536
7.35e-04s 3.83e-04d [MaxClique]
6.41e-04s 0.00e+00d [DetectDominanceRelations]
2.96e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
2.03e-04s 0.00e+00d [ProcessAtMostOneAndLinear]
1.79e-04s 0.00e+00d [DetectDuplicateConstraints]
1.71e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
2.22e-04s 9.95e-06d [DetectDominatedLinearConstraints] #relevant_constraints=150 #num_inclusions=74
4.58e-05s 0.00e+00d [DetectDifferentVariables]
1.73e-04s 6.96e-06d [ProcessSetPPC] #relevant_constraints=378
1.59e-04s 0.00e+00d [TransformClausesToExactlyOne] #num_amos=303
5.96e-04s 0.00e+00d [DetectEncodedComplexDomains]
4.83e-05s 0.00e+00d [FindAlmostIdenticalLinearConstraints]
7.97e-04s 2.37e-04d [FindBigAtMostOneAndLinearOverlap]
2.02e-04s 2.83e-04d [FindBigVerticalLinearOverlap]
2.77e-05s 1.15e-05d [FindBigHorizontalLinearOverlap] #linears=148
1.26e-05s 0.00e+00d [MergeClauses]
4.35e-04s 0.00e+00d [DetectDominanceRelations]
3.22e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
5.46e-06s 0.00e+00d [MergeNoOverlap]
6.24e-06s 0.00e+00d [MergeNoOverlap2D]
3.25e-04s 0.00e+00d [ExpandObjective] #entries=7'628 #tight_variables=768 #tight_constraints=74
Presolve summary:
- 0 affine relations were detected.
- rule 'TODO linear inclusion: superset is equality' was applied 149 times.
- rule 'TODO linear2: convert ax + by != cte to clauses for large domains' was applied 4'608 times.
- rule 'at_most_one: transformed into max clique' was applied 1 time.
- rule 'bool_or: implications' was applied 347 times.
- rule 'deductions: 1536 stored' was applied 1 time.
- rule 'linear + amo: extracted enforcement literal' was applied 768 times.
- rule 'linear2: contains a boolean' was applied 768 times.
- rule 'linear2: convert ax + by != cte to clauses' was applied 347 times.
- rule 'linear: positive at most one' was applied 266 times.
- rule 'linear: positive equal one' was applied 74 times.
- rule 'objective: shifted cost with exactly ones' was applied 74 times.
- rule 'presolve: 0 unused variables removed.' was applied 1 time.
- rule 'presolve: iteration' was applied 2 times.
- rule 'setppc: exactly_one included in linear' was applied 74 times.
- rule 'setppc: reduced linear coefficients' was applied 73 times.
- rule 'setppc: removed trivial linear constraint' was applied 1 time.
- rule 'variables: detect fully reified value encoding' was applied 768 times.
- rule 'variables: detect half reified value encoding' was applied 1'536 times.
Presolved optimization model 'optiwindnet': (model_fingerprint: 0x20eb10e88c6e1c3b)
#Variables: 1'536 (#bools: 694 in objective) (1'388 primary variables)
- 768 Booleans in [0,1]
- 694 in [0,6]
- 74 in [0,7]
#kAtMostOne: 266 (#literals: 1'224)
#kBoolAnd: 37 (#enforced: 37) (#literals: 74)
#kExactlyOne: 74 (#literals: 768)
#kLinear1: 1'536 (#enforced: 1'536)
#kLinear3: 2
#kLinearN: 148 (#terms: 2'298)
[Symmetry] Graph for symmetry has 5'168 nodes and 9'048 arcs.
[Symmetry] Symmetry computation done. time: 0.00115577 dtime: 0.00121072
Preloading model.
#Bound 0.08s best:inf next:[123610.947,1028471.61] initial_domain
#1 0.08s best:139656.479 next:[123610.947,139656.479] complete_hint
#Model 0.09s var:1536/1536 constraints:2063/2063
Starting search at 0.09s with 8 workers.
6 full problem subsolvers: [core, default_lp, max_lp, no_lp, quick_restart, reduced_costs]
2 first solution subsolvers: [fj, fs_random_no_lp]
9 interleaved subsolvers: [feasibility_pump, graph_arc_lns, graph_cst_lns, graph_dec_lns, graph_var_lns, ls, rins/rens, rnd_cst_lns, rnd_var_lns]
3 helper subsolvers: [neighborhood_helper, synchronization_agent, update_gap_integral]
#Bound 0.11s best:139656.479 next:[123610.951,139656.479] am1_presolve (num_literals=694 num_am1=20 increase=4452 work_done=2551)
#Bound 0.11s best:139656.479 next:[131572.565,139656.479] quick_restart
#Bound 0.11s best:139656.479 next:[131572.567,139656.479] default_lp
#Bound 0.11s best:139656.479 next:[131572.568,139656.479] reduced_costs
#Model 0.12s var:1528/1536 constraints:2055/2063
#2 0.15s best:139650.831 next:[131572.568,139650.831] rnd_cst_lns (d=7.07e-01 s=15 t=0.10 p=1.00 stall=1 h=base)
#Bound 0.16s best:139650.831 next:[135687.687,139650.831] max_lp
#Bound 0.26s best:139650.831 next:[135855.016,139650.831] max_lp
#Bound 0.29s best:139650.831 next:[135928.998,139650.831] max_lp
#Bound 0.30s best:139650.831 next:[135929.655,139650.831] max_lp
#Model 0.30s var:1484/1536 constraints:2009/2063
#3 0.52s best:139645.183 next:[135929.655,139645.183] graph_arc_lns (d=7.07e-01 s=17 t=0.10 p=1.00 stall=1 h=base)
#Bound 0.59s best:139645.183 next:[136104.997,139645.183] quick_restart
#Bound 0.64s best:139645.183 next:[136135.778,139645.183] quick_restart
#Bound 0.68s best:139645.183 next:[136164.333,139645.183] quick_restart
#Model 0.69s var:1474/1536 constraints:1999/2063
#Bound 0.75s best:139645.183 next:[136241.57,139645.183] quick_restart
#Bound 0.79s best:139645.183 next:[136265.263,139645.183] quick_restart
#Model 0.79s var:1472/1536 constraints:1997/2063
#Bound 1.00s best:139645.183 next:[136357.122,139645.183] quick_restart
#Bound 1.72s best:139645.183 next:[136383.539,139645.183] quick_restart
#Bound 1.97s best:139645.183 next:[136395.825,139645.183] quick_restart
#Bound 2.58s best:139645.183 next:[136401.776,139645.183] quick_restart
#Bound 2.81s best:139645.183 next:[136427.557,139645.183] quick_restart
#Bound 2.85s best:139645.183 next:[136441.913,139645.183] quick_restart
#Bound 2.88s best:139645.183 next:[136442.502,139645.183] quick_restart
#Bound 3.17s best:139645.183 next:[136473.906,139645.183] quick_restart
#Bound 4.02s best:139645.183 next:[136490.778,139645.183] quick_restart
#Bound 4.32s best:139645.183 next:[136515.86,139645.183] quick_restart
Task timing n [ min, max] avg dev time n [ min, max] avg dev dtime
'core': 1 [ 4.91s, 4.91s] 4.91s 0.00ns 4.91s 2 [ 3.51ms, 3.26s] 1.63s 1.63s 3.27s
'default_lp': 1 [ 4.91s, 4.91s] 4.91s 0.00ns 4.91s 2 [ 97.26ms, 2.80s] 1.45s 1.35s 2.90s
'feasibility_pump': 11 [ 66.55us, 65.42ms] 7.66ms 18.29ms 84.31ms 9 [318.71us, 50.34ms] 5.90ms 15.71ms 53.08ms
'fj': 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns
'fs_random_no_lp': 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns
'graph_arc_lns': 7 [ 11.53ms, 339.80ms] 174.05ms 138.60ms 1.22s 7 [ 6.06us, 100.33ms] 57.63ms 49.09ms 403.42ms
'graph_cst_lns': 8 [ 13.65ms, 345.57ms] 152.68ms 133.72ms 1.22s 8 [ 70.85us, 100.10ms] 44.55ms 44.23ms 356.43ms
'graph_dec_lns': 11 [ 1.23ms, 327.92ms] 110.62ms 125.64ms 1.22s 9 [ 10.00ns, 100.05ms] 40.89ms 44.80ms 368.03ms
'graph_var_lns': 9 [ 16.26ms, 346.41ms] 135.25ms 129.98ms 1.22s 9 [560.79us, 100.35ms] 39.83ms 44.38ms 358.44ms
'ls': 10 [ 94.39ms, 138.72ms] 112.54ms 11.50ms 1.13s 10 [100.01ms, 100.02ms] 100.01ms 5.30us 1.00s
'max_lp': 1 [ 4.91s, 4.91s] 4.91s 0.00ns 4.91s 2 [174.33ms, 2.72s] 1.45s 1.27s 2.90s
'no_lp': 1 [ 4.91s, 4.91s] 4.91s 0.00ns 4.91s 2 [ 4.10ms, 2.21s] 1.11s 1.10s 2.21s
'quick_restart': 1 [ 4.91s, 4.91s] 4.91s 0.00ns 4.91s 2 [ 96.75ms, 2.82s] 1.46s 1.36s 2.92s
'reduced_costs': 1 [ 4.92s, 4.92s] 4.92s 0.00ns 4.92s 2 [ 39.02ms, 2.26s] 1.15s 1.11s 2.30s
'rins/rens': 7 [ 13.33ms, 324.11ms] 187.53ms 137.54ms 1.31s 7 [135.62us, 100.17ms] 58.60ms 47.95ms 410.21ms
'rnd_cst_lns': 8 [ 8.46ms, 298.25ms] 154.52ms 127.14ms 1.24s 8 [255.00ns, 100.02ms] 49.86ms 45.82ms 398.87ms
'rnd_var_lns': 8 [ 5.82ms, 341.77ms] 148.01ms 122.40ms 1.18s 8 [ 10.00ns, 100.10ms] 46.10ms 43.11ms 368.77ms
Search stats Bools Conflicts Branches Restarts BacktrackToRoot Backtrack BoolPropag IntegerPropag
'core': 788 131'439 311'501 227 3'479 134'173 2'066'417 5'847'326
'default_lp': 810 259 16'756 4 7'852 8'850 87'745 429'568
'fs_random_no_lp': 0 0 0 0 0 0 0 0
'max_lp': 768 425 8'577 2 4'615 5'208 59'273 277'375
'no_lp': 768 40'190 105'551 128 22'163 63'124 4'069'464 13'424'020
'quick_restart': 792 77 25'567 4 13'719 14'924 122'263 625'027
'reduced_costs': 784 693 22'934 6 10'530 12'064 122'038 611'353
SAT formula Fixed Equiv Total VarLeft BinaryClauses PermanentClauses TemporaryClauses
'core': 32 0 788 756 170 986 5'709
'default_lp': 33 0 810 777 332 149 206
'fs_random_no_lp': 0 0 0 0 0 0 0
'max_lp': 32 0 768 736 110 74 374
'no_lp': 32 0 768 736 114 166 5'482
'quick_restart': 34 0 792 758 270 96 39
'reduced_costs': 32 0 784 752 210 151 618
SAT stats ClassicMinim LitRemoved LitRemovedBinary LitLearned LitForgotten Subsumed
'core': 118'206 898'120 828'488 6'701'524 3'605'350 51'608
'default_lp': 176 2'674 7'048 17'278 0 38
'fs_random_no_lp': 0 0 0 0 0 0
'max_lp': 299 3'324 15'301 54'775 0 49
'no_lp': 37'687 1'645'521 122'785 2'017'466 696'411 21'379
'quick_restart': 35 1'475 1'300 3'108 0 21
'reduced_costs': 539 6'965 21'154 106'866 0 73
Vivification Clauses Decisions LitTrue Subsumed LitRemoved DecisionReused Conflicts
'core': 197 1'474 0 2 18 0 1
'default_lp': 935 7'924 0 27 394 282 2
'fs_random_no_lp': 0 0 0 0 0 0 0
'max_lp': 299 2'658 0 1 5 0 0
'no_lp': 2'432 25'134 0 25 515 1'121 13
'quick_restart': 1'316 11'081 1 4 43 26 0
'reduced_costs': 818 6'936 0 2 23 14 0
Clause deletion at_true l_and_not(l) to_binary sub_conflict sub_extra sub_decisions sub_eager sub_vivify sub_probing sub_inpro blocked eliminated forgotten promoted conflicts
'core': 104 0 1 50'176 843 0 1'432 2 1 290 0 0 71'970 289'822 131'439
'default_lp': 0 0 0 38 1 0 0 27 2 1 0 0 0 424 259
'fs_random_no_lp': 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
'max_lp': 0 0 0 43 1 0 6 1 0 0 0 0 0 911 425
'no_lp': 5 18 0 20'858 144 265 521 25 0 34 0 0 12'838 92'997 40'190
'quick_restart': 1 0 1 18 0 0 3 4 2 0 0 0 0 111 77
'reduced_costs': 0 0 1 72 1 0 1 2 2 6 0 0 0 1'649 693
Lp stats Component Iterations AddedCuts OPTIMAL DUAL_F. DUAL_U.
'default_lp': 1 35'263 2'417 1'136 3 64
'max_lp': 1 42'139 1'187 1'339 174 108
'quick_restart': 1 24'351 2'544 652 5 14
'reduced_costs': 1 38'495 2'230 1'193 206 88
Lp dimension Final dimension of first component
'default_lp': 1438 rows, 1462 columns, 18920 entries
'max_lp': 734 rows, 1536 columns, 5384 entries
'quick_restart': 1611 rows, 1462 columns, 24854 entries
'reduced_costs': 1246 rows, 1536 columns, 14269 entries
Lp debug CutPropag CutEqPropag Adjust Overflow Bad BadScaling
'default_lp': 0 0 1'187 0 7'765 0
'max_lp': 0 1 1'618 0 7'430 0
'quick_restart': 0 1 649 0 11'701 0
'reduced_costs': 0 0 1'472 0 7'967 0
Lp pool Constraints Updates Simplif Merged Shortened Split Strengthened Cuts/Call
'default_lp': 4'989 59 875 0 377 18 23 2'417/4'552
'max_lp': 4'018 91 668 0 462 20 2 1'187/2'378
'quick_restart': 5'116 104 2'036 0 356 154 32 2'544/4'759
'reduced_costs': 5'061 79 969 0 363 28 15 2'230/4'045
Lp Cut max_lp default_lp quick_restart reduced_costs
CG_FF: 5 12 16 21
CG_K: 2 11 9 10
CG_KL: - 1 - 1
CG_R: 19 10 18 31
CG_RB: 41 34 34 42
CG_RBP: 14 13 24 21
IB: 262 929 769 960
MIR_1_FF: 34 94 114 42
MIR_1_K: 1 38 23 6
MIR_1_KL: - 19 19 3
MIR_1_R: - - 4 2
MIR_1_RB: 14 64 65 29
MIR_1_RBP: 6 68 63 7
MIR_2_FF: 49 96 102 87
MIR_2_K: 3 43 48 23
MIR_2_KL: - 14 11 9
MIR_2_R: 4 4 3 10
MIR_2_RB: 58 84 93 94
MIR_2_RBP: 22 46 63 25
MIR_3_FF: 49 50 64 78
MIR_3_K: 9 40 37 25
MIR_3_KL: 1 8 12 6
MIR_3_R: 6 3 4 9
MIR_3_RB: 57 59 69 92
MIR_3_RBP: 15 47 43 11
MIR_4_FF: 44 35 40 43
MIR_4_K: 14 39 53 17
MIR_4_KL: 6 3 6 5
MIR_4_R: 7 6 1 8
MIR_4_RB: 24 34 36 55
MIR_4_RBP: 20 30 61 18
MIR_5_FF: 39 24 23 40
MIR_5_K: 22 30 31 18
MIR_5_KL: 5 3 7 3
MIR_5_R: 8 - 1 5
MIR_5_RB: 20 20 26 31
MIR_5_RBP: 20 37 39 13
MIR_6_FF: 35 19 15 22
MIR_6_K: 28 22 33 19
MIR_6_KL: 3 4 5 7
MIR_6_R: 4 2 1 1
MIR_6_RB: 15 17 21 20
MIR_6_RBP: 17 28 37 17
ZERO_HALF_FF: 20 24 25 33
ZERO_HALF_K: 4 7 7 3
ZERO_HALF_KL: - 2 3 2
ZERO_HALF_R: 140 197 290 178
ZERO_HALF_RB: 18 31 58 26
ZERO_HALF_RBP: 3 16 18 2
LNS stats Improv/Calls Closed Difficulty TimeLimit
'graph_arc_lns': 1/7 43% 4.01e-01 0.10
'graph_cst_lns': 0/8 62% 7.95e-01 0.10
'graph_dec_lns': 0/9 56% 7.73e-01 0.10
'graph_var_lns': 0/9 56% 7.12e-01 0.10
'rins/rens': 2/7 43% 5.29e-01 0.10
'rnd_cst_lns': 1/8 62% 8.33e-01 0.10
'rnd_var_lns': 0/8 62% 8.42e-01 0.10
LS stats Batches Restarts/Perturbs LinMoves GenMoves CompoundMoves Bactracks WeightUpdates ScoreComputed
'ls_restart': 1 1 12'021 0 0 0 2'049 342'431
'ls_restart_compound': 1 1 0 15'327 1'414 6'954 87 373'533
'ls_restart_decay': 2 2 29'452 0 0 0 597 626'524
'ls_restart_decay_compound': 1 1 0 12'638 2'133 5'251 31 306'894
'ls_restart_decay_compound_perturb': 1 1 0 12'763 2'198 5'281 30 315'574
'ls_restart_decay_perturb': 1 1 15'154 0 0 0 321 307'687
'ls_restart_perturb': 3 3 36'152 0 0 0 6'251 1'020'704
Solutions (3) Num Rank
'complete_hint': 2 [0,1]
'graph_arc_lns': 2 [2,3]
'rnd_cst_lns': 2 [1,2]
Objective bounds Num
'am1_presolve': 1
'default_lp': 1
'initial_domain': 1
'max_lp': 4
'quick_restart': 16
'reduced_costs': 1
Solution repositories Added Queried Synchro
'alternative_path': 1 0 1
'best_solutions': 6 73 5
'fj solution hints': 0 0 0
'lp solutions': 66 7 35
'pump': 0 0
Improving bounds shared Num Sym
'default_lp': 3 0
'max_lp': 42 0
'quick_restart': 14 0
'reduced_costs': 8 0
Clauses shared #Exported #Imported #BinaryRead #BinaryTotal
'core': 104 1 151 151
'default_lp': 2 93 151 151
'max_lp': 0 0 149 151
'no_lp': 138 92 151 151
'quick_restart': 0 18 149 151
'reduced_costs': 0 93 151 151
LRAT_status: NA
[Scaling] scaled_objective_bound: 136516 corrected_bound: 136516 delta: -1.40289e-06
CpSolverResponse summary:
status: FEASIBLE
objective: 139645.1826536399
best_bound: 136515.8599476402
integers: 0
booleans: 0
conflicts: 0
branches: 0
propagations: 0
integer_propagations: 0
restarts: 0
lp_iterations: 0
walltime: 5.00984
usertime: 5.00984
deterministic_time: 20.2264
gap_integral: 162.93
solution_fingerprint: 0x6aa24a4cea96b19f
[12]:
wfn_reg.length()
[12]:
139645.18265364
[13]:
wfn_reg.cost()
[13]:
248112330.12342116
[14]:
wfn_reg
[14]:
Irregular turbine layout¶
[15]:
res_irr_warmup = wfn_irr.optimize(router=warmstart_router)
Check the total length of the warm-start solution:
[16]:
wfn_irr.length()
[16]:
136472.24805009153
Optimize with MILP router¶
[17]:
res_irr = wfn_irr.optimize(router=milp_router)
IntegerBoundsPreprocessor 1836 rows, 1192 columns, 6580 entries with magnitude in [1.000000e+00, 7.000000e+00]
BoundPropagationPreprocessor 1836 rows, 1192 columns, 6580 entries with magnitude in [1.000000e+00, 7.000000e+00]
ImpliedIntegerPreprocessor 1836 rows, 1192 columns, 6580 entries with magnitude in [1.000000e+00, 7.000000e+00]
IntegerBoundsPreprocessor 1836 rows, 1192 columns, 6580 entries with magnitude in [1.000000e+00, 7.000000e+00]
ReduceCostOverExclusiveOrConstraintPreprocessor 1836 rows, 1192 columns, 6580 entries with magnitude in [1.000000e+00, 7.000000e+00]
Scaling to pure integer problem.
Num integers: 1192/1192 (implied: 0 in_inequalities: 0 max_scaling: 0) [IP]
Maximum constraint coefficient relative error: 0
Maximum constraint worst-case activity error: 0
Constraint scaling factor range: [1, 1]
Starting CP-SAT solver v9.15.6755
Parameters: max_time_in_seconds: 5 log_search_progress: true catch_sigint_signal: false relative_gap_limit: 0.005 num_workers: 8
Initial optimization model 'optiwindnet': (model_fingerprint: 0xdf0b125fec3ce89e)
#Variables: 1'192 (#bools: 522 in floating point objective) (1'044 primary variables)
- 596 Booleans in [0,1]
- 522 in [0,6]
- 74 in [0,7]
#kLinear2: 1'457
#kLinear3: 5
#kLinearN: 374 (#terms: 3'651)
Starting presolve at 0.00s
The solution hint is complete and is feasible.
[Scaling] Floating point objective has 522 terms with magnitude in [0.59325, 14141.5] average = 2338.54
[Scaling] Objective coefficient relative error: 3.6523e-07
[Scaling] Objective worst-case absolute error: 6.72685e-05
[Scaling] Objective scaling factor: 1.04858e+06
4.81e-04s 0.00e+00d [DetectDominanceRelations]
7.97e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=2 #num_dual_strengthening=1
5.97e-05s 0.00e+00d [ExtractEncodingFromLinear] #potential_supersets=232
1.27e-04s 0.00e+00d [DetectDuplicateColumns]
1.25e-04s 0.00e+00d [DetectDuplicateConstraints]
[Symmetry] Graph for symmetry has 4'481 nodes and 8'294 arcs.
[Symmetry] Symmetry computation done. time: 0.000497575 dtime: 0.00081108
[SAT presolve] num removable Booleans: 0 / 596
[SAT presolve] num trivial clauses: 0
[SAT presolve] [0s] clauses:261 literals:522 vars:522 one_side_vars:522 simple_definition:0 singleton_clauses:0
[SAT presolve] [2.0189e-05s] clauses:261 literals:522 vars:522 one_side_vars:522 simple_definition:0 singleton_clauses:0
[SAT presolve] [3.6336e-05s] clauses:261 literals:522 vars:522 one_side_vars:522 simple_definition:0 singleton_clauses:0
1.17e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
1.35e-02s 6.52e-03d [Probe] #probed=2'384 #new_binary_clauses=596
2.53e-04s 3.24e-04d [MaxClique] Merged 419 constraints with 1'216 literals into 234 constraints with 846 literals
5.53e-04s 0.00e+00d [DetectDominanceRelations]
3.38e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
1.34e-03s 0.00e+00d [ProcessAtMostOneAndLinear] #num_changes=596
1.61e-04s 0.00e+00d [DetectDuplicateConstraints]
1.29e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
2.61e-04s 1.03e-05d [DetectDominatedLinearConstraints] #relevant_constraints=151 #num_inclusions=75
3.34e-05s 0.00e+00d [DetectDifferentVariables]
2.38e-03s 1.93e-04d [ProcessSetPPC] #relevant_constraints=310 #num_inclusions=308
1.00e-04s 0.00e+00d [TransformClausesToExactlyOne] #num_amos=234
3.73e-04s 0.00e+00d [DetectEncodedComplexDomains]
2.54e-05s 2.00e-07d [FindAlmostIdenticalLinearConstraints] #num_tested_pairs=4
1.72e-04s 1.84e-04d [FindBigAtMostOneAndLinearOverlap]
1.50e-04s 2.07e-04d [FindBigVerticalLinearOverlap]
2.19e-05s 8.71e-06d [FindBigHorizontalLinearOverlap] #linears=136
1.42e-05s 0.00e+00d [MergeClauses]
2.50e-04s 0.00e+00d [DetectDominanceRelations]
3.96e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=2 #num_dual_strengthening=1
2.42e-04s 0.00e+00d [DetectDominanceRelations]
1.89e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
7.45e-05s 0.00e+00d [DetectDuplicateColumns]
1.20e-04s 0.00e+00d [DetectDuplicateConstraints]
[Symmetry] Graph for symmetry has 4'042 nodes and 6'890 arcs.
[Symmetry] Symmetry computation done. time: 0.000286292 dtime: 0.00073484
[SAT presolve] num removable Booleans: 0 / 596
[SAT presolve] num trivial clauses: 0
[SAT presolve] [0s] clauses:76 literals:152 vars:152 one_side_vars:152 simple_definition:0 singleton_clauses:0
[SAT presolve] [1.0796e-05s] clauses:76 literals:152 vars:152 one_side_vars:152 simple_definition:0 singleton_clauses:0
[SAT presolve] [3.0733e-05s] clauses:76 literals:152 vars:152 one_side_vars:152 simple_definition:0 singleton_clauses:0
1.21e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
5.80e-03s 2.15e-03d [Probe] #probed=1'192
2.31e-04s 2.19e-04d [MaxClique]
2.52e-04s 0.00e+00d [DetectDominanceRelations]
2.16e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
1.34e-04s 0.00e+00d [ProcessAtMostOneAndLinear]
1.21e-04s 0.00e+00d [DetectDuplicateConstraints]
1.06e-04s 0.00e+00d [DetectDuplicateConstraintsWithDifferentEnforcements]
1.65e-04s 7.75e-06d [DetectDominatedLinearConstraints] #relevant_constraints=150 #num_inclusions=74
2.98e-05s 0.00e+00d [DetectDifferentVariables]
1.14e-04s 4.99e-06d [ProcessSetPPC] #relevant_constraints=309
1.14e-04s 0.00e+00d [TransformClausesToExactlyOne] #num_amos=234
3.91e-04s 0.00e+00d [DetectEncodedComplexDomains]
2.48e-05s 1.90e-07d [FindAlmostIdenticalLinearConstraints] #num_tested_pairs=2
1.86e-04s 1.82e-04d [FindBigAtMostOneAndLinearOverlap]
1.33e-04s 2.07e-04d [FindBigVerticalLinearOverlap]
3.05e-05s 8.70e-06d [FindBigHorizontalLinearOverlap] #linears=136
1.69e-05s 0.00e+00d [MergeClauses]
3.16e-04s 0.00e+00d [DetectDominanceRelations]
2.66e-03s 0.00e+00d [PresolveToFixPoint] #num_loops=1 #num_dual_strengthening=1
6.86e-06s 0.00e+00d [MergeNoOverlap]
7.46e-06s 0.00e+00d [MergeNoOverlap2D]
2.49e-04s 0.00e+00d [ExpandObjective] #entries=4'968 #tight_variables=596 #tight_constraints=74
Presolve summary:
- 0 affine relations were detected.
- rule 'TODO linear inclusion: superset is equality' was applied 149 times.
- rule 'TODO linear2: convert ax + by != cte to clauses for large domains' was applied 3'576 times.
- rule 'at_most_one: transformed into max clique' was applied 1 time.
- rule 'bool_or: implications' was applied 261 times.
- rule 'deductions: 1192 stored' was applied 1 time.
- rule 'linear + amo: extracted enforcement literal' was applied 596 times.
- rule 'linear2: contains a boolean' was applied 596 times.
- rule 'linear2: convert ax + by != cte to clauses' was applied 261 times.
- rule 'linear: positive at most one' was applied 158 times.
- rule 'linear: positive equal one' was applied 74 times.
- rule 'objective: shifted cost with exactly ones' was applied 74 times.
- rule 'presolve: 0 unused variables removed.' was applied 1 time.
- rule 'presolve: iteration' was applied 2 times.
- rule 'setppc: exactly_one included in linear' was applied 74 times.
- rule 'setppc: reduced linear coefficients' was applied 73 times.
- rule 'setppc: removed trivial linear constraint' was applied 1 time.
- rule 'variables: detect fully reified value encoding' was applied 596 times.
- rule 'variables: detect half reified value encoding' was applied 1'192 times.
Presolved optimization model 'optiwindnet': (model_fingerprint: 0xd9b5e871a7065697)
#Variables: 1'192 (#bools: 522 in objective) (1'044 primary variables)
- 596 Booleans in [0,1]
- 522 in [0,6]
- 74 in [0,7]
#kAtMostOne: 158 (#literals: 694)
#kBoolAnd: 76 (#enforced: 76) (#literals: 152)
#kExactlyOne: 74 (#literals: 596)
#kLinear1: 1'192 (#enforced: 1'192)
#kLinear2: 4
#kLinear3: 1
#kLinearN: 145 (#terms: 1'777)
[Symmetry] Graph for symmetry has 4'042 nodes and 6'890 arcs.
[Symmetry] Symmetry computation done. time: 0.000331498 dtime: 0.00073405
Preloading model.
#Bound 0.06s best:inf next:[93516.0522,1236251.99] initial_domain
#1 0.06s best:136451.277 next:[93516.0522,136451.277] complete_hint
#Model 0.06s var:1192/1192 constraints:1650/1650
Starting search at 0.06s with 8 workers.
6 full problem subsolvers: [core, default_lp, max_lp, no_lp, quick_restart, reduced_costs]
2 first solution subsolvers: [fj, fs_random_no_lp]
9 interleaved subsolvers: [feasibility_pump, graph_arc_lns, graph_cst_lns, graph_dec_lns, graph_var_lns, ls, rins/rens, rnd_cst_lns, rnd_var_lns]
3 helper subsolvers: [neighborhood_helper, synchronization_agent, update_gap_integral]
#Bound 0.07s best:136451.277 next:[95755.9972,136451.277] am1_presolve (num_literals=522 num_am1=19 increase=2348752632 work_done=1852)
#2 0.07s best:136417.955 next:[95755.9972,136417.955] no_lp [hint] (fixed_bools=0/596)
#Bound 0.08s best:136417.955 next:[104424.449,136417.955] default_lp
#Bound 0.08s best:136417.955 next:[106103.007,136417.955] reduced_costs
#3 0.09s best:135961.555 next:[106103.007,135961.555] graph_arc_lns (d=5.00e-01 s=9 t=0.10 p=0.00 stall=0 h=base)
#Bound 0.09s best:135961.555 next:[127628.142,135961.555] max_lp
#4 0.09s best:135928.233 next:[127628.142,135928.233] graph_arc_lns (d=5.00e-01 s=9 t=0.10 p=0.00 stall=0 h=base) [combined with: no_lp [hint]...]
#5 0.12s best:135719.133 next:[127628.142,135719.133] no_lp (fixed_bools=0/596)
#Bound 0.15s best:135719.133 next:[128533.054,135719.133] max_lp
#Bound 0.16s best:135719.133 next:[128801.178,135719.133] max_lp
#6 0.24s best:134995.892 next:[128801.178,134995.892] graph_var_lns (d=7.07e-01 s=18 t=0.10 p=1.00 stall=1 h=base)
#7 0.24s best:134786.792 next:[128801.178,134786.792] graph_var_lns (d=7.07e-01 s=18 t=0.10 p=1.00 stall=1 h=base) [combined with: no_lp...]
#Bound 0.27s best:134786.792 next:[129503.176,134786.792] max_lp
#Model 0.28s var:1176/1192 constraints:1631/1650
#Model 0.29s var:1166/1192 constraints:1621/1650
#Bound 0.29s best:134786.792 next:[129515.336,134786.792] max_lp
#Bound 0.30s best:134786.792 next:[129515.56,134786.792] max_lp
#Bound 0.30s best:134786.792 next:[129517.464,134786.792] max_lp
#Bound 0.56s best:134786.792 next:[129636.484,134786.792] max_lp
#Bound 0.77s best:134786.792 next:[129932.239,134786.792] max_lp
#Model 0.84s var:1156/1192 constraints:1611/1650
#Bound 1.29s best:134786.792 next:[130007.372,134786.792] max_lp
#Bound 1.57s best:134786.792 next:[130068.753,134786.792] max_lp
#Bound 1.60s best:134786.792 next:[130163.511,134786.792] max_lp
#Model 1.65s var:1152/1192 constraints:1606/1650
#Bound 1.95s best:134786.792 next:[130275.978,134786.792] max_lp
#Model 1.99s var:1150/1192 constraints:1604/1650
#Model 2.84s var:1148/1192 constraints:1602/1650
#Bound 3.54s best:134786.792 next:[130291.971,134786.792] max_lp
#Model 3.56s var:1144/1192 constraints:1598/1650
#Bound 4.33s best:134786.792 next:[130403.146,134786.792] quick_restart
#Model 4.46s var:1142/1192 constraints:1596/1650
#Bound 4.72s best:134786.792 next:[130463.392,134786.792] max_lp
Task timing n [ min, max] avg dev time n [ min, max] avg dev dtime
'core': 1 [ 4.94s, 4.94s] 4.94s 0.00ns 4.94s 2 [ 2.22ms, 4.89s] 2.44s 2.44s 4.89s
'default_lp': 1 [ 4.94s, 4.94s] 4.94s 0.00ns 4.94s 2 [ 84.01ms, 2.20s] 1.14s 1.06s 2.28s
'feasibility_pump': 12 [ 36.14us, 50.43ms] 5.52ms 13.55ms 66.19ms 10 [259.68us, 32.28ms] 3.48ms 9.60ms 34.80ms
'fj': 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns
'fs_random_no_lp': 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns 0 [ 0.00ns, 0.00ns] 0.00ns 0.00ns 0.00ns
'graph_arc_lns': 10 [ 12.94ms, 260.12ms] 117.41ms 97.22ms 1.17s 10 [415.54us, 100.02ms] 45.22ms 44.98ms 452.25ms
'graph_cst_lns': 9 [ 6.82ms, 265.19ms] 145.12ms 112.20ms 1.31s 9 [ 14.29us, 100.11ms] 56.82ms 48.38ms 511.40ms
'graph_dec_lns': 11 [ 2.32ms, 265.37ms] 107.36ms 114.86ms 1.18s 11 [ 10.00ns, 100.08ms] 38.42ms 46.75ms 422.66ms
'graph_var_lns': 7 [ 13.10ms, 287.32ms] 174.29ms 112.73ms 1.22s 7 [ 1.56ms, 100.14ms] 60.37ms 42.03ms 422.57ms
'ls': 10 [106.25ms, 120.12ms] 115.18ms 4.38ms 1.15s 10 [100.01ms, 100.02ms] 100.01ms 4.16us 1.00s
'max_lp': 1 [ 4.94s, 4.94s] 4.94s 0.00ns 4.94s 2 [210.70ms, 2.19s] 1.20s 987.79ms 2.40s
'no_lp': 1 [ 4.94s, 4.94s] 4.94s 0.00ns 4.94s 2 [ 2.54ms, 2.71s] 1.35s 1.35s 2.71s
'quick_restart': 1 [ 4.95s, 4.95s] 4.95s 0.00ns 4.95s 2 [ 80.10ms, 2.39s] 1.23s 1.15s 2.47s
'reduced_costs': 1 [ 4.95s, 4.95s] 4.95s 0.00ns 4.95s 2 [ 34.29ms, 2.62s] 1.33s 1.30s 2.66s
'rins/rens': 11 [321.54us, 292.11ms] 107.19ms 123.77ms 1.18s 7 [803.47us, 100.09ms] 60.34ms 46.15ms 422.40ms
'rnd_cst_lns': 9 [ 6.32ms, 278.35ms] 142.14ms 119.83ms 1.28s 9 [375.00ns, 100.10ms] 50.97ms 46.94ms 458.75ms
'rnd_var_lns': 10 [ 5.34ms, 286.37ms] 130.09ms 111.85ms 1.30s 10 [ 93.00ns, 100.09ms] 45.53ms 45.06ms 455.25ms
Search stats Bools Conflicts Branches Restarts BacktrackToRoot Backtrack BoolPropag IntegerPropag
'core': 672 124'936 260'950 131 5'240 129'471 2'048'454 5'439'011
'default_lp': 644 461 16'760 6 7'984 10'007 87'052 404'077
'fs_random_no_lp': 0 0 0 0 0 0 0 0
'max_lp': 596 292 11'093 3 5'740 6'714 51'109 255'267
'no_lp': 596 79'671 126'476 61 14'548 96'588 4'903'194 14'602'494
'quick_restart': 631 106 22'681 9 11'387 13'305 86'615 402'445
'reduced_costs': 596 654 15'462 6 6'875 8'359 70'401 369'956
SAT formula Fixed Equiv Total VarLeft BinaryClauses PermanentClauses TemporaryClauses
'core': 24 2 672 646 482 1'983 9'077
'default_lp': 25 2 644 617 460 96 392
'fs_random_no_lp': 0 0 0 0 0 0 0
'max_lp': 25 2 596 569 250 85 254
'no_lp': 25 2 596 569 250 208 8'496
'quick_restart': 25 2 631 604 414 204 92
'reduced_costs': 25 2 596 569 248 202 622
SAT stats ClassicMinim LitRemoved LitRemovedBinary LitLearned LitForgotten Subsumed
'core': 107'089 871'519 623'720 6'935'076 4'198'143 35'345
'default_lp': 384 4'306 10'498 34'403 0 57
'fs_random_no_lp': 0 0 0 0 0 0
'max_lp': 264 5'426 6'810 27'256 0 38
'no_lp': 68'970 511'169 98'075 5'323'205 1'303'091 50'786
'quick_restart': 84 1'519 3'274 7'942 0 9
'reduced_costs': 569 13'267 9'806 43'070 0 26
Vivification Clauses Decisions LitTrue Subsumed LitRemoved DecisionReused Conflicts
'core': 2'187 17'129 0 207 2'519 2'275 23
'default_lp': 1'051 6'728 0 2 10 8 0
'fs_random_no_lp': 0 0 0 0 0 0 0
'max_lp': 644 4'209 0 2 7 1 0
'no_lp': 3'256 19'502 0 103 862 2'364 0
'quick_restart': 1'431 9'662 0 3 10 1 0
'reduced_costs': 763 5'149 0 1 3 0 0
Clause deletion at_true l_and_not(l) to_binary sub_conflict sub_extra sub_decisions sub_eager sub_vivify sub_probing sub_inpro blocked eliminated forgotten promoted conflicts
'core': 46 0 6 34'291 1'550 6 1'054 207 2 219 0 0 76'571 305'676 124'936
'default_lp': 0 2 0 55 0 0 2 2 2 0 0 0 0 933 461
'fs_random_no_lp': 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
'max_lp': 0 2 0 36 0 0 2 2 1 0 0 0 0 609 292
'no_lp': 137 53 0 50'687 115 3 99 103 0 7 0 0 19'853 167'270 79'671
'quick_restart': 1 2 0 8 1 0 1 3 1 10 0 0 0 173 106
'reduced_costs': 0 2 0 24 2 0 2 1 2 11 0 0 0 1'528 654
Lp stats Component Iterations AddedCuts OPTIMAL DUAL_F. DUAL_U.
'default_lp': 1 36'804 2'568 2'232 1 16
'max_lp': 1 25'004 1'889 1'164 78 31
'quick_restart': 1 23'472 2'656 1'061 1 7
'reduced_costs': 1 49'868 2'212 2'061 281 50
Lp dimension Final dimension of first component
'default_lp': 994 rows, 1119 columns, 10038 entries
'max_lp': 1158 rows, 1192 columns, 16171 entries
'quick_restart': 1030 rows, 1119 columns, 13707 entries
'reduced_costs': 1047 rows, 1192 columns, 9648 entries
Lp debug CutPropag CutEqPropag Adjust Overflow Bad BadScaling
'default_lp': 0 0 2'240 0 9'198 0
'max_lp': 0 2 1'273 0 17'414 0
'quick_restart': 0 0 1'062 0 18'098 0
'reduced_costs': 0 0 2'359 0 7'040 0
Lp pool Constraints Updates Simplif Merged Shortened Split Strengthened Cuts/Call
'default_lp': 4'519 67 1'199 0 806 20 60 2'568/5'109
'max_lp': 4'135 249 1'824 0 1'290 244 15 1'889/3'478
'quick_restart': 4'607 156 1'373 0 846 80 55 2'656/4'996
'reduced_costs': 4'458 87 913 0 551 34 12 2'212/4'063
Lp Cut default_lp max_lp quick_restart reduced_costs
CG_FF: 26 6 16 21
CG_K: 13 3 6 8
CG_KL: 4 - - 5
CG_R: 36 23 39 33
CG_RB: 47 50 60 65
CG_RBP: 33 18 29 21
Clique: - - - 1
IB: 820 327 674 847
MIR_1_FF: 111 78 145 57
MIR_1_K: 35 7 46 6
MIR_1_KL: 13 3 25 4
MIR_1_R: - 1 2 2
MIR_1_RB: 55 47 72 36
MIR_1_RBP: 55 14 63 17
MIR_1_RLT: - - - 1
MIR_2_FF: 109 78 120 80
MIR_2_K: 59 10 59 6
MIR_2_KL: 17 2 7 1
MIR_2_R: 7 8 5 6
MIR_2_RB: 77 87 104 99
MIR_2_RBP: 59 21 74 16
MIR_3_FF: 86 113 88 94
MIR_3_K: 60 24 64 19
MIR_3_KL: 11 3 3 8
MIR_3_R: 2 14 7 9
MIR_3_RB: 74 118 64 110
MIR_3_RBP: 63 37 69 28
MIR_4_FF: 44 79 64 49
MIR_4_K: 34 17 49 11
MIR_4_KL: - 4 9 4
MIR_4_R: 3 13 10 8
MIR_4_RB: 30 67 43 82
MIR_4_RBP: 41 29 61 18
MIR_5_FF: 42 35 34 36
MIR_5_K: 36 24 31 9
MIR_5_KL: 12 11 12 8
MIR_5_R: 2 6 6 3
MIR_5_RB: 14 38 22 43
MIR_5_RBP: 40 33 49 18
MIR_6_FF: 15 29 17 16
MIR_6_K: 24 37 33 11
MIR_6_KL: 18 19 18 21
MIR_6_R: - 7 1 3
MIR_6_RB: 5 44 6 20
MIR_6_RBP: 32 44 40 26
ZERO_HALF_FF: 27 18 15 23
ZERO_HALF_K: 10 3 4 3
ZERO_HALF_KL: 2 6 1 -
ZERO_HALF_R: 216 198 236 168
ZERO_HALF_RB: 32 25 35 21
ZERO_HALF_RBP: 17 11 19 11
LNS stats Improv/Calls Closed Difficulty TimeLimit
'graph_arc_lns': 2/10 50% 5.39e-01 0.10
'graph_cst_lns': 0/9 44% 5.07e-01 0.10
'graph_dec_lns': 0/11 64% 8.50e-01 0.10
'graph_var_lns': 1/7 57% 7.52e-01 0.10
'rins/rens': 7/9 56% 6.96e-01 0.10
'rnd_cst_lns': 0/9 56% 7.45e-01 0.10
'rnd_var_lns': 0/10 60% 8.17e-01 0.10
LS stats Batches Restarts/Perturbs LinMoves GenMoves CompoundMoves Bactracks WeightUpdates ScoreComputed
'ls_restart_compound': 3 3 0 59'482 4'639 27'415 382 1'424'738
'ls_restart_decay': 2 2 36'205 0 0 0 814 753'454
'ls_restart_decay_compound': 2 2 0 33'630 5'205 14'190 95 904'194
'ls_restart_decay_compound_perturb': 1 1 0 16'177 2'626 6'769 50 398'387
'ls_restart_decay_perturb': 2 2 36'703 0 0 0 821 752'381
Solutions (7) Num Rank
'complete_hint': 2 [0,1]
'graph_arc_lns': 4 [2,4]
'graph_var_lns': 4 [5,7]
'no_lp': 4 [1,5]
Objective bounds Num
'am1_presolve': 1
'default_lp': 1
'initial_domain': 1
'max_lp': 15
'quick_restart': 1
'reduced_costs': 1
Solution repositories Added Queried Synchro
'alternative_path': 1 0 1
'best_solutions': 8 83 8
'fj solution hints': 0 0 0
'lp solutions': 42 11 35
'pump': 0 0
Improving bounds shared Num Sym
'max_lp': 44 0
'quick_restart': 6 0
'reduced_costs': 2 0
Clauses shared #Exported #Imported #BinaryRead #BinaryTotal
'core': 206 0 16 17
'default_lp': 0 16 17 17
'max_lp': 0 16 17 17
'no_lp': 0 16 17 17
'quick_restart': 0 164 17 17
'reduced_costs': 2 163 17 17
LRAT_status: NA
[Scaling] scaled_objective_bound: 130463 corrected_bound: 130463 delta: -2.01093e-07
CpSolverResponse summary:
status: FEASIBLE
objective: 134786.7922581253
best_bound: 130463.3918217484
integers: 0
booleans: 0
conflicts: 0
branches: 0
propagations: 0
integer_propagations: 0
restarts: 0
lp_iterations: 0
walltime: 5.0098
usertime: 5.0098
deterministic_time: 21.5941
gap_integral: 181.179
solution_fingerprint: 0x8de4169e43eb94c3
[18]:
wfn_irr.length()
[18]:
134807.7634895362
[19]:
wfn_irr.cost()
[19]:
247033944.13135293
[20]:
wfn_irr
[20]:
Layouts’ edge list¶
These lists of 3-tuples has all the edges and their cable type (as an index to the turbines_per_cable list), i.e. (coordinate_A, coordinate_B, cable_type).
Negative node indices represent substations, the node indices ranging from 0 to 73 represent the WT in the order they were given.
If the network has contours or detours, indices will go beyond the number of coordinates (WT, SS, borders) provided, and the mapping of these additional indices to indices to the provided coordinates is presented.
[21]:
wfn_reg.G.edges(data='cable')
[21]:
EdgeDataView([(-1, 47, 2), (-1, 56, 2), (-1, 46, 2), (-1, 33, 2), (-1, 45, 2), (-1, 57, 2), (-1, 34, 2), (-1, 24, 2), (-1, 49, 2), (-1, 58, 2), (-1, 32, 2), (0, 1, 0), (1, 4, 0), (4, 5, 1), (2, 3, 0), (3, 8, 0), (8, 14, 1), (5, 9, 1), (9, 15, 1), (6, 7, 0), (7, 12, 0), (12, 13, 1), (14, 22, 1), (15, 24, 2), (10, 11, 0), (11, 16, 0), (16, 17, 1), (13, 20, 1), (20, 21, 1), (22, 23, 1), (17, 26, 1), (26, 25, 1), (18, 19, 0), (19, 28, 0), (28, 27, 1), (21, 32, 2), (23, 33, 2), (25, 34, 2), (27, 36, 1), (36, 35, 1), (29, 38, 0), (29, 40, 0), (38, 37, 1), (30, 31, 0), (31, 44, 1), (31, 42, 0), (44, 45, 1), (44, 43, 0), (35, 46, 2), (37, 48, 1), (48, 47, 1), (39, 50, 1), (39, 52, 1), (50, 49, 2), (41, 52, 1), (41, 54, 0), (51, 62, 1), (51, 60, 1), (60, 59, 1), (53, 62, 0), (53, 64, 0), (61, 70, 0), (61, 69, 1), (69, 68, 1), (63, 70, 0), (54, 55, 0), (65, 66, 1), (65, 80, 1), (56, 80, 1), (67, 68, 1), (67, 57, 2), (59, 58, 2), (66, 71, 0), (66, 73, 0), (71, 72, 0)])
Alternatively we can use get_network() method, to get the final cabling network as a structured array of edge data, and then extract desired edge data from it.
Regular turbine layout¶
[22]:
network_reg = wfn_reg.get_network()
print(network_reg.dtype.names)
('src', 'tgt', 'length', 'load', 'cable')
[23]:
network_cable_reg = np.column_stack((network_reg['src'], network_reg['tgt'], network_reg['cable']))
print(network_cable_reg)
[[47 -1 2]
[56 -1 2]
[46 -1 2]
[33 -1 2]
[45 -1 2]
[57 -1 2]
[34 -1 2]
[24 -1 2]
[49 -1 2]
[58 -1 2]
[32 -1 2]
[ 0 1 0]
[ 1 4 0]
[ 4 5 1]
[ 2 3 0]
[ 3 8 0]
[ 8 14 1]
[ 5 9 1]
[ 9 15 1]
[ 6 7 0]
[ 7 12 0]
[12 13 1]
[14 22 1]
[15 24 2]
[10 11 0]
[11 16 0]
[16 17 1]
[13 20 1]
[20 21 1]
[22 23 1]
[17 26 1]
[26 25 1]
[18 19 0]
[19 28 0]
[28 27 1]
[21 32 2]
[23 33 2]
[25 34 2]
[27 36 1]
[36 35 1]
[29 38 0]
[40 29 0]
[38 37 1]
[30 31 0]
[31 44 1]
[42 31 0]
[44 45 1]
[43 44 0]
[35 46 2]
[37 48 1]
[48 47 1]
[39 50 1]
[52 39 1]
[50 49 2]
[41 52 1]
[54 41 0]
[62 51 1]
[51 60 1]
[60 59 1]
[53 62 0]
[64 53 0]
[70 61 0]
[61 69 1]
[69 68 1]
[63 70 0]
[55 54 0]
[66 65 1]
[65 80 1]
[80 56 1]
[68 67 1]
[67 57 2]
[59 58 2]
[71 66 0]
[73 66 0]
[72 71 0]]
Irregular turbine layout¶
[24]:
network_irr = wfn_irr.get_network()
network_cable_irr = np.column_stack((network_irr['src'], network_irr['tgt'], network_irr['cable']))
print(network_cable_irr)
[[41 -1 2]
[28 -1 2]
[49 -1 2]
[55 -1 1]
[39 -1 2]
[60 -1 2]
[70 -1 2]
[25 -1 2]
[33 -1 2]
[80 -1 2]
[81 -1 2]
[ 0 50 0]
[50 46 0]
[ 1 34 0]
[34 20 0]
[ 2 8 1]
[ 7 2 1]
[ 8 42 1]
[ 3 12 1]
[15 3 1]
[12 45 1]
[ 4 20 0]
[20 37 1]
[ 9 5 0]
[ 5 32 1]
[32 14 1]
[ 6 35 0]
[35 36 0]
[42 25 2]
[10 24 0]
[24 17 0]
[11 18 0]
[18 59 0]
[45 33 2]
[13 26 0]
[26 31 0]
[14 68 1]
[68 73 2]
[16 29 1]
[17 16 1]
[29 53 1]
[59 60 2]
[52 59 1]
[37 51 1]
[44 22 1]
[22 67 1]
[67 70 2]
[23 43 0]
[43 7 0]
[31 56 1]
[27 52 0]
[38 27 0]
[53 28 2]
[30 54 1]
[56 30 1]
[54 49 2]
[36 62 1]
[62 69 1]
[51 41 2]
[40 55 1]
[57 40 0]
[47 65 0]
[65 58 1]
[48 65 0]
[58 61 1]
[61 64 1]
[64 71 2]
[69 63 1]
[71 81 2]
[73 80 2]
[21 15 0]
[19 9 0]
[66 21 0]
[46 44 1]
[63 39 2]
[72 57 0]]
Mapping of contour/detour¶
Mapping of contour/detour node to the index of its VertexC coordinate :
[25]:
wfn_reg.map_detour_vertex()
[25]:
{80: 76}
[26]:
wfn_irr.map_detour_vertex()
[26]:
{80: 28, 81: 76}