# SaveInMemory¶

class SaveInMemory

Cache self energies in memory.

## Usage Examples¶

Examples on how to use SaveInMemory() and other storage strategies can be found in the Usage Examples of RecursionSelfEnergy.

## Notes¶

In each step of the SCF loop of a device calculation, the same self energies need to be evaluated.

The SaveInMemory() storage strategy specifies that each self energy is calculated only once and stored in memory. The self energies are reused in subsequent iterations. This strategy can significantly improve performance, but requires additional memory.

The StoreOnDisk() strategy provides a similar performance improvement without the additional memory requirements.