ArticleslgStudy

science

Heyawake

Heyawake is a science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Heyawake rather than just read about it. In short: Heyawake (Japanese: へやわけ, "divided rooms") is a binary-determination logic puzzle published by Nikoli. As of 2013, five books consisting entirely of Heyawake puzzles have been published by Nikoli.

Heyawake — main illustration
Heyawake — illustration

Key takeaways

  • Heyawake belongs to science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Heyawake to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Heyawake from memory before moving on to harder problems.

Reference excerpt

Heyawake (Japanese: へやわけ, "divided rooms") is a binary-determination logic puzzle published by Nikoli. As of 2013, five books consisting entirely of Heyawake puzzles have been published by Nikoli. It first appeared in Puzzle Communication Nikoli #39 (September 1992).

Rules Heyawake is played on a rectangular grid of cells with no standard size; the grid is divided into variously sized rectangular "rooms" by bold lines following the edges of the cells. Some rooms may contain a single number, typically printed in their upper-left cell; as originally designed, every room was numbered, but this is rarely necessary for solving and is no longer followed. Some of the cells in the puzzle are to be painted black; the object of the puzzle is to determine for each cell if it must be painted or must be left blank (remaining white). In practice, it is often easier to mark known "blank" cells in some way—for example, by placing a dot in the center of the cell. The following rules determine which cells are which:

Rule 1: Painted cells may never be orthogonally connected (they may not share a side, although they can touch diagonally). Rule 2: All white cells must be interconnected (form a single polyomino). Rule 3: A number indicates exactly how many painted cells there must be in that particular room. Rule 4: A room which has no number may contain any number of painted cells, or none. Rule 5: Where a straight (orthogonal) line of connected white cells is formed, it must not contain cells from more than two rooms—in other words, any such line of white cells which connects three or more rooms is forbidden.

Solution methods Note that the first two rules also apply to (for example) Hitori puzzles, and thus these puzzles share some of their solving methods:

If it is discovered that a cell is painted black, it is immediately known that all of the four (orthogonally) adjacent cells must be white (from Rule 1). A section of (orthogonally) contiguous white cells cannot be cut off from the rest of the grid (from Rule 2). Black cells may not form a diagonal split across the grid nor a closed loop; any cell that would complete such a "short circuit" must be white instead. More complex puzzles require combining Rule 1 and Rule 2 to make progress without guessing; the key is recognizing where the cells must assume one of two checkered patterns and one leads to a short circuit. The remaining rules differentiate Heyawake from other "dynasty" puzzles:

Rule 5 is the defining rule of the puzzle; black cells must be placed to prevent any (orthogonal) lines of white cells that cross two room borders ("spanners"). Numbered rooms typically provide solvers a starting place, among other deductions. The following are the simplest examples of rooms defined at the onset: A 2×2 room in the corner of the grid containing a '2' must have one painted cell in the grid corner and the second painted square diagonally outward from the corner. As painted squares may not share a side (Rule 1), the only alternative would disconnect the forced white cell in the corner, violating Rule 2. A 2×3 room with the 3-cell side along a grid border containing a '3' must have a painted cell in the center of the 3-cell side along the border and the other two in the opposite corners of the room, for similar reasons to the above. A 1×3 room containing a '2' must have the two end cells painted, as a painted centre cell would force a breach of rule 1. More generally, a 1×(2n−1) room containing an n must have every other cell within it painted. A 3×3 room containing a '5' must have a checkered pattern, with painted cells in all corners and the center.

Variants Heyawacky is played like Heyawake, but rooms are not necessarily rectangular. Orthogonal lines of white cells may not exit and re-enter a room; i.e. such lines may not straddle more than one region boundary. Symmetry Heyawake (also known as ekawayeH and Ayeheya) is played like Heyawake, but the placement of shaded cells in each room is rotationally symmetric about its center.

Computational complexity The computational complexity of Heyawake has been analyzed: deciding for a given instance of Heyawake whether there exists a solution to the puzzle is NP-complete. An interpretation of this theoretical result in layman's terms is that this puzzle is as hard to solve as the Boolean satisfiability problem, which is a well studied difficult problem in computer science.

See also List of Nikoli puzzle types

Notes

References Holzer, Markus; Ruepp, Oliver (2007). "The Troubles of Interior Design–A Complexity Analysis of the Game Heyawake" (PDF). Proceedings, 4th International Conference on Fun with Algorithms, LNCS 4475. Springer, Berlin/Heidelberg. pp. 198–212. doi:10.1007/978-3-540-72914-3_18. ISBN 978-3-540-72913-6.

External links Nikoli's page on Heyawake Archived 2013-11-09 at the Wayback Machine

Illustrations

Heyawake: A Heyawake puzzle
A Heyawake puzzle

Worked examples

Example 1 — a first encounter with Heyawake

Start with the simplest possible case. Write down what Heyawake claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Heyawake before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Heyawake ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Heyawake

In research
Heyawake appears in science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Heyawake in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Heyawake is common in secondary-school and first-year university syllabi. It links to neighbouring topics Japanese board games, Logic puzzles, NP-complete problems, so understanding it makes those chapters shorter.
In everyday life
Look for Heyawake outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Heyawake” →

How to study Heyawake in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Heyawake means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Heyawake out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Heyawake in simple terms?

Heyawake (Japanese: へやわけ, "divided rooms") is a binary-determination logic puzzle published by Nikoli. As of 2013, five books consisting entirely of Heyawake puzzles have been published by Nikoli.

Why does Heyawake matter?

Because it connects several science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Heyawake?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Heyawake.

Tags

  • Japanese board games
  • Logic puzzles
  • NP-complete problems

Keep exploring