The Buddha told a story about a time when the Earth was not yet formed. The sentient beings in this time normally lived in the realm of Abhassara, in radiant light and nourished by celestial joy. Then came a time when the Earth was in the process of forming yet still uninhabitable. One of these beings in the Abhassara realm died (due to the exhaustion of his karma) and was reborn in the higher realm called the Brahma realm and lived alone in the palace there. From living alone for so long a time, this being grew distressed and longed for a companion.