19.4 How to plot the exchange potential

It is recommended to check plots of the exchange potential for both OEP-EXX and LHF potential, to avoid spurious numerical oscillations (which usually originates from too small or too large basis-set). To plot the LHF potential over a line, add to the control file (e.g. for a 2000 points along the z axis):

$pointval xc geo=line  
 grid1 vector 0 0 1 range -10,10 points 2000  
 origin 0 0 0

and run odft -proper. The plotting subroutine reads the file lhfcg, contaning the matrix elements of the Correation potential is already generated by a previous run. The file tx.vec will be generated with four columns (distance, LHF potential, Slater potential, Correction potential).

The procedure to plot the OEP-EXX potential is the same. In this case the expansion coefficients (see Eq. 19.6) are read from the file oepcVx.dat (cartesian format). The file tx.vec will be generated with four columns (distance, EXX potential, EXX potential, zero).