carbatpy.models.components.flowmachine_comp
Classes
FlowMachine means Compressor, Expander, and Pump. |
Module Contents
- class carbatpy.models.components.flowmachine_comp.FlowMachine(name, config, **kwargs)[source]
Bases:
carbatpy.models.components.comp.FlowDeviceFlowMachine means Compressor, Expander, and Pump.
Set the basic configuration of a component.
- Parameters:
name (string) – name of the component to be configured, must be the same as in the config dictionary or file.
config (string or dictionary) – if it is a string it must be the filename with a yaml or json file with the dictionary information. All needed basic parameters or default parameters and calculation type are set here. Check the io_utils.py file for typical values.
**kwargs (dictionary) – any further parameters which may be needed.
- Return type:
None.
- calculate(in_states, out_states, run_param=None, **kwargs)[source]
- Calculates a Flowmachine. Available models:
const_eta: compressor (Pump) / expander
turbo * RadialCompressor: from spp machines
turbo * RadialTurbine: from spp machines
scroll * Expander: from Liège
For more information on the models see documentation.
Results written in self.output
- Parameters:
in_states (dictionary) – keys: fluidnmae (str) index: state entering, as defined in THERMO_STRING T,p,h,v,s.
out_states (dictionary) – keys: fluidnmae (str) index: output state only the pressure is used out_state[1].
run_params (dict, optional) – if further parameters must be passed for the calculation. - power : power given, mass flow rate calculated
**kwargs (TYPE) – DESCRIPTION.
- Raises:
Exception – DESCRIPTION.
- Return type:
None.