make biga0 and r0 accessible via Pair::extract() and add pair style to table in fix adapt

This commit is contained in:
Axel Kohlmeyer
2023-02-28 21:49:31 -05:00
parent 02c26f4b87
commit 11172c1949
4 changed files with 7 additions and 1 deletions

View File

@ -133,6 +133,8 @@ formulas for the meaning of these parameters:
+------------------------------------------------------------------------------+--------------------------------------------------+-------------+
| :doc:`born/coul/long, born/coul/msm <pair_born>` | coulombic_cutoff | type global |
+------------------------------------------------------------------------------+--------------------------------------------------+-------------+
| :doc:`born/gauss <pair_born_gauss>` | biga0,biga1,r0 | type pairs |
+------------------------------------------------------------------------------+--------------------------------------------------+-------------+
| :doc:`buck, buck/coul/cut <pair_buck>` | a,c | type pairs |
+------------------------------------------------------------------------------+--------------------------------------------------+-------------+
| :doc:`buck/coul/long, buck/coul/msm <pair_buck>` | a,c,coulombic_cutoff | type pairs |

View File

@ -363,6 +363,8 @@ double PairBornGauss::single(int /*i*/, int /*j*/, int itype, int jtype, double
void *PairBornGauss::extract(const char *str, int &dim)
{
dim = 2;
if (strcmp(str, "biga0") == 0) return (void *) biga0;
if (strcmp(str, "biga1") == 0) return (void *) biga1;
if (strcmp(str, "r0") == 0) return (void *) r0;
return nullptr;
}

View File

@ -44,7 +44,7 @@ class PairBornGauss : public Pair {
void *extract(const char *, int &) override;
protected:
double cut_global, temperature;
double cut_global;
double **cut;
double **biga0, **alpha, **biga1, **beta, **r0;
double **offset;

View File

@ -12,7 +12,9 @@ pair_style: born/gauss 8.0
pair_coeff: ! |
* * 8.2464e13 12.48 0.042644277 0.44 3.56
extract: ! |
biga0 2
biga1 2
r0 2
natoms: 32
init_vdwl: 2834.5490463003366
init_coul: 0