One day in 1595, while teaching a class of indifferent secondary school students about the conjunction of Mars and Jupiter, it occurred to him that, based on distances employed in the Copernican model, he could inscribe an equilateral triangle between the two orbits.
The insight struck him like a lightning bolt, and launched one of the most idiosyncratic investigations in the history of science. Kepler decided that a nested ordering of the five regular three-dimensional figures (called the Platonic Solids) might determine the distances between the planetary orbits.
At age 25 he published his idea in a short book entitled Mysterium Cosmographicum (The Sacred Mystery of the Cosmos).
One astronomer who learned of Kepler's hypothesis, the Danish nobleman Tycho Brahe, was impressed enough by Kepler's technical work to extend an offer of employment. From 1597 on, Kepler writes, Brahe “did not cease ... to invite me to come to him."
As Kepler's prospects for employment in the Catholic city of Graz in 1600 diminished in the context of rising religious tensions (Kepler was a Protestant), the young astronomer accepted Brahe's invitation to visit him. Kepler traveled overland to Prague.
Kepler saw this meeting as the work of divine providence.
“It is true that a divine voice, which enjoins humans to study astronomy, is expressed in the world itself, not in words or syllables, but in things themselves and in the conformity of the human intellect and senses with the sequence of celestial bodies and of their dispositions. Nevertheless, there is also a kind of fate, by whose invisible agency various individuals are driven to take up various arts, which makes them certain that, just as they are a part of the work of creation, the likewise also partake to a certain extent in divine providence." (Chapter 7 of the New Astronomy, Donahue translation, p. 183)
Kepler also said he thought it happened by "divine arrangement” that when he arrived Brahe's assistant "was intent upon Mars, whose motions provide the only possible access to the hidden secrets of astronomy, without which we would remain forever ignorant of those secrets.” (Donahue translation, p. 185)
Mars has the most irregular orbit of all the planets. Had Kepler commenced his work on a planet with a more regular orbit, his key insights might not have developed.