mirror of
https://github.com/ANL-CEEESA/UnitCommitment.jl.git
synced 2025-12-06 08:18:51 -06:00
Formatted codes on the LMP dev branch
This commit is contained in:
@@ -124,7 +124,7 @@ function _aelmp_check_parameters(
|
|||||||
)
|
)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
all_units = instance.units;
|
all_units = instance.units
|
||||||
# CHECK: model cannot handle non-fast-starts (MISO Phase I: can ONLY solve fast-starts)
|
# CHECK: model cannot handle non-fast-starts (MISO Phase I: can ONLY solve fast-starts)
|
||||||
if any(u -> u.min_uptime > 1 || u.min_downtime > 1, all_units)
|
if any(u -> u.min_uptime > 1 || u.min_downtime > 1, all_units)
|
||||||
error(
|
error(
|
||||||
@@ -132,20 +132,14 @@ function _aelmp_check_parameters(
|
|||||||
)
|
)
|
||||||
end
|
end
|
||||||
if any(u -> u.initial_power > 0, all_units)
|
if any(u -> u.initial_power > 0, all_units)
|
||||||
error(
|
error("The initial power of all generators must be 0.")
|
||||||
"The initial power of all generators must be 0.",
|
|
||||||
)
|
|
||||||
end
|
end
|
||||||
if any(u -> u.initial_status >= 0, all_units)
|
if any(u -> u.initial_status >= 0, all_units)
|
||||||
error(
|
error("The initial status of all generators must be negative.")
|
||||||
"The initial status of all generators must be negative.",
|
|
||||||
)
|
|
||||||
end
|
end
|
||||||
# CHECK: model does not support startup costs (in time series)
|
# CHECK: model does not support startup costs (in time series)
|
||||||
if any(u -> length(u.startup_categories) > 1, all_units)
|
if any(u -> length(u.startup_categories) > 1, all_units)
|
||||||
error(
|
error("The method does NOT support time-varying start-up costs.")
|
||||||
"The method does NOT support time-varying start-up costs.",
|
|
||||||
)
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user