DiscretizedVariable.numerical

DiscretizedVariable.numerical(indice)
Parameters:
  • index (int) – an index

  • indice (int)

Returns:

the numerical representation of the value at the given index

Return type:

float

Example

import pyagrum as gum

x = gum.DiscretizedVariable("x", "x", [0, 1, 5, 10])
x.numerical(1)  # the middle of the interval [1;5[
# 3.0

Class

DiscretizedVariable