IPotential, IPotentialAtomic, Potential2Soft, Potential2Spherical, PotentialHard, PotentialSoftpublic class P2Ideal extends Potential2 implements Potential2Soft, Potential2Spherical, PotentialHard
Useful as a placeholder where a potential is expected but it is desired to not have the atoms interact.
| Modifier and Type | Field | Description |
|---|---|---|
protected double |
range |
| Modifier and Type | Method | Description |
|---|---|---|
void |
bump(IAtomList atom,
double falseTime) |
Does nothing.
|
double |
collisionTime(IAtomList atom,
double falseTime) |
Returns Double.POSITIVE_INFINITY.
|
double |
du(double r2) |
Returns zero.
|
double |
energy(IAtomList atoms) |
Returns zero.
|
double |
energyChange() |
Returns zero.
|
double |
getRange() |
Returns zero.
|
Vector[] |
gradient(IAtomList atoms) |
Returns a zero vector.
|
Vector[] |
gradient(IAtomList atoms,
Tensor pressureTensor) |
Returns the same gradient as gradient(AtomSet) and also adds in the
contribution of the AtomSet to the pressureTensor.
|
double |
hyperVirial(IAtomList pair) |
Returns zero.
|
double |
integral(double rC) |
Returns zero.
|
double |
lastCollisionVirial() |
Returns zero.
|
Tensor |
lastCollisionVirialTensor() |
Returns a tensor of zeros.
|
void |
setBox(Box box) |
Does nothing.
|
void |
setRange(double range) |
|
double |
u(double r2) |
Returns zero.
|
double |
virial(IAtomList pair) |
Returns zero.
|
nBodypublic P2Ideal(Space space)
public void setBox(Box box)
setBox in interface IPotentialsetBox in class Potentialpublic void setRange(double range)
public double getRange()
getRange in interface IPotentialgetRange in class Potentialpublic double energy(IAtomList atoms)
energy in interface IPotentialAtomicenergy in class Potentialpublic double hyperVirial(IAtomList pair)
hyperVirial in interface Potential2Softpublic double virial(IAtomList pair)
virial in interface PotentialSoftpublic double integral(double rC)
integral in interface Potential2Softpublic double u(double r2)
u in interface Potential2Sphericalr2 - the square of the distance between the particles.public double du(double r2)
du in interface Potential2Softpublic double lastCollisionVirial()
lastCollisionVirial in interface PotentialHardpublic Tensor lastCollisionVirialTensor()
lastCollisionVirialTensor in interface PotentialHardpublic void bump(IAtomList atom, double falseTime)
bump in interface PotentialHardpublic double collisionTime(IAtomList atom, double falseTime)
collisionTime in interface PotentialHardpublic double energyChange()
energyChange in interface PotentialHardpublic Vector[] gradient(IAtomList atoms)
gradient in interface PotentialSoftpublic Vector[] gradient(IAtomList atoms, Tensor pressureTensor)
PotentialSoftgradient in interface PotentialSoft