1 #ifndef OPENMPCD_PAIRPOTENTIALS_FENE_HPP
2 #define OPENMPCD_PAIRPOTENTIALS_FENE_HPP
4 #include <OpenMPCD/PairPotentials/Base.hpp>
8 namespace PairPotentials
17 template<
typename T = FP>
28 FENE(
const T K,
const T l_0,
const T R)
53 ( 1 - ( (abs_r - l0) * ( abs_r - l0 ) ) / ( R * R ) )
66 return -0.5*K*R*R*log( 1 - tmp );
104 #endif //OPENMPCD_PAIRPOTENTIALS_FENE_HPP
#define OPENMPCD_CUDA_HOST_AND_DEVICE
Denotes a function to be callable both from the Host and from a CUDA Device.
OPENMPCD_CUDA_HOST_AND_DEVICE FENE(const T K, const T l_0, const T R)
The constructor.
OPENMPCD_CUDA_HOST_AND_DEVICE T getK() const
Returns the parameter.
const OPENMPCD_CUDA_HOST_AND_DEVICE Vector3D getNormalized() const
Returns this vector, but normalized.
OPENMPCD_CUDA_HOST_AND_DEVICE Vector3D< T > force(const Vector3D< T > &Rvec) const
Returns the force vector of the interaction for a given position vector.
OPENMPCD_CUDA_HOST_AND_DEVICE T potential(const Vector3D< T > &Rvec) const
Returns the potential of the interaction for a given position vector.
Abstract base class for pair potentials.
OPENMPCD_CUDA_HOST_AND_DEVICE T get_l_0() const
Returns the parameter.
OPENMPCD_CUDA_HOST_AND_DEVICE RealType getMagnitude() const
Returns the magnitude of this vector.
OPENMPCD_CUDA_HOST_AND_DEVICE T getR() const
Returns the parameter.