Distribute the interactions between CNT and polyethylene

Dear Dr.axel

Hi,

I calculate total energy of (polyethylene+cnt) that is about -40000 kcal/mol. but when i calculate total energy of polyethylene and CNT, I see these are respectively, -35000 and -5000 kcal/mol. thus, E polyethylene + E cnt - E toatal =0. but I thunk that it must be non-zero because the interaction energy should be considered in both cases. How does LAMMPS distribute the interactions between CNT and polyethylene?

like any other MD code. LAMMPS has been around since 1995, don't you
think people would have noticed, if such a fundamental property would
be computed incorrectly?
it is *much* more likely, that your thinking, or force field input, or
how you compute E_polyethylene and E_cnt is wrong.

axel.

thanks for your reply.

computing total energy by using these scripts:

compute potcnt cnt pe/atom
compute kecnt cnt ke/atom

compute potpoly poly pe/atom
compute kepoly poly ke/atom

compute pet all reduce sum c_pot
compute petcnt cnt reduce sum c_potcnt
compute petpoly poly reduce sum c_potpoly
compute ket all reduce sum c_ke
compute ketcnt cnt reduce sum c_kecnt
compute ketpoly poly reduce sum c_kepoly

variable edifference equal (c_petcnt+c_petpoly)-(c_pet)

variable etotalall equal c_pet+c_ket
variable etotalcnt equal c_petcnt+c_ketcnt
variable etotalpoly equal c_petpoly+c_ketpoly
I use AIREBO and I verify it by another simulation.

thanks.
Best

there you go. the problem is in the way how you compute E_pet and E_cnt.

you compute them *in the presence* of the other object with the force
field covering both parts. what you compute is just the tally of the
energy contributions of all interactions to individual atoms and the
sum *should* be the total energy.

axel.