As a reminder, the expression (P ijkl ⊆ P |i, m ijkl ⊆ m) is shorthand for denoting that the quantity (P ijkl |im ijkl ) is computed as a subset of the density-fitted ERI with dense indices (P |im). The fact that the slices may come from dense quantities does not affect the runtime of the DLPNO-(Q) algorithm, since there is a constant number of memory accesses per quadruplet. In Algorithm 2, the pseudocode for computing Γ abcd ijkl (Equation ) is presented. In Algorithms 3 and 4, the pseudocode for computing the [Q] and (Q) energies (Equations 25 and 26) given amplitudes t abcd ijkl is presented. In these algorithms, a "computed list" is utilized in cases where not every index in ijkl is unique to avoid double-counting. In all these algorithms, permutation operators P (i,j,k,l) , as well as its adjoint P † (i,j,k,l) , are defined, with ( i, j, k, l) representing the tuple (i, j, k, l) in ascending order.