Commit 91a8df19 authored by Oliver Henrich's avatar Oliver Henrich
Browse files

Modified files according to request

parent def0cf8a
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -124,6 +124,8 @@ potentials are simultaneously introduced after the formation of the
new bond. Without a restriction on the permissible angle, and for
stiffer angle potentials very large energies can arise and lead to
uncontrolled behavior.
The *aconstrain* keyword is only available
when LAMMPS was built with the FixBondCreateAngle class.

Any bond that is created is assigned a bond type of *bondtype*.

@@ -255,9 +257,6 @@ This fix is part of the MC package. It is only enabled if LAMMPS was
built with that package.  See the :doc:`Build package <Build_package>`
doc page for more info.

The *aconstrain* keyword is only available
when LAMMPS was built with the FixBondCreateAngle class.

Related commands
""""""""""""""""

+5 −3
Original line number Diff line number Diff line
@@ -27,9 +27,11 @@
#include "random_mars.h"
#include "memory.h"
#include "error.h"
#include "math_const.h"

using namespace LAMMPS_NS;
using namespace FixConst;
using namespace MathConst;

#define BIG 1.0e20
#define DELTA 16
@@ -126,7 +128,7 @@ FixBondCreate::FixBondCreate(LAMMPS *lmp, int narg, char **arg) :
      if (itype < 0) error->all(FLERR,"Illegal fix bond/create command");
      iarg += 2;
    } else if (strcmp(arg[iarg],"aconstrain") == 0 &&
        strcmp(arg[2],"bond/create/angle") == 0) {
        strcmp(style,"bond/create/angle") == 0) {
      if (iarg+3 > narg) 
          error->all(FLERR,"Illegal fix bond/create/angle command");
      amin = force->numeric(FLERR,arg[iarg+1]);
@@ -137,8 +139,8 @@ FixBondCreate::FixBondCreate(LAMMPS *lmp, int narg, char **arg) :
        error->all(FLERR,"Illegal fix bond/create/angle command");
      if (amax < 0 || amax > 180)
        error->all(FLERR,"Illegal fix bond/create/angle command");
      amin = (3.14159265358979323846/180.0) * amin;
      amax = (3.14159265358979323846/180.0) * amax;
      amin = (MY_PI/180.0) * amin;
      amax = (MY_PI/180.0) * amax;
      constrainflag = 1;
      iarg += 3;
    } else error->all(FLERR,"Illegal fix bond/create command");
+2 −0
Original line number Diff line number Diff line
@@ -49,6 +49,8 @@ int FixBondCreateAngle::constrain(int i, int j, double amin, double amax)
  double v2y = 0.0;
  double v2z = 0.0;

  double angle1,angle2;

  int flag = 0;

  // pass if both atoms have no neighbors: bond is always formed
+0 −1
Original line number Diff line number Diff line
@@ -29,7 +29,6 @@ class FixBondCreateAngle : public FixBondCreate {
  FixBondCreateAngle(class LAMMPS *, int, char **);

 private:
  double angle1,angle2,amin,amax;
  int constrain(int, int, double, double);
};