Defining a non-bonded potential

Dear all,

I am planning to design a system where I have a sphere and in the middle of this sphere, I have a square well like non-bonded potential. When particles come into the region where the potential exists, they should experience it. Is it possible to do this with LAMMPS (I am sure it is, but am not sure how exactly) and how do I start looking at this problem; what are the essential files that require changes and has anyone built set-ups that resemble the one I need.

Thank you very much for your time.

With best wishes, Anna

You can use pair_style table to tabulate a pairwise
potential with any shape you lilke. Perfectly square
is not possible in that manner b/c it has infinite
slope. But nearly square is OK.

Steve

Dear all,

I am planning to design a system where I have a sphere and in the middle of this sphere, I have a square well like non-bonded potential. When particles come into the region where the potential exists, they should experience it. Is it possible to do this with LAMMPS (I am sure it is, but am not sure how exactly) and how do I start looking at this problem; what are the essential files that require changes and has anyone built set-ups that resemble the one I need.

are you sure you need to implement this as a non-bonded potential?
but rather need to implement this as a fix?
in a similar manner as fix indent, or fix wall, for example.

axel.

Yeah, it sounded like she wanted to use something like fix indent.
(But perhaps with a finite energy barrier height).

(If fix_indent does not work for her, then one way that comes to mind
is she could apply "set force" and/or "set velocity" to immobilise a
single atom at the center of the simulation box, Then she could define
a tabular pair style between it and other atom types. This would
require defining a hybrid pair_style. The upper radial cutoff would
would be large, and I don't know if this would affect the simulation
speed adversely. Try it and report back.) If there is another way to
do this, I'm curious to know.

Cheers
Andrew

Dear all,

Thank you so very much for your suggestions Steve, Axel and Andrew, your input is always extremely valuable :slight_smile: I will try different solutions and see how they work; will let you know about the outcome anyway.

With best wishes,
Anna

My advice to tabulate a pair style was probably wrong.
If you have just a single "sphere" and want all the
particles to interact with it, then something fix indent
which the others recommended is the way to go.

Steve