Reactors

A list of the available Reactors.

Index

Models

BioChemicalTreatment.ProcessSimulator.BatchReactorFunction
BatchReactor(states; initial_states = nothing, name)

A Batch Reactor.

This system defines the mass transfer of a batch reactor (which is in fact empty). The reactions are to be supplied from an external system.

The volume of the tank is not needed, as only concentration is considered and the equation thus independent of the volume. The equations for component $C$ in a Batch reactor is then defined as:

$\frac{dC}{dt} = r_C$

where $r_C$ is the externally supplied reaction rate corresponding to the component.

Parameters:

  • states: The components that the batch reactor should have and for which the mass transfer is defined
  • initial_states: The initial concentrations in the batch reactor
  • name: The name of the reactor

States:

  • One state for each component defined by the states parameter

Connectors:

  • states: The current values of all states in the batch reactor
  • rates: Input for the reaction rates for each state
source
BatchReactor(processes = Vector{Process}(); initial_states = nothing, name, state_mapping = default_state_mapping(), use_default_processes = true)

A Batch Reactor.

This system defines the mass transfer of a batch reactor (which is in fact empty). The reactions are to be supplied from an external system.

The volume of the tank is not needed, as only concentration is considered and the equation thus independent of the volume. The equations for component $C$ in a Batch reactor is then defined as:

$\frac{dC}{dt} = r_C$

where $r_C$ is the externally supplied reaction rate corresponding to the component.

Parameters:

  • processes: The processes in the reactor. Will be extended by the default processes (unless use_default_processes=false). Can be either a single Process or a Vector{Process}. Defaults to an empty Vector{Process}, and thus only the default processes.
  • initial_states: The initial concentrations in the batch reactor
  • name: The name of the reactor
  • state_mapping: Mapping to rename and set states equal. Defaults to default_state_mapping().
  • use_default_processes: If the default processes (from default_processes()) are added to the given processes.

States:

  • One state for each component defined by the states parameter

Connectors:

  • states: The current values of all states in the batch reactor
  • rates: Input for the reaction rates for each state
source
BioChemicalTreatment.ProcessSimulator.CSTRFunction
CSTR(V, states; initial_states = nothing, name)

A Continuously Stirred Tank Reactor (CSTR).

This system defines the mass flow of a CSTR without any reactions. The reactions are to be supplied from an external system.

The mass transfer of an given component $C$ in a CSTR with volume $V$ and flow rate $q$ is defined as:

$\frac{dC}{dt} = (C_{in} - C) * \frac{q}{V} + r_C$

where $r_C$ is the externally supplied reaction rate corresponding to the component.

Parameters:

  • V: The volume of the CSTR
  • states: The components that the CSTR should have and for which the mass transfer is defined
  • initial_states: The initial concentrations in the CSTR
  • name: The name of the CSTR

States:

  • One state for each component defined by the states parameter

Connectors:

  • inflow: The inflow of the CSTR
  • outflow: The outflow of the CSTR
  • states: The current values of all states in the CSTR
  • rates: Input for the reaction rates for each state
source
CSTR(V, processes = Vector{Process}(); initial_states = nothing, name, state_mapping = default_state_mapping(), use_default_processes = true)

A Continuously Stirred Tank Reactor (CSTR).

This function constructs a CSTR, directly with the supplied processes in it. If use_default_processes = true, the default processes are added, which enables easy addition of processes to the default ones as well as calling this function without any process.

The mass transfer of an given component $C$ in a CSTR with volume $V$ and flow rate $q$ is defined as:

$\frac{dC}{dt} = (C_{in} - C) * \frac{q}{V} + r_C$

where $r_C$ is the externally supplied reaction rate corresponding to the component.

Parameters:

  • V: The volume of the CSTR
  • processes: The processes in the reactor. Will be extended by the default processes (unless use_default_processes=false). Can be either a single Process or a Vector{Process}. Defaults to an empty Vector{Process}, and thus only the default processes.
  • initial_states: The initial concentrations in the CSTR
  • name: The name of the CSTR
  • state_mapping: Mapping to rename and set states equal. Defaults to default_state_mapping().
  • use_default_processes: If the default processes (from default_processes()) are added to the given processes.

States:

  • One state for each component defined by the states parameter

Connectors:

  • inflow: The inflow of the CSTR
  • outflow: The outflow of the CSTR
  • states: The current values of all states in the CSTR
  • rates: Input for the reaction rates for each state
source