Dear LAMMPS users,
I am using pair_style table to tabulate the potentials of J. Chem. Phys. 131, 014504 (2009) (Eqs. 23).
Here are the pair_style and pair_coeff commands I’m using:
pair_style hybrid zero 1.0 table linear 55000
pair_coeff 1 1 table potentials.table INV_POW
pair_coeff 2 2 table potentials.table GEN_GAUSS
pair_coeff 1 2 zero 1.0
where the number of points N=5500 is the same as the number of entries in both sections (INV_POW and GEN_GAUSS) of the .table file.
The distance values appearing in the .table file are uniformly spaced with spacing dr=10^5 for both potentials.
Here is an extract my .table file:
INV_POW
N 55000 R 0.95 1.5
1 0.9500000000 2.8528500312e+04 6.0060000656e+06
2 0.9500100000 2.8468503803e+04 5.9933061343e+06
3 0.9500200000 2.8408634099e+04 5.9806391653e+06
…
GEN_GAUSS
N 55000 R 0.00001 0.55
1 0.0000100000 1.0000000000e+00 8.0752791445e36
2 0.0000200000 1.0000000000e+00 4.1345429220e33
3 0.0000300000 1.0000000000e+00 1.5894571940e31
…
I have tried using the parameters R, RSQ and also no parameter.
With no parameter, everything works “almost” fine, apart from the following warning message:
WARNING: 2283 of 55000 force values in table are inconsistent with dE/dr.
Should only be flagged at inflection points (…/pair_table.cpp:483)
which doesn’t worry very much since it should come from the inflection point of the GEN_GAUSS potential, and the number of problematic values is small compared to the total number of values (in case I’m wrong and I should be worried about this, please let me know).
When using the R parameter with rlo and rhi values corresponding to the smallest and largest distances appearing in two sections of the .table file, everything is fine, in the sense that I obtain the same warning message reported above.
However, when using RSQ with the same rlo and rhi values, e.g.:
INV_POW
N 55000 RSQ 0.95 1.5
I get more warnings:
WARNING: 54793 of 55000 force values in table are inconsistent with dE/dr.
WARNING: 54998 of 55000 distance values in table with relative error
WARNING: 24791 of 55000 force values in table are inconsistent with dE/dr.
WARNING: 54998 of 55000 distance values in table with relative error
My questions are:

Am I using the RSQ parameter in the wrong way? As far as I understood, the same rlo and rhi values can be used with R or RSQ since the manual page says that “For “R”, distances uniformly spaced between rlo and rhi are computed; for “RSQ”, squared distances uniformly spaced between rlorlo and rhirhi are computed.”

Why does the manual suggest to use the RSQ or BITMAP parameter in conjunction with the linear style (“Use N in the pair_style command equal to the “N” in the tabulation file, and use the “RSQ” or “BITMAP” parameter, so additional interpolation is not needed.”)? What is the drawback of using no parameter or the R parameter?
Please excuse me if these questions are trivial, but I started using tabulated potentials in LAMMPS fairly recently.
I also have a minor suggestion: it would be helpful if the warning message LAMMPS gives (force values in table are inconsistent with dE/dr) would point out at which potential is problematic in cases in which multiple tabulated potentials are used (such as my case).
Thank you in advance.
Best regards,
Valerio