How to set different soli-wall attraction forces as function of coordinates

Hi everyone,

I was following up to build a liquid droplet interacting with solid wall using many-body dissipative particle dynamics.

I could made a script to simulate a liquid droplet on static position but I was stuck how to set different attraction forces depending on the coordinates of droplets by the following correlation.

Asl (attraction forces) – x is the position of the liquid droplets

-8.662 x < -40

1.03 x 10-3x2 - 0.16 – 16.71 -40 ≤ x ≤ 40

-21.462 x > 40

My question is how to read the position of liquid droplets and how to update the attraction forces depending on the position into the script in LAMMPS.

I attached my script to let you make sense my problem.


It’s not clear if you are asking an mDPD Q, in which
case email Zhen Li.

Or if you are asking a more basic LAMMPS Q
that has nothing to do with mDPD, What is
attracted to what? Reading the position of
the liquid droplets means what? Just reading
them like any other particle from the input
data file?