Logo GenPRES

Rate Module

Wraps an order variable as a rate, with the name part rte, and applies the order variable functions to it.

Functions and values

Function or value Description

apply f

Full Usage: apply f

Parameters:
Returns: Rate -> Rate

Apply a function to the OrderVariable in a Rate

f : OrderVariable -> OrderVariable
Returns: Rate -> Rate

applyConstraints

Full Usage: applyConstraints

Returns: Rate -> Rate

Apply the constraints of a Rate to the OrderVariable Variable

Returns: Rate -> Rate

applyDefinedConstraints

Full Usage: applyDefinedConstraints

Returns: Rate -> Rate

Set the Variable of a Rate to its defined constraints

Returns: Rate -> Rate

applyOnlyMaxConstraints

Full Usage: applyOnlyMaxConstraints

Returns: Rate -> Rate
Returns: Rate -> Rate

convertFirstUnit u

Full Usage: convertFirstUnit u

Parameters:
Returns: Rate -> Rate

Convert the first unit of a Rate (e.g., mg/h -> g/h)

u : Unit
Returns: Rate -> Rate

convertTimeUnit u

Full Usage: convertTimeUnit u

Parameters:
Returns: Rate -> Rate

Convert the time unit of a Rate (e.g., mg/h -> mg/min)

u : Unit
Returns: Rate -> Rate

create n un tu

Full Usage: create n un tu

Parameters:
    n : Name - The Name of the Rate
    un : Unit - The Unit of the Rate
    tu : Unit - The Time Unit of the Rate

Returns: Rate

Create a Rate with name n

n : Name

The Name of the Rate

un : Unit

The Unit of the Rate

tu : Unit

The Time Unit of the Rate

Returns: Rate

fromDto dto

Full Usage: fromDto dto

Parameters:
Returns: Rate

Create a Rate from a Dto

dto : Dto
Returns: Rate

fromOrdVar

Full Usage: fromOrdVar

Returns: OrderVariable list -> Rate -> Rate

Replaces a Rate with the OrderVariable of the same name from a list, when the list has one.

Returns: OrderVariable list -> Rate -> Rate

hasConstraints

Full Usage: hasConstraints

Returns: Rate -> bool
Returns: Rate -> bool

isNonZeroPositive

Full Usage: isNonZeroPositive

Returns: Rate -> bool
Returns: Rate -> bool

isSolved

Full Usage: isSolved

Returns: Rate -> bool

Check whether a Rate is solved

Returns: Rate -> bool

isWithinConstraints useCalc

Full Usage: isWithinConstraints useCalc

Parameters:
    useCalc : bool

Returns: Rate -> bool

Check whether a Rate is within its constraints

useCalc : bool
Returns: Rate -> bool

name

Full Usage: name

Returns: string
Returns: string

setMaxValue

Full Usage: setMaxValue

Returns: Rate -> Rate

Set the maximum value for a Rate

Returns: Rate -> Rate

setMedianValue

Full Usage: setMedianValue

Returns: Rate -> Rate

Set the median value for a Rate

Returns: Rate -> Rate

setMinValue

Full Usage: setMinValue

Returns: Rate -> Rate

Set the minimum value for a Rate

Returns: Rate -> Rate

setNthValue nth

Full Usage: setNthValue nth

Parameters:
    nth : int

Returns: Rate -> Rate

Sets the values to the nth value, counted from 0, but not above the maximum.

nth : int
Returns: Rate -> Rate

setPercValue perc

Full Usage: setPercValue perc

Parameters:
    perc : int

Returns: Rate -> Rate

Sets the values to the value at perc percent of the way through all values.

perc : int
Returns: Rate -> Rate

setToNonZeroPositive

Full Usage: setToNonZeroPositive

Returns: Rate -> Rate

Set a Rate to non-zero positive values

Returns: Rate -> Rate

toDto

Full Usage: toDto

Returns: Rate -> Dto

Create a Dto for a Rate

Returns: Rate -> Dto

toOrdVar arg1

Full Usage: toOrdVar arg1

Parameters:
Returns: OrderVariable

Get the OrderVariable in a Rate

arg0 : Rate
Returns: OrderVariable

toString

Full Usage: toString

Returns: Rate -> string

Turn a Rate to a string

Returns: Rate -> string

toStringWithConstraints

Full Usage: toStringWithConstraints

Returns: Rate -> string

Get a string representation of a Rate (including constraints)

Returns: Rate -> string

toValueUnitMarkdown

Full Usage: toValueUnitMarkdown

Returns: int -> Rate -> string

Get a ValueUnit Markdown representation of a Rate

Returns: int -> Rate -> string

toValueUnitString

Full Usage: toValueUnitString

Returns: int -> Rate -> string

Get a ValueUnit string representation of a Rate

Returns: int -> Rate -> string

toValueUnitStringList

Full Usage: toValueUnitStringList

Returns: Rate -> string option

Gets the value set of a Rate as a Dutch string; None without a value set.

Returns: Rate -> string option

Type something to start searching.