Reformat code

bugfix/formulations
Alinson S. Xavier 4 years ago
parent 8cdd88d6de
commit 0a96565f47

@ -70,27 +70,15 @@ function main()
"tejada19/UC_168h_199g", "tejada19/UC_168h_199g",
] ]
formulations = Dict( formulations = Dict(
"ArrCon2000" => Formulation( "ArrCon2000" => Formulation(ramping = ArrCon2000.Ramping()),
ramping = ArrCon2000.Ramping(), "CarArr2006" => Formulation(pwl_costs = CarArr2006.PwlCosts()),
), "DamKucRajAta2016" =>
"CarArr2006" => Formulation( Formulation(ramping = DamKucRajAta2016.Ramping()),
pwl_costs = CarArr2006.PwlCosts(), "Gar1962" => Formulation(pwl_costs = Gar1962.PwlCosts()),
), "KnuOstWat2018" =>
"DamKucRajAta2016" => Formulation( Formulation(pwl_costs = KnuOstWat2018.PwlCosts()),
ramping = DamKucRajAta2016.Ramping(), "MorLatRam2013" => Formulation(ramping = MorLatRam2013.Ramping()),
), "PanGua2016" => Formulation(ramping = PanGua2016.Ramping()),
"Gar1962" => Formulation(
pwl_costs = Gar1962.PwlCosts(),
),
"KnuOstWat2018" => Formulation(
pwl_costs = KnuOstWat2018.PwlCosts(),
),
"MorLatRam2013" => Formulation(
ramping = MorLatRam2013.Ramping(),
),
"PanGua2016" => Formulation(
ramping = PanGua2016.Ramping(),
),
) )
trials = [i for i in 1:5] trials = [i for i in 1:5]
combinations = [ combinations = [
@ -149,10 +137,7 @@ end
BLAS.set_num_threads(1) BLAS.set_num_threads(1)
UnitCommitment.optimize!( UnitCommitment.optimize!(
model, model,
XavQiuWanThi2019.Method( XavQiuWanThi2019.Method(time_limit = 3600.0, gap_limit = 1e-4),
time_limit = 3600.0,
gap_limit = 1e-4,
),
) )
end end
@info @sprintf("Total time was %.2f seconds", total_time) @info @sprintf("Total time was %.2f seconds", total_time)

@ -2,7 +2,6 @@
# Copyright (C) 2020, UChicago Argonne, LLC. All rights reserved. # Copyright (C) 2020, UChicago Argonne, LLC. All rights reserved.
# Released under the modified BSD license. See COPYING.md for more details. # Released under the modified BSD license. See COPYING.md for more details.
""" """
Lazy constraint solution method described in: Lazy constraint solution method described in:

@ -32,4 +32,4 @@ end
_test(Formulation(pwl_costs = Gar1962.PwlCosts())) _test(Formulation(pwl_costs = Gar1962.PwlCosts()))
_test(Formulation(pwl_costs = CarArr2006.PwlCosts())) _test(Formulation(pwl_costs = CarArr2006.PwlCosts()))
_test(Formulation(pwl_costs = KnuOstWat2018.PwlCosts())) _test(Formulation(pwl_costs = KnuOstWat2018.PwlCosts()))
end end

Loading…
Cancel
Save