# Exploring DF vs. RI Approximations

• Juanchotutata
In summary, there is confusion surrounding the terms "density fitting" and "resolution of the identity" in quantum chemistry. While they are often used interchangeably, the authors of a particular article argue that "density fitting" should be the preferred term. This is because, while they are mathematically similar, "resolution of the identity" involves a summation over states and an implied overlap metric, which are not present in density fitting. In practice, both methods require specifying an auxiliary basis set, but for different purposes - the main basis set for the actual calculation, and the auxiliary basis set for approximating two-electron integrals in density fitting.
Juanchotutata
Hi everybody!

I am trying to find the difference between density fitting (DF) and resolution of the Identity (RI) approximations. I have read the following in the article [J. Chem. Phys. 118, 8149 (2003)]:

"Density fitting mathematically resembles a resolution of the identity RI in the specific case where the fitting criterion and target integral type coincide. However, RIs in quantum mechanics usually involve a summation over states and an implied overlap metric, neither of which appear in density fitting. Furthermore RIs do not offer a framework in which to discuss fitting criteria, constraints or robust fitting."

I still do not know what this exactly means. Could anyone give me a hand?

Last edited by a moderator:

Juanchotutata said:
Hi everybody!

I am trying to find the difference between density fitting (DF) and resolution of the Identity (RI) approximations. I have read the following in the article [J. Chem. Phys. 118, 8149 (2003)]:

"Density fitting mathematically resembles a resolution of the identity RI in the specific case where the fitting criterion and target integral type coincide. However, RIs in quantum mechanics usually involve a summation over states and an implied overlap metric, neither of which appear in density fitting. Furthermore RIs do not offer a framework in which to discuss fitting criteria, constraints or robust fitting."

I still do not know what this exactly means. Could anyone give me a hand?

I agree, as written this is very confusing. In fact, the key comes later in that same paragraph:
Werner et al said:
In this work we therefore use the term DF-MP2 as a synonym for RI-MP2, and hope that other authors will accept this as the standard name.
So DF is a synonym for RI (which also meshes with my experience). I think what the authors meant by the quote above is that, while many researchers use "resolution of the identity" to refer to the density fitting approximation, the precise mathematical "resolution of the identity"
$$1=\sum_n |n\rangle\langle n|$$
is never actually used. Therefore, they're arguing that "density fitting" should be the term of art, as opposed to "resolution of the identity." At least that's my takeaway.

Juanchotutata

But I am confused, because when I perform my calculations on Molpro (maybe you have used it), I have to specify basis sets for density fitting and basis sets for resolution of the identity. So, if they are the same, why do I have to specify it twice?

Juanchotutata said:

But I am confused, because when I perform my calculations on Molpro (maybe you have used it), I have to specify basis sets for density fitting and basis sets for resolution of the identity. So, if they are the same, why do I have to specify it twice?
From the https://www.molpro.net/info/2012.1/doc/manual/node334.html:
" RI-MP2 is an alias for the command DF-MP2. "
The DF procedure invokes two basis sets. The first is the main basis set that is required for all calculations. The second is an auxiliary basis set used for the actual density fitting.

Density fitting is a way to speed up calculations of the two-electron integrals that appear in quantum chemistry calculations:
$$(ab|ij)=\int d\mathbf{r}_1 \int d\mathbf{r}_2 \frac{\phi_{a}(\mathbf{r}_1)\phi_{b}(\mathbf{r}_1)\phi_{i}(\mathbf{r}_2)\phi_{j}(\mathbf{r}_2)}{r_{12}}$$
The main issue is that transforming this integral from the atomic orbital basis to the molecular orbital basis scales as ##O(N^5)##. However, taking, e.g., ##\phi_{a}(\mathbf{r}_1)\phi_{b}(\mathbf{r}_1) = \rho_{ab}## and expanding ##\rho_{ab} = \sum_n (d_{ab})_n \chi_n## using an easily calculable auxiliary basis set ##\chi_n##, we can "cheat" and knock the integral transformation down to ##O(N^4)## (but if you choose your auxiliary basis set wisely, it ends up being closer to ##O(N^3)## in practice). So DF gives a nice speedup when doing things like MP2 calculations. The disadvantage is that you have to choose an auxiliary basis wisely in order to correctly approximate the density, or you might end up with a sizeable error in your calculations.

Juanchotutata and jim mcnamara
I think I understand it now. Thank you very much again!

## 1. What is the difference between DF and RI approximations?

The main difference between DF (density functional) and RI (resolution of identity) approximations is the way they handle the electron-electron interactions in a system. DF approximations use a set of mathematical equations to calculate the energy and electron density of a system, while RI approximations use a simplified version of these equations by assuming that the electron density can be expressed as a sum of simpler basis functions.

## 2. Which approximation is more accurate?

It is difficult to determine which approximation is more accurate as it depends on the specific system being studied. In general, DF approximations tend to be more accurate for smaller systems with a lower number of electrons, while RI approximations are more accurate for larger systems with a higher number of electrons. However, both approximations have their own strengths and limitations, and the choice of which one to use should be based on the specific research goals and system being studied.

## 3. How do these approximations affect computational efficiency?

DF approximations are more computationally intensive as they involve solving complex mathematical equations. On the other hand, RI approximations are less computationally demanding as they use simpler equations. This makes RI approximations more efficient for larger systems, as they can significantly reduce the computational time and resources required for calculations.

## 4. Can these approximations be combined?

Yes, it is possible to combine DF and RI approximations to take advantage of their strengths and improve the accuracy and efficiency of calculations. This is known as hybrid methods, where both approximations are used in different parts of the calculation. However, the implementation of these hybrid methods can be complex and may require specialized software or programming skills.

## 5. What are the current challenges in using these approximations?

One of the main challenges in using DF and RI approximations is finding the right balance between accuracy and efficiency. While DF approximations may provide more accurate results, they can be computationally demanding. On the other hand, RI approximations may be more efficient, but they may sacrifice some accuracy. Additionally, the development of new and improved approximations is an ongoing challenge in the field of computational chemistry.