### Random Post

### Recent Posts

### Recent Comments

### Archives

### Categories

- article (11)
- enigma (1,115)
- misc (2)
- project euler (2)
- puzzle (29)
- site news (43)
- tantalizer (29)
- teaser (3)

### Site Stats

- 166,357 hits

Programming Enigma Puzzles

18 March 2016

Posted by on **From New Scientist #1485, 5th December 1985** [link]

I was visiting my Uncle Ever-Clever, the inventor. “What are all these little cubes and boxes?” I asked. “Ah,” he said, “that’s a mathematical game I’ve been working on involving cubelets, each of whose faces is either black or white. I realised that I’d have my work cut out making each cubelet individually, so I hit upon the idea of taking a large cube of black wood and an equal cube of white wood, then painting the black one white and the white one black.”

“How would that help?” I asked woodenly.

“Well, when you saw them up you obtain cubelets having various combinations of white and black faces. Every distinguishable combination of black faces and white faces manufacturable by these means occurs exactly once in a complete set of my Chock-a-Block cubes.

“And do all-white and all-black each count as combinations?” I asked.

“Of course, you blockhead!” was the affectionate replay as he closed the Brewster window (he suffered from sunspots).

“Well, I transformed the two painted cubes without wastage of wood into equal cubelets in such a way that, when they were sorted into complete sets, the amount of wood left over was the minimum possible. These boxes each contain a full set of my cubelets; those over there between the Wimshurst bicycle and the Luminous Moondial are the ones left over… But you must be famished, dear boy; let me ring for a pot of Logwood Tea and some Dwarfstar Cake.”

How many boxes were there, how many cubelets did they each contain and how many cubelets were left over?

[enigma337]

Advertisements

%d bloggers like this:

This Python program runs in 33ms.

Solution:There are 16 boxes, each box containing a set of 7 cubelets. There were 138 cubelets left over.The minimum amount of wastage per set occurs when

n=5(i.e. the large cubes are each cut into 5×5×5 = 125 cubelets).w3is always 16, and asnincreases beyond 4 the number of this type of cubelet becomes the limiting factor in constructing complete sets. So the amount of wastage per set increases forn ≥ 5.The wording on this enigma is poor since there are several possible interpretations of the meaning of “the amount of wood left over was the minimum possible”.

It certainly could have been clearer on the measure.

I used a wastage measure of the number of spare cubelets per complete set of cubes created, which is at a minimum when

n = 5. Another (perhaps more) reasonable measure would be to measure the total volume of waste wood per complete set of cubes created – but that’s also at a minimum atn = 5.The minimum total volume of waste wood (without considering how many complete sets are created) also occurs at

n = 5. However if we just consider the total number of waste cubes, then that is at a minimum whenn = 3.In retrospect I think I probably should have used a measure of

w / (t * s)at line 35