Networks of Constraints: Fundamental Properties and Applications to Picture Processing