check_if_numeric_type_and_cache

(function from pyomo.core.expr.numvalue)

pyomo.core.expr.numvalue.check_if_numeric_type_and_cache(obj)[source]

DEPRECATED.

Test if the argument is a numeric type by checking if we can add zero to it. If that works, then we cache the value and return a NumericConstant object.

Deprecated since version 6.4.3: check_if_numeric_type_and_cache() has been deprecated in favor of just calling as_numeric()