The Greenhouse Nutrient Pump
Activate the PUMP if both SENSOR and LIGHT are active, unless the DRY signal is also true. The ALERT must sound if either SENSOR or DRY is active but not both.
Replay this puzzle All puzzles
The truth table
Inputs on the left, outputs on the right. A circuit solves the puzzle when it reproduces every row.
| SENSOR | LIGHT | DRY | PUMP | ALERT |
|---|---|---|---|---|
| 0 | 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 0 | 1 |
| 0 | 1 | 0 | 0 | 0 |
| 0 | 1 | 1 | 0 | 1 |
| 1 | 0 | 0 | 0 | 1 |
| 1 | 0 | 1 | 0 | 0 |
| 1 | 1 | 0 | 1 | 1 |
| 1 | 1 | 1 | 0 | 0 |
What the table tells you
- PUMP is 1 in 1 of the 8 rows, so it is a single AND-shaped condition: one exact combination of the inputs. Every input matters: for each one there is a row where flipping it changes PUMP. The rows that turn it on: SENSOR=1, LIGHT=1, DRY=0.
- ALERT is 1 in 4 of the 8 rows, a balanced function, which is what XOR-like and single-input-like rules look like. It does not depend on LIGHT at all: flipping it never changes the output, so any gate reading it is wasted. The rows that turn it on: SENSOR=0, LIGHT=0, DRY=1; SENSOR=0, LIGHT=1, DRY=1; SENSOR=1, LIGHT=0, DRY=0; SENSOR=1, LIGHT=1, DRY=0.
The smallest known circuit: 9 gates
As a formula, one line per output:
PUMP = ((SENSOR AND LIGHT) AND NOT DRY)ALERT = (SENSOR XOR DRY)
As a netlist, in the order you would wire it. Each g is one gate; the last lines say which signal drives each output.
g1 = SENSOR NAND LIGHTg2 = DRY NAND DRYg3 = SENSOR NAND SENSORg4 = g1 NAND g1g5 = SENSOR NAND g2g6 = DRY NAND g3g7 = g4 NAND g2g8 = g5 NAND g6g9 = g7 NAND g7PUMP = g9ALERT = g8
The search ran out of budget before it could rule out every smaller circuit, so 9 is the best anyone found, not a proof. If you build it in fewer, the leaderboard records it. Gates that do not feed an output are never counted.
Leaderboard for the day
Nobody posted a result on the day. The circuit above is the reference.
← #44 The Coffee Machine Brew · #46 The Baker's Oven Timer →