Skip to content

Commit

Permalink
Merge branch 'main' into add-2023-cepci
Browse files Browse the repository at this point in the history
  • Loading branch information
lbianchi-lbl authored Jul 9, 2024
2 parents 82a2354 + 24ca931 commit df34cdd
Show file tree
Hide file tree
Showing 12 changed files with 17 additions and 16 deletions.
1 change: 1 addition & 0 deletions .github/workflows/typos.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ idaes = "idaes"
IDAE = "IDAE"
# HELMET - HELMholtz
HEL = "HEL"
gam = "gam"
# Datas
Datas = "Datas"
# ba triggers in docs
Expand Down
2 changes: 1 addition & 1 deletion idaes/core/util/model_diagnostics.py
Original file line number Diff line number Diff line change
Expand Up @@ -3167,7 +3167,7 @@ def psweep_runner_validator(val):

class IpoptConvergenceAnalysis:
"""
Tool to performa a parameter sweep of model checking for numerical issues and
Tool to perform a parameter sweep of model checking for numerical issues and
convergence characteristics. Users may specify an IDAES ParameterSweep class to
perform the sweep (default is SequentialSweepRunner).
"""
Expand Down
2 changes: 1 addition & 1 deletion idaes/models/unit_models/translator.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ class TranslatorData(UnitModelBlockData):
**default** - True.
**Valid values:** {
**True** - outlet state will be fully defined,
**False** - outlet property package should enforce sumation and equilibrium
**False** - outlet property package should enforce summation and equilibrium
constraints.}""",
),
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -830,7 +830,7 @@ def set_inputs(m):
fs.bfp.efficiency_isentropic.fix(0.8)
fs.bfp.outlet.pressure.fix(1.45e7)

# Set input for spliter for main steam attemperator spray
# Set input for splitter for main steam attemperator spray
fs.split_attemp.split_fraction[:, "Spray"].fix(0.0007)

# Set inputs for water spray control valve
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def main():
# pylint: disable-next=import-outside-toplevel
import idaes.models_extra.power_generation.flowsheets.supercritical_power_plant.boiler_subflowsheet_build as blr

# import the models (ECON, WW, PrSH, PlSH, FSH, Spliter, Mixer, Reheater)
# import the models (ECON, WW, PrSH, PlSH, FSH, Splitter, Mixer, Reheater)
# see boiler_subflowhseet_build.py for a better description
blr.build_boiler(m.fs)
# initialize boiler network models (one by one)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ def initialize_build(
(self.control_volume.deltaP[t] + self.inlet.pressure[t])
/ self.inlet.pressure[t]
)
# Fix the variables we base the initializtion on and free the rest.
# Fix the variables we base the initialization on and free the rest.
# This requires good values to be provided for pressure, efficiency,
# and inlet conditions, but it is simple and reliable.
self.inlet.fix()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ def initialize_build(
hot_side = getattr(self, self.config.hot_side_name)
cold_side = getattr(self, self.config.cold_side_name)

# Store initial model specs, restored at the end of initializtion, so
# Store initial model specs, restored at the end of initialization, so
# the problem is not altered. This can restore fixed/free vars,
# active/inactive constraints, and fixed variable values.
sp = StoreSpec.value_isfixed_isactive(only_fixed=True)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ def initialize_build(self, outlvl=idaeslog.NOTSET, optarg=None, solver=None):
# Create solver
opt = get_solver(solver, optarg)

# This shouldn't require too much initializtion, just fixing inlets
# This shouldn't require too much initialization, just fixing inlets
# and solving should always work.

# sp is what to save to make sure state after init is same as the start
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def initialize_build(
(self.control_volume.deltaP[t] + self.inlet.pressure[t])
/ self.inlet.pressure[t]
)
# Fix the variables we base the initializtion on and free the rest.
# Fix the variables we base the initialization on and free the rest.
# This requires good values to be provided for pressure, efficiency,
# and inlet conditions, but it is simple and reliable.
self.inlet.fix()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def initialize_build(
(self.control_volume.deltaP[t] + self.inlet.pressure[t])
/ self.inlet.pressure[t]
)
# Fix the variables we base the initializtion on and free the rest.
# Fix the variables we base the initialization on and free the rest.
# This requires good values to be provided for pressure, efficiency,
# and inlet conditions, but it is simple and reliable.
self.inlet.fix()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,9 @@ def initialize_build(
"""
Initialize the inlet turbine stage model. This deactivates the
specialized constraints, then does the isentropic turbine initialization,
then reactivates the constraints and solves. This initializtion uses a
then reactivates the constraints and solves. This initialization uses a
flow value guess, so some reasonable flow guess should be specified prior
to initializtion.
to initialization.
Args:
outlvl (int): Amount of output (0 to 3) 0 is lowest
Expand All @@ -154,7 +154,7 @@ def initialize_build(
sp = StoreSpec.value_isfixed_isactive(only_fixed=True)
istate = to_json(self, return_dict=True, wts=sp)

# Setup for initializtion step 1
# Setup for initialization step 1
self.inlet_flow_constraint.deactivate()
self.efficiency_correlation.deactivate()
self.eff_nozzle.fix()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ def _inlet_to_rule(b, i):
self.stream_inlet_mix_inlet = Arc(inlet_idx, rule=_inlet_to_rule)

# There are three sections HP, IP, and LP which all have the same sort
# of internal connctions, so the functions below provide some generic
# of internal connections, so the functions below provide some generic
# capcbilities for adding the internal Arcs (streams).
def _arc_indexes(nstages, index_set, discon, splits):
"""
Expand All @@ -369,7 +369,7 @@ def _arc_indexes(nstages, index_set, discon, splits):
nstages (int): Number of stages in section
index_set (Set): Index set for arcs in the section
discon (list): Disconnected stages in the section
splits (list): Spliter locations
splits (list): Splitter locations
"""
sr = set() # set of things to remove from the Arc index set
for i in index_set:
Expand Down Expand Up @@ -602,7 +602,7 @@ def _init_section(
copy_disconnected_flow,
copy_disconnected_pressure,
):
"""Reuse the initializtion for HP, IP and, LP sections."""
"""Reuse the initialization for HP, IP and, LP sections."""
if 0 in splits:
propagate_state(splits[0].inlet, prev_port)
splits[0].initialize(outlvl=outlvl, solver=solver, optarg=optarg)
Expand Down Expand Up @@ -671,7 +671,7 @@ def initialize_build(
None
"""
# Setup loggers
# Store initial model specs, restored at the end of initializtion, so
# Store initial model specs, restored at the end of initialization, so
# the problem is not altered. This can restore fixed/free vars,
# active/inactive constraints, and fixed variable values.
sp = StoreSpec.value_isfixed_isactive(only_fixed=True)
Expand Down

0 comments on commit df34cdd

Please sign in to comment.