He was the sixth child in the family, although two of his brothers and sisters were from his father's first marriage. Among his earliest memories was the marching of Prussian and Austrian troops into Kiel during the Danish-Prussian war of 1864. In 1867 the family moved to Munich, and Planck enrolled in the Maximilians gymnasium school, where he came under the tutelage of Hermann Müller, a mathematician who took an interest in the youth, and taught him astronomy and mechanics as well as mathematics. It was from Müller that Planck first learned the principle of conservation of energy. Planck graduated early, at age 17. This is how Planck first came in contact with the field of physics.