Threshold constraints

A threshold discrete constraint can be applied to a property to restrict the property values to 0 or at least the threshold value (= 0 or > = threshold).

A property can have a threshold discrete constraint if the property reference is preceding with the Threshold keyword.

For example, Threshold: Class name.property name, value; where:

  • Class name.property name is a property reference for which the threshold constraint is to be applied.
  • value is the value of the threshold for which the property is restricted. Possible options:
    • [OPT_THRE_01] – (constant number literal): This value is used as the threshold value for all Class name.property name threshold constraints.
    • [OPT_THRE_02] – (attributes): The threshold value per Resource for Class name.property name from the related resources attribute value.
    • [OPT_THRE_03] – (property): The threshold value per Resource and Bucket for Class name.property name from the property value for the related Resource and Bucket.
    • [OPT_THRE_04] – (default property): The threshold value per Resource for Class name.property name from the related resources default property value.
    • [OPT_THRE_05] – (variable): The variable value is used as the threshold value for all Class name.property name threshold constraints. When value refers to an attribute, property or default property, the value for the threshold constraint from the attribute, property or default property, within the context of a Resource and Bucket.
    • [OPT_THRE_06]: A threshold value of 0 can be used to prevent the threshold constraint being applied. A non-zero threshold is a discrete constraint which has a major negative impact on the solver performance.
Table 1. Examples
Requirement Value
Values for purchase quantity must be 0, or at least 100. threshold: Purchase Order.purchase quantity, 100;
Values for purchase quantity must be 0 or at least the value of the resources default property value minimum purchase (*). threshold: Purchase Order.purchase quantity, minimum purchase (*);
Note: 
  • The value for minimum purchase (*) can differ per resource.
  • Threshold constraints cannot be created for Resources with a default property minimum purchase (*) value of 0.
Values for purchase quantity must be 0 or at least the value of the property value minimum purchase. threshold: Purchase Order.purchase quantity, minimum purchase;
Note: 
  • The value for minimum purchase can differ per resource and bucket.
  • Threshold constraints cannot be created for Resources and Buckets which have a property minimum purchase value of 0.
Values for purchase quantity must be 0 or at least the value of the value for variable $minimum_purchase. threshold: Purchase Order.purchase quantity, $minimum_purchase;
Note: The value for the $minimum purchase variable is applied when the solver is executed.