Tabulated Potential

Dear LAMMPS users,

I have tabulated bonded and non-bonded potentials given as N discrete points in a data file. According to the manual, LAMMPS uses cubic spline to interpolate energy and forces at each of N distances. My question is what boundary conditions are used in LAMMPS.

In my tabulated potential file, the value of the second derivative at the end knots is none zero (that is, there is some curvature). If LAMMPS sets the second derivative at the end knots to zero it makes some deviation at the boundaries. In this case, should I use linear interpolation or there is another alternative method.


Morteza Ziaee

Interpolation is needed for the intermediate points for which the force and potential is not numerically given. As long as the integration of equations of motion is concerned second derivative is not required. If it is needed as boundary conditions it can also be given numerically I guess.

For the pair_style table (and bond_style table, etc)

there is an optional FPRIME (or FP) which sets the

derivative of the force at the 2 end points. E.g.

in the pair_style table doc page:

If used, the parameter “FPRIME” is followed by 2 values fplo and fphi which are the derivative of the force at the innermost and outermost distances listed in the table. These values are needed by the spline construction routines. If not specified by the “FPRIME” parameter, they are estimated (less accurately) by the first 2 and last 2 force values in the table. This parameter is not used by BITMAP tables.

Is this what you are asking about?

If you are asking about a higher order derivative,

I don’t think it is required (or used) by the spline

inititialiization. I.e. only the fprime values are

needed, along with all the nodal point values in

the file.