didppy.log
- didppy.log(x, y)
Returns an expression representing the logarithm of
x
using yas
a base.- Parameters:
x (IntExpr, IntVar, IntResourceVar, FloatExpr, FloatVar, FloatResourceVar, int, or float) – Input.
y (IntExpr, IntVar, IntResourceVar, FloatExpr, FloatVar, FloatResourceVar, int, or float) – Base.
- Returns:
The logarithm.
- Return type:
Examples
>>> import didppy as dp >>> model = dp.Model() >>> state = model.target_state >>> x = dp.FloatExpr(4.0) >>> y = dp.FloatExpr(2.0) >>> dp.log(x, y).eval(state, model) 2.0