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 #213
213. As regards love and wisdom, love is the end, wisdom the cause or means, and useful endeavor the effect, and useful endeavor embraces, contains, and is the foundation of love and wisdom. Moreover, useful endeavor so embraces and so contains them that all the qualities of the love and all the qualities of the wisdom are actually present in it, useful endeavor being the concurrence of these.
It should be rightly known, however, that it is all homogeneous and accordant qualities of love and wisdom that are present in useful endeavor, in accordance with the observations presented and demonstrated above in the discussion in nos. 189-194.