329. We can tell what a useful function is from the goal of the creation of the universe. The goal of the creation of the universe is to bring about an angelic heaven; and since an angelic heaven is the goal, so is humanity or the human race, since that is where heaven comes from. It follows, then, that everything that has been created is an intermediate goal, and that the functions are useful in the sequence, on the level, and in the specific way that they relate to humanity, and through humanity to the Lord.
Divine Love and Wisdom #32
32. It is because the divine essence itself is love and wisdom that the universe and everything in it, whether living or not, depends on warmth and light for its survival. Warmth in fact corresponds to love and light corresponds to wisdom, which also means that spiritual warmth is love and spiritual light is wisdom. But more on this as well later [83-84, 89-92].