## 5.1. abs_value

Origin

Arithmetic.

Constraint

$\mathrm{𝚊𝚋𝚜}_\mathrm{𝚟𝚊𝚕𝚞𝚎}\left(𝚈,𝚇\right)$

Usual name

$\mathrm{𝚊𝚋𝚜}$

Synonym

$\mathrm{𝚊𝚋𝚜𝚘𝚕𝚞𝚝𝚎}_\mathrm{𝚟𝚊𝚕𝚞𝚎}$.

Arguments
 $𝚈$ $\mathrm{𝚍𝚟𝚊𝚛}$ $𝚇$ $\mathrm{𝚍𝚟𝚊𝚛}$
Restriction
$𝚈\ge 0$
Purpose

Enforce the fact that the first variable is equal to the absolute value of the second variable.

Example
$\left(8,-8\right)$

The $\mathrm{𝚊𝚋𝚜}_\mathrm{𝚟𝚊𝚕𝚞𝚎}$ constraint holds since 8 is equal to $|-8|$.

Systems

abs in Choco, abs in Gecode.