bio_rtd.uo.fc_uo

Dilution

class bio_rtd.uo.fc_uo.Dilution(t, dilution_ratio, uo_id, gui_title='Dilution')[source]

Bases: bio_rtd.core.UnitOperation

Dilute process fluid stream in constant ratio.

Variables
  • dilution_ratio (int) – Dilution ratio. Must be >= 1. Dilution ratio of 1.2 means adding 20 % of dilution buffer. It is applied before the delay_inlet.

  • c_add_buffer (np.ndarray) – Concentration of species in dilution buffer.

evaluate(f_in, c_in)

Evaluate the propagation through the unit operation.

Parameters
  • c_in (ndarray) – Inlet concentration profile with shape (n_species, n_time_steps).

  • f_in (array) – Inlet flow rate profile with shape (n_time_steps,).

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

get_result()

Returns existing flow rate and concentration profiles.

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

property log

Logger.

If logger is not set, then a DefaultLogger is instantiated. Setter also plants a data tree into passed logger.

Return type

RtdLogger

set_logger_from_parent(parent_id, logger)

Inherit logger from parent.

Parameters

Concentration

class bio_rtd.uo.fc_uo.Concentration(t, flow_reduction, uo_id, gui_title='Concentration')[source]

Bases: bio_rtd.core.UnitOperation

Concentrate process fluid stream

Concentration step can be used before or after the FlowThrough or FlowThroughWithSwitching steps in order to simulate unit operations such as SPTFF or UFDF

evaluate(f_in, c_in)

Evaluate the propagation through the unit operation.

Parameters
  • c_in (ndarray) – Inlet concentration profile with shape (n_species, n_time_steps).

  • f_in (array) – Inlet flow rate profile with shape (n_time_steps,).

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

get_result()

Returns existing flow rate and concentration profiles.

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

property log

Logger.

If logger is not set, then a DefaultLogger is instantiated. Setter also plants a data tree into passed logger.

Return type

RtdLogger

set_logger_from_parent(parent_id, logger)

Inherit logger from parent.

Parameters

BufferExchange

class bio_rtd.uo.fc_uo.BufferExchange(t, exchange_ratio, uo_id, gui_title='BufferExchange')[source]

Bases: bio_rtd.core.UnitOperation

Buffer exchange

Can be combined with Concentration and one of the FlowThrough or FlowThroughWithSwitching steps in order to simulate unit operations such as SPTFF or UFDF

evaluate(f_in, c_in)

Evaluate the propagation through the unit operation.

Parameters
  • c_in (ndarray) – Inlet concentration profile with shape (n_species, n_time_steps).

  • f_in (array) – Inlet flow rate profile with shape (n_time_steps,).

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

get_result()

Returns existing flow rate and concentration profiles.

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

property log

Logger.

If logger is not set, then a DefaultLogger is instantiated. Setter also plants a data tree into passed logger.

Return type

RtdLogger

set_logger_from_parent(parent_id, logger)

Inherit logger from parent.

Parameters

FlowThrough

class bio_rtd.uo.fc_uo.FlowThrough(t, pdf, uo_id, gui_title='FlowThrough')[source]

Bases: bio_rtd.core.UnitOperation

Fully continuous unit operation without inline switching

FlowThrough has a constant PDF, which depends on process parameters. It assumes a constant inlet flow rate (apart from initial delay or early stop). It does not depend on concentration.

If initial volume (v_init) < void volume (v_void), then the unit operation is first filled up. During the fill-up an ideal mixing is assumed.

Variables
  • v_void (float) –

    Effective void volume of the unit operations (v_void = rt_target / f)

    Values > 0 are accepted.

  • rt_target (float) – Specified flow-through time as alternative way to define v_void (v_void = rt_target / f) Values > 0 are accepted in v_void <= 0

  • v_init (float) – Effective void volume of the unit operations (v_void = rt_target / f) Values (v_void >= v_init >= 0) are accepted. Values > v_void result in error. If v_init and v_init_ratio are both undefined or out of range, v_init = v_void is assumed.

  • v_init_ratio (float) – Specified flow-through time as alternative way to define v_void (v_void = rt_target / f) Values (0 >= v_init_ratio >= 1) are accepted if v_init if < 0. Values > 1 result in error. If v_init and v_init_ratio are both < 0, v_init == v_void is assumed.

  • c_init (np.ndarray) – Concentration in v_init for each process fluid component. If left blank it is assumed that all components are 0.

  • pdf (PDF) – Steady-state probability distribution function (see PFD class). pdf is updated based on passed v_void and f at runtime

evaluate(f_in, c_in)

Evaluate the propagation through the unit operation.

Parameters
  • c_in (ndarray) – Inlet concentration profile with shape (n_species, n_time_steps).

  • f_in (array) – Inlet flow rate profile with shape (n_time_steps,).

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

get_result()

Returns existing flow rate and concentration profiles.

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

property log

Logger.

If logger is not set, then a DefaultLogger is instantiated. Setter also plants a data tree into passed logger.

Return type

RtdLogger

set_logger_from_parent(parent_id, logger)

Inherit logger from parent.

Parameters

FlowThroughWithSwitching

class bio_rtd.uo.fc_uo.FlowThroughWithSwitching(t, pdf, uo_id, gui_title='FlowThroughWithSwitching')[source]

Bases: bio_rtd.uo.fc_uo.FlowThrough

Fully continuous unit operation with inline switching (= piece-wise FC UO)

FlowThroughWithSwitching has a constant PDF, which depends on process parameters. It assumes a constant inlet flow rate (apart from initial delay or early stop). Its operation does not depend on concentration values It is periodically interrupted

If initial volume (v_init) < void volume (v_void), then the unit operation is first filled up. During the fill-up an ideal mixing is assumed. First cycle starts when the inlet flow rate is turned on (possible initial delays are covered in UnitOperation)

Variables
  • t_cycle (float) – Duration of the cycle between switches

  • v_cycle (float) – Alternative way to define t_cycle t_cycle = v_cycle / f

  • v_cycle_relative (float) – Alternative way to define t_cycle t_cycle = v_cycle_relative * v_void / f = v_cycle_relative * rt_mean

  • pdf (PDF) – Steady-state probability distribution function (see PFD class). pdf is updated based on passed v_void and f at runtime

Parameters
  • v_void (float) –

    Effective void volume of the unit operations (v_void = rt_target / f)

    Values > 0 are accepted.

  • rt_target (float) – Specified flow-through time as alternative way to define v_void (v_void = rt_target / f) Values > 0 are accepted in v_void <= 0

  • c_init (np.ndarray) – Concentration in v_init for each process fluid component. If left blank it is assumed that all components are 0.

evaluate(f_in, c_in)

Evaluate the propagation through the unit operation.

Parameters
  • c_in (ndarray) – Inlet concentration profile with shape (n_species, n_time_steps).

  • f_in (array) – Inlet flow rate profile with shape (n_time_steps,).

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

get_result()

Returns existing flow rate and concentration profiles.

Return type

Tuple[ndarray, ndarray]

Returns

  • f_out – Outlet flow rate profile.

  • c_out – Outlet concentration profile.

property log

Logger.

If logger is not set, then a DefaultLogger is instantiated. Setter also plants a data tree into passed logger.

Return type

RtdLogger

set_logger_from_parent(parent_id, logger)

Inherit logger from parent.

Parameters