A 40-mile stretch of a long-gone branch of the Nile may explain why the ancient monuments were built where they were.