Reverse engineering the Pyramids