18#ifndef VOTCA_CSG_NBLIST_3BODY_H
19#define VOTCA_CSG_NBLIST_3BODY_H
50 bool do_exclusions =
true);
55 bool do_exclusions =
true) {
56 Generate(list1, list2, list2, do_exclusions);
61 Generate(list, list, list, do_exclusions);
87 T *
object,
bool (T::*fkt)(
Bead *,
Bead *,
Bead *,
const Eigen::Vector3d &,
88 const Eigen::Vector3d &,
89 const Eigen::Vector3d &,
const double dist12,
90 const double dist13,
const double dist23));
94 Bead *,
Bead *,
Bead *,
const Eigen::Vector3d &,
const Eigen::Vector3d &,
95 const Eigen::Vector3d &,
const double dist12,
const double dist13,
96 const double dist23));
100 const Eigen::Vector3d &,
const Eigen::Vector3d &,
101 const double,
const double,
const double) {
106 template <
typename triple_type>
116 template <
typename triple_type>
119 const Eigen::Vector3d &r12,
120 const Eigen::Vector3d &r13,
121 const Eigen::Vector3d &r23) {
123 new triple_type(bead1, bead2, bead3, r12, r13, r23));
127 const Eigen::Vector3d &,
128 const Eigen::Vector3d &,
129 const Eigen::Vector3d &);
140 const Eigen::Vector3d &,
const Eigen::Vector3d &,
141 const double dist12,
const double dist13,
142 const double dist23) = 0;
147 template <
typename T>
151 const Eigen::Vector3d &,
const Eigen::Vector3d &,
152 const double,
const double,
const double);
157 const Eigen::Vector3d &r13,
const Eigen::Vector3d &r23,
158 const double dist12,
const double dist13,
159 const double dist23)
override {
160 return (
cls_->*
fkt_)(b1, b2, b3, r12, r13, r23, dist12, dist13, dist23);
172 const Eigen::Vector3d &,
const Eigen::Vector3d &,
173 const double,
const double,
const double);
177 const Eigen::Vector3d &r13,
const Eigen::Vector3d &r23,
178 const double dist12,
const double dist13,
179 const double dist23)
override {
180 return (*
fkt_)(b1, b2, b3, r12, r13, r23, dist12, dist13, dist23);
190template <
typename triple_type>
197 T *
object,
bool (T::*fkt)(
Bead *,
Bead *,
Bead *,
const Eigen::Vector3d &,
198 const Eigen::Vector3d &,
const Eigen::Vector3d &,
199 const double dist12,
const double dist13,
200 const double dist23)) {
206 Bead *,
Bead *,
Bead *,
const Eigen::Vector3d &,
const Eigen::Vector3d &,
207 const Eigen::Vector3d &,
const double dist12,
const double dist13,
208 const double dist23)) {
Functor for member functions.
bool operator()(Bead *b1, Bead *b2, Bead *b3, const Eigen::Vector3d &r12, const Eigen::Vector3d &r13, const Eigen::Vector3d &r23, const double dist12, const double dist13, const double dist23) override
bool(T::*)(Bead *, Bead *, Bead *, const Eigen::Vector3d &, const Eigen::Vector3d &, const Eigen::Vector3d &, const double, const double, const double) fkt_t
FunctorMember(T *cls, fkt_t fkt)
Functor for non-member functions.
FunctorNonMember(fkt_t fkt)
bool operator()(Bead *b1, Bead *b2, Bead *b3, const Eigen::Vector3d &r12, const Eigen::Vector3d &r13, const Eigen::Vector3d &r23, const double dist12, const double dist13, const double dist23) override
bool(*)(Bead *, Bead *, Bead *, const Eigen::Vector3d &, const Eigen::Vector3d &, const Eigen::Vector3d &, const double, const double, const double) fkt_t
virtual ~Functor()=default
virtual bool operator()(Bead *, Bead *, Bead *, const Eigen::Vector3d &, const Eigen::Vector3d &, const Eigen::Vector3d &, const double dist12, const double dist13, const double dist23)=0
Neighbour list class for 3 body interactions.
void setCutoff(const double cutoff)
double getCutoff()
get the cutoff for the neighbour search
virtual void Generate(BeadList &list, bool do_exclusions=true)
bool do_exclusions_
take into account exclusions from topolgoy
static bool match_always(Bead *, Bead *, Bead *, const Eigen::Vector3d &, const Eigen::Vector3d &, const Eigen::Vector3d &, const double, const double, const double)
standard match function
void SetMatchFunction(T *object, bool(T::*fkt)(Bead *, Bead *, Bead *, const Eigen::Vector3d &, const Eigen::Vector3d &, const Eigen::Vector3d &, const double dist12, const double dist13, const double dist23))
match function for class member functions
static BeadTriple * beadtriple_create_policy(Bead *bead1, Bead *bead2, Bead *bead3, const Eigen::Vector3d &r12, const Eigen::Vector3d &r13, const Eigen::Vector3d &r23)
policy function to create new bead types
triple_creator_t triple_creator_
the current bead pair creator function
std::unique_ptr< Functor > match_function_
virtual void Generate(BeadList &list1, BeadList &list2, bool do_exclusions=true)
BeadTriple *(*)(Bead *, Bead *, Bead *, const Eigen::Vector3d &, const Eigen::Vector3d &, const Eigen::Vector3d &) triple_creator_t
virtual void Generate(BeadList &list1, BeadList &list2, BeadList &list3, bool do_exclusions=true)
void setTripleType()
function to use a user defined triple type
double cutoff_
cutoff (at the moment use only one cutoff value)
base class for all analysis tools