| OCR Text |
Show 12 1.7 Dependency vs. Constraint Based Model Maintenance. There are two ifTl)Ortant differences in the meaning of the dependency a :• b + c and the constraint a • b + c. The first difference is what may happen to the values of a orb when cis modified. A dependency is a record of how a particular value was derived whereas a oonstraint is a relation between a set of values. When c is changed, the dependency must recompute a, but the constraint is free to reoorTl>lJte either a or b. Because of the freedom constraints have to modify their constrained values, a constraint cannot be used to reoord the semantics of an assignment statement as a dependency can. The second difference is that a new dependency can replace another dependency whereas a new oonstraint adds to the set of constraints. For example, suppose a new dependency a := b + d is added to the original dependency a := b + c and a new constraint a • b + d Is added to the original constraint a-= b + c . Since a value may have only one derivation, the new dependency must replace the old dependency. The new statement actually changes a's derivation. However a value may be a part of any number of relations, so the new constraint is added to the set of constraints on a and b. The old constraint is left intact. Dependencies are superior to constraints for maintaining information about the derivation of a model, and how to rederive parts of the model efficiently. However constraints allow |