diff --git a/doc/src/pair_gran.rst b/doc/src/pair_gran.rst index f83fd6d6ab..3249bae866 100644 --- a/doc/src/pair_gran.rst +++ b/doc/src/pair_gran.rst @@ -279,6 +279,11 @@ statistically similar results. This is because the forces they compute depend on atom velocities. See the :doc:`read_restart ` command for more details. +Accumulated values for individual contacts are saved to to restart +files but are not saved to data files. Therefore, forces may +differ significantly when a system is reloaded using A +:doc:`read_data ` command. + Related commands """""""""""""""" diff --git a/doc/src/pair_granular.rst b/doc/src/pair_granular.rst index 675c8fe4ff..5856db307b 100644 --- a/doc/src/pair_granular.rst +++ b/doc/src/pair_granular.rst @@ -780,6 +780,11 @@ statistically similar results. This is because the forces they compute depend on atom velocities. See the :doc:`read_restart ` command for more details. +Accumulated values for individual contacts are saved to to restart +files but are not saved to data files. Therefore, forces may +differ significantly when a system is reloaded using A +:doc:`read_data ` command. + Related commands """""""""""""""" diff --git a/src/GRANULAR/contact_tangential_models.cpp b/src/GRANULAR/contact_tangential_models.cpp index 1ac8c1c44c..d9bb3320b8 100644 --- a/src/GRANULAR/contact_tangential_models.cpp +++ b/src/GRANULAR/contact_tangential_models.cpp @@ -168,7 +168,7 @@ void TangentialLinearHistory::calculate_forces() TangentialLinearHistoryClassic::TangentialLinearHistoryClassic(LAMMPS *lmp) : TangentialLinearHistory(lmp) { - scale_area = 0; + scale_area = 0; // Sets gran/hooke/history behavior } /* ---------------------------------------------------------------------- */ @@ -233,7 +233,7 @@ void TangentialLinearHistoryClassic::calculate_forces() TangentialMindlinClassic::TangentialMindlinClassic(LAMMPS *lmp) : TangentialLinearHistoryClassic(lmp) { - scale_area = 1; + scale_area = 1; // Sets gran/hertz/history behavior } /* ---------------------------------------------------------------------- diff --git a/src/GRANULAR/contact_twisting_models.cpp b/src/GRANULAR/contact_twisting_models.cpp index 52b37d46e1..aca4f958e7 100644 --- a/src/GRANULAR/contact_twisting_models.cpp +++ b/src/GRANULAR/contact_twisting_models.cpp @@ -50,7 +50,6 @@ TwistingMarshall::TwistingMarshall(LAMMPS *lmp) : TwistingModel(lmp) void TwistingMarshall::init() { k_tang = contact->tangential_model->k; - damp_tang = contact->tangential_model->damp; mu_tang = contact->tangential_model->mu; } @@ -63,7 +62,7 @@ void TwistingMarshall::calculate_forces() // Calculate twist coefficients from tangential model & contact geometry // eq 32 of Marshall paper double k = 0.5 * k_tang * contact->area * contact->area; - double damp = 0.5 * damp_tang * contact->area * contact->area; + double damp = 0.5 * contact->tangential_model->damp * contact->area * contact->area; double mu = TWOTHIRDS * mu_tang * contact->area; if (contact->history_update) { diff --git a/src/GRANULAR/contact_twisting_models.h b/src/GRANULAR/contact_twisting_models.h index 724448892a..1fa5aa2c6a 100644 --- a/src/GRANULAR/contact_twisting_models.h +++ b/src/GRANULAR/contact_twisting_models.h @@ -44,7 +44,7 @@ class TwistingMarshall : public TwistingModel { void calculate_forces(); void init(); protected: - double k_tang, damp_tang, mu_tang; + double k_tang, mu_tang; }; /* ---------------------------------------------------------------------- */ diff --git a/src/GRANULAR/fix_wall_gran.cpp b/src/GRANULAR/fix_wall_gran.cpp index 05e060e61c..0d6fc587fb 100644 --- a/src/GRANULAR/fix_wall_gran.cpp +++ b/src/GRANULAR/fix_wall_gran.cpp @@ -83,8 +83,7 @@ FixWallGran::FixWallGran(LAMMPS *lmp, int narg, char **arg) : int iarg; if (classic_flag) { - iarg = 4; - iarg = model->init_classic_model(arg, iarg, narg); + iarg = model->init_classic_model(arg, 3, narg); if (iarg < narg) { if (strcmp(arg[iarg],"limit_damping") == 0) { diff --git a/src/GRANULAR/pair_granular.cpp b/src/GRANULAR/pair_granular.cpp index 9e512c78c0..1e423b92b3 100644 --- a/src/GRANULAR/pair_granular.cpp +++ b/src/GRANULAR/pair_granular.cpp @@ -354,7 +354,8 @@ void PairGranular::coeff(int narg, char **arg) while (iarg < narg) { - if (strcmp(arg[iarg++], "tangential") == 0) { + if (strcmp(arg[iarg], "tangential") == 0) { + iarg++; if (iarg >= narg) error->all(FLERR,"Illegal pair_coeff command, must specify " "tangential model after tangential keyword");