Side option in fix indent

Hello all

I am trying to understand the fix indent command using a small test system of a spherical static indenter with a single particle that moves with prescribed velocity. The system is simulated using the commands in the following input file and shown below
in.nanoidentation (531 Bytes)

units lj
atom_style atomic
boundary p p p

region mybox block 0.0 20.0 0.0 20.0 0.0 20.0
create_box 1 mybox

create_atoms 1 single 0.0 10.0 10.0
mass 1 1.0

pair_style none

fix 2 all move linear 20.0 NULL NULL
fix 1 all indent 1.0 sphere 10.0 10.0 10.0 1.0 side out units box
#fix 1 all indent 1.0 cylinder y 10.0 10.0 1.0 side in units box

thermo_style custom step f_1 f_1[1] f_1[2] f_1[3]
thermo_modify line one
thermo 1

dump myDump all atom 1 dump.lammpstrj

run 100

By construction, the indenter is located at (10, 10, 10) in LJ units, the particle is initially located at (0, 10, 10) and it moves with a constant velocity of 20.0 in the x-direction. Periodic boundary conditions are applied. When I set the side option to out, I get the following log file log.lammps.side_out (9.3 KB) which indicates a zero energy and force between the indented and the particle when the particle is outside the indenter region. Non-zero values appear only when the particle is located inside the indenter. The opposite trend is observed when I specify the side as in (see attached log file
log.lammps.side_in (9.3 KB) ). According to the manual

If the side keyword is specified as out , which is the default, then particles outside the indenter are pushed away from its outer surface, as described above.

so intuitively I would expect the opposite behavior from what I get. Looking at the fix_indent.cpp file lines 307 - 314, it seems that the force and energy between the indenter and the particle is zero if the side keyword is specified as out and their distance is greater than the indenter radius. Shouldn’t it be the other way round?

Thanks, Evangelos

I would expect the opposite. Please understand that your example is very unusual, since the indenter is usually much larger than the particles.

Please see this animation of the “indent” example from the LAMMPS examples tree.