And He Built a Crooked House

 ' —And He Built a Crooked House— '  is a science fiction short story by American writer Robert A. Heinlein, first published in Astounding Science Fiction in February 1941. It was reprinted in the anthology Fantasia Mathematica (Clifton Fadiman, ed.) in 1958, and in the Heinlein collections The Unpleasant Profession of Jonathan Hoag in 1959 and The Best of Robert Heinlein in 1973. The story is about a mathematically inclined architect named Quintus Teal who has what he thinks is a brilliant idea to save on real estate costs by building a house shaped like the unfolded net of a tesseract. The title is paraphrased from the nursery rhyme "There Was a Crooked Man".

Plot summary
Quintus Teal, a "Graduate Architect" in the Los Angeles area, wants architects to be inspired by topology and the Picard–Vessiot theory. During a conversation with friend Homer Bailey he shows models made of toothpicks and clay, representing projections of a four-dimensional tesseract, the equivalent of a cube, and convinces Bailey to build one. The house is quickly constructed in an "inverted double cross" shape (having eight cubical rooms, arranged as a stack of four cubes with a further four cubes surrounding the second cube up on the stack). The night before Teal is to show Bailey and his wife, Matilda, around the house, an earthquake occurs. The three of them arrive the next morning to find what appears to be just a single cubical room.

Inside, they find the upper floors completely intact, but the stairs seem to form a closed loop. As all the doors and windows lead directly into other spaces, there seems to be no way to get back out. At one point, they look down a hallway and are shocked to see their own backs. Teal realizes that the earthquake caused the house to fold into an actual tesseract.

In attempting to move from one room to another by way of a French window, Teal falls outside and lands in shrubbery. Exploring further, they find that the windows of the original top room do not connect where they mathematically "should". One gives a dizzying view from above the Empire State Building, another an upside-down view of a seascape. A third window looks out on a place of no-space, with no color, not even black. The fourth window looks out on an unearthly desert scene. Just then another earthquake hits, and so they exit in a panic through the open window. They find themselves in a desert with twisted, tree-like vegetation around them, with no sign of the house or the window they just jumped through. At first they fear that they might be on another planet. They are relieved when they discover, from a passing truck driver, that they are in Joshua Tree National Park (referred to by the driver as Joshua Tree National Forest).

Returning to the house, they find it has vanished. Teal remarks that it must've "fell through into another section of space" on the last earthquake, and that he should've "anchored it at the foundations".

The story ends with Teal rejoicing that he's now got a "great new revolutionary idea for a house", and Mr. Bailey attempting to punch him out of frustration, which Teal quickly evades, as "he was always a man of action".

Address
The story gives Quintus Teal's address as 8775 Lookout Mountain Avenue in Hollywood (34.10918°N, -118.38464°W), across the street from "the Hermit, the original Hermit of Hollywood". That address is across the street from Heinlein's own house at the time the story was written.

Reception
Stating that it "was, for many readers, the first introduction to four-dimensional geometry that held any promise of comprehensibility", Carl Sagan in 1978 listed "—And He Built a Crooked House—" as an example of how science fiction "can convey bits and pieces, hints and phrases, of knowledge unknown or inaccessible to the reader".