The Cassowary linear arithmetic constraint solving algorithm
Greg J. Badros, Alan H. Borning, Peter J. Stuckey · ACM Transactions on Computer-Human Interaction · 2001
Linear equality and inequality constraints arise naturally in specifying many aspects of user interfaces, such as requiring that one window be to the left of another, requiring that a pane occupy the leftmost third of a window, or preferring that an object be contained within a rectangle if possible. Previous constraint solvers designed for user interface applications cannot handle simultaneous linear equations and inequalities efficiently. This is a major limitation, as such systems of constraints arise often in natural declarative specifications. We describe Cassowary---an incremental algorithm based on the dual simplex method, which can solve such systems of constraints efficiently. We have implemented the algorithm as part of a constraint-solving toolkit. We discuss the implementation of the toolkit, its application programming interface, and its performance.
Cited by 177 works. doi:10.1145/504704.504705
Authors
References
- Numerical recipes in Pascal: the art of scientific computing
- Sketchpad
- Numerical Recipes--The Art of Scientific Computing.
- Sketch pad a man-machine graphical communication system
- The perceptual span and peripheral cues in reading
- Fast contact force computation for nonpenetrating rigid bodies
- Programming with Constraints
- Stylization and abstraction of photographs
- An Object-Oriented Architecture for Constraint-Based Graphical Editing
- Level of Detail for 3D Graphics