Base RTD class — rtdpy 0.6.0 documentation

# Base RTD class

Base RTD Class and Error.

class `rtdpy.rtd.` `RTD`(dt, time_end)

  Bases: `object`

  Base class for RTD analysis

  Child classes must implement:
    exitage

      The exitage function evaluated at each time point

  property `dt`

    Time step for RTD

  property `exitage`

    Exit age distribution for RTD

  property `exitage_norm`

    Normalized Exit Age Distribtion for RTD

  `frequencyresponse`(omegas)
    Parameters
      omegasndarray

        frequencies at which to evaluate magnitude response

    Returns
      magnitudendarray

        frequency magnitude response at omegas

  `funnelplot`(times, disturbances)

    Return maximum output signal due to square disturbances.

    Uses method from [Garcia] . Also returns meshgrid for times and disturbance inputs for ease of plotting.

    Parameters
      timesarray_like, size m

        Times to determine funnelplot

      disturbancesarray_like, size n

        Disturbance magnitudes

    Returns
      x2D meshgrid size (mxn)

        times

      y2D meshgrid size (mxn)

        disturbances

      response2D meshgrid size (mxn)

        maximum response at (x,y)

    References

    Garcia

      Garcia-Munoz S., Butterbaugh A., Leavesley I., Manley L.F., Slade D., Bermingham S. (2018) A flowhseet model for the development of a continuous process for pharmaceutical tablets: An industrial perspective. “AIChE Journal”, 64(2), 511-525.

  `integral`()

    Integral of RTD.

  `mrt`()

    Mean residence time of RTD.

  `output`(inputtime, inputsignal)

    Convolves input signal with RTD

    Parameters
      inputtimendarray

        Times of input signal, which must have same dt as RTD. Size m

      inputsignalndarray

        Input signal. Size n

    Returns
      outputsignalndarrary

        Output signal at same dt. Size m + n -1

  `sigma`()

    Variance of RTD.

  property `stepresponse`

    Step respose of RTD

  property `stepresponse_norm`

    Normalized step respose of RTD

  property `time`

    Time points for exitage function.

  property `time_end`

    Last time point for RTD

exception `rtdpy.rtd.` `RTDInputError`

  Bases: `Exception`

  Errors for RTD inputs.

  `args`
  `with_traceback`()

    Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.