# Constraint Propagation

> Source: https://modeladay.com/models/constraint-propagation/
> Category: principle | Topics: systems, cognition, decision | Difficulty: 3/5

## Definition

Constraint propagation repeatedly applies relationships among variables and their possible values. When one option is removed, check whether dependent options still have support. Keep propagating reductions until nothing changes or a contradiction appears.

## Core Rule

Constraint propagation repeatedly applies relationships among variables and their possible values. When one option is removed, check whether dependent options still have support. Keep propagating reductions until nothing changes or a contradiction appears.

## Opening Context

Say your neighborhood's Saturday talks use a ground-floor room that has thirty seats and is wheelchair accessible. The room upstairs seats fifteen and you have to take the stairs. Each room has a morning slot and an afternoon slot, four talks in all.

The accessible travel speaker uses a wheelchair and needs the room downstairs, so you give her the morning slot. She could have used either time, but after the posters come back, you discover the photography teacher can only come in the morning. Twenty people signed up and the fifteen-seat room is all that's left.

Even if you fill every chair upstairs, five people will still be standing. Where did the schedule go wrong?

That's where constraint propagation helps: settle one choice, then follow the rules to see which other choices that rules out. Let's schedule Saturday again, and see what to do if we run out of options.

## How It Works (Preview)

Before we redo the schedule, look at where the idea came from. In the early 1970s, artificial intelligence researcher David Waltz was teaching computers to read line drawings of blocks. A line could stand for several different kinds of edge.

He had the computer check whether each possible reading fit the readings of the lines it touched. Drop the ones that have no compatible neighbor, then check whatever else they connect to. Most possibilities disappear quickly, leaving only a few to try.

## When It Fails (Preview)

A schedule can look fine one square at a time and still give you trouble. It helps to know what to do when the crossing out stops.

## Full Lesson, Audio & Practice

Get the full Constraint Propagation breakdown, 5-minute audio lesson, interactive mechanism animation, and decision checklist in the ConceptFlow app:
- iOS App Store: https://apps.apple.com/app/conceptflow-mental-models/id6756862333
- Google Play: https://play.google.com/store/apps/details?id=com.juxianyp.conceptflow
- Web page: https://modeladay.com/models/constraint-propagation/

## Related Mental Models

- [Backtracking Search](https://modeladay.com/models/backtracking-search/)
- [Iceberg Model](https://modeladay.com/models/iceberg-model/)
- [Issue Tree](https://modeladay.com/models/issue-tree/)
