The first several chapters of Mishneh Torah (ch.3-4) include some pseudo-scientific (Aristotelian?) passages, seemingly unrelated to practical Halacha, for example,
"The celestial spheres are called heaven, firmament, habitation and nebula, and there are nine such spheres; ... the spheres are pure and transparent as glass or sapphire, therefore the stars which are in the eighth sphere, seem to be beneath the first sphere."
"All of these spheres which encircle the universe, are round as a globe, and the earth is suspended in the center... All of the stars and spheres are beings, endowed with a soul, intelligence and understanding; they continue a purposeful life and are conscious of the existence of Him Who spoke and the universe sprang forth. "
"These four elements, namely: fire, air, water and earth, are the elements of all the creatures beneath the expanse; all that be whether of man, beast, fowl, creeping thing, fish, vegetation, minerals, precious stones, pearls, structural stones, mountains and glaciers, the body of each and every one is the joint issue of these four elements. "
Why all those explanations are needed in a Halachic compendium? What Biblical Mitzvahs do they relate to?
At first, I thought it to be a part of the Mitzvah of knowing Hashem, but the end of the second chapter suggests that its details are explained only in the first two chapters.