Modification pair_yukawa.cpp

Dear LAMMPS users,

Where did you put the new/modified files?: The new files are in the src folder

What is the output of “make ps”? The output I get when I make ps is:

Installed YES: package ASPHERE

Installed YES: package BODY

Installed YES: package CLASS2

Installed YES: package COLLOID

Installed YES: package COMPRESS

Installed YES: package CORESHELL

Installed YES: package DIPOLE

Installed YES: package GPU

Installed YES: package GRANULAR

Installed YES: package KIM

Installed YES: package KOKKOS

Installed YES: package KSPACE

Installed YES: package MANYBODY

Installed YES: package MC

Installed YES: package MEAM

Installed YES: package MISC

Installed YES: package MOLECULE

Installed YES: package MPIIO

Installed YES: package OPT

Installed YES: package PERI

Installed YES: package POEMS

Installed YES: package PYTHON

Installed YES: package QEQ

Installed YES: package REAX

Installed YES: package REPLICA

Installed YES: package RIGID

Installed YES: package SHOCK

Installed YES: package SNAP

Installed YES: package SRD

Installed YES: package VORONOI

Installed YES: package USER-ATC

Installed YES: package USER-AWPMD

Installed YES: package USER-CG-CMM

Installed YES: package USER-COLVARS

Installed YES: package USER-DIFFRACTION

Installed YES: package USER-DPD

Installed YES: package USER-DRUDE

Installed YES: package USER-EFF

Installed YES: package USER-FEP

Installed YES: package USER-H5MD

Installed YES: package USER-INTEL

Installed YES: package USER-LB

Installed YES: package USER-MANIFOLD

Installed YES: package USER-MGPT

Installed YES: package USER-MISC

Installed YES: package USER-MOLFILE

Installed YES: package USER-NC-DUMP

Installed YES: package USER-OMP

src/fix_qeq_comb_omp.cpp does not exist

src/pair_comb_omp.cpp does not exist

src/fix_qeq_comb_omp.h does not exist

src/pair_comb_omp.h does not exist

Installed YES: package USER-PHONON

Installed YES: package USER-QMMM

Installed YES: package USER-QTB

Installed YES: package USER-QUIP

Installed YES: package USER-REAXC

Installed YES: package USER-SMD

Installed YES: package USER-SMTBQ

Installed YES: package USER-SPH

Installed YES: package USER-TALLY

Installed YES: package USER-VTK

We’d need to see the contents of the new/modified .h file.: I send you the new files. Also, in Makefile.list I added the name of the new pair style.

Thank you for your time.

All the best,
José Ruiz-Franco.

pair_yukawa_kappa.cpp (10 KB)

pair_yukawa_kappa.h (1.78 KB)

your reported error message was:

ERROR: Unknown pair style yukawa_kappa (../force.cpp:246)
Last command: pair_style yukawa_kappa 2.0 4.0

which is correct, since in your new PairStyle macro invocation in the
.h file you have:

#ifdef PAIR_CLASS

PairStyle(yukawakappa,PairYukawaKappa)

#else

#ifndef LMP_PAIR_YUKAWA_KAPPA_H
#define LMP_PAIR_YUKAWA_KAPPA_H

so it *cannot* match.

a couple more comments:
- i for better consistency with other styles in LAMMPS, i would name
this class PairYukawaPoly and the style yukawa/poly
- you still have per atom type kappa parameters and don't derive them
from the radius, so you have not really gained that much convenience
and efficiency

for a truly polydisperse setup, you could assuming the global kappa
to be value for a particle radius of 1 length unit and kappa scaling
linearly with the radius property, then you could infer the kappa for
any given pair from kappa*sqrt(atom->radius[i]*atom->radius[j]), while
you are currently (pre-)computing kappa[itype][jtype] =
sqrt(kappa[itype][itype]*kappa[jtype][jtype]) requiring a different
type for each atom with a different radius and entering a suitable
kappa for those, too.

axel.

Qua trovi i files

There are no files here.

Please use English, this is an international mailing list.

Thanks, Axel.