1 | /*
|
---|
2 | * Project: MoleCuilder
|
---|
3 | * Description: creates and alters molecular systems
|
---|
4 | * Copyright (C) 2010 University of Bonn. All rights reserved.
|
---|
5 | * Please see the LICENSE file or "Copyright notice" in builder.cpp for details.
|
---|
6 | */
|
---|
7 |
|
---|
8 | /**
|
---|
9 | * \file filling.dox
|
---|
10 | *
|
---|
11 | * Created on: Jan 16, 2012
|
---|
12 | * Author: heber
|
---|
13 | */
|
---|
14 |
|
---|
15 | /** \page filling Filling a domain
|
---|
16 | *
|
---|
17 | * The idea behind filling a domain is to cluster it with a set of nodes,
|
---|
18 | * i.e. a position in space in such a way that e.g. around node is sufficient
|
---|
19 | * space to fill in the desired molecule. The logic of generating the nodes
|
---|
20 | * is responsible to create them in such a way as to allow for dense (or
|
---|
21 | * whatever specific) filling is desired. However, we must not make it too
|
---|
22 | * complicated. The generation logic for these nodes should concentrate on
|
---|
23 | * filling the specific domain (sphere, ellipsoid, cuboid, pyramid, ...)
|
---|
24 | * in the best possible way.
|
---|
25 | * Whether each node can be filled is then to be decided by a predicate.
|
---|
26 | *
|
---|
27 | * The filling routine uses then both to traverse the given nodes and
|
---|
28 | * evaluate the predicate at each.
|
---|
29 | *
|
---|
30 | * Hence, the filling of a domain is abstracted into the following parts:
|
---|
31 | *
|
---|
32 | * -# \ref Mesh - node containers
|
---|
33 | * -# \ref FillPredicate - predicates
|
---|
34 | * -# \ref Filler - a filling routine which itself requires
|
---|
35 | * -# \ref Cluster - a set of atoms alone(!) inside a specific Shape
|
---|
36 | * -# \ref CopyAtomsInterface - copy Method for atoms used by Cluster::clone
|
---|
37 | * -# \ref Inserter - an insertion routine for the cloned cluster
|
---|
38 | *
|
---|
39 | * \section filling-node-generation Node generation
|
---|
40 | *
|
---|
41 | * The node generation is basically just a point or mesh generator that fills
|
---|
42 | * a specified region (best would be based on the class Shape) with a mesh in
|
---|
43 | * such a way as to fulfill certain criteria:
|
---|
44 | *
|
---|
45 | * -# equidistant
|
---|
46 | * -# containing certain primitive volumes (e.g. for fitting polymers)
|
---|
47 | * -# ...
|
---|
48 | *
|
---|
49 | * \section filling-predicate Predicates
|
---|
50 | *
|
---|
51 | * The Predicate pattern has already been used with Descriptors and Shapes.
|
---|
52 | * These are simply function objects that return a boolean value. I.e. they
|
---|
53 | * decide whether the current node in the mesh is vacant and can be filled or
|
---|
54 | * not. As with the predicate() function in the class Descriptor, these should
|
---|
55 | * be composable via logic operators such as || (or), && (and), ! (not), ...
|
---|
56 | *
|
---|
57 | * Note that each predicate receives on construction all the required
|
---|
58 | * information, e.g. LinkedCell_View or Tesselation references or objects, ...
|
---|
59 | *
|
---|
60 | * \section filling-filling-routine Filling routine
|
---|
61 | *
|
---|
62 | * The filling routine is then simply a function that goes through the given
|
---|
63 | * number of nodes (completely unaware of the geometry) and evaluates for each
|
---|
64 | * point the given predicates (which might be a composition of other predicates).
|
---|
65 | *
|
---|
66 | * It rejects all nodes that evaluate to false, the list of valid points is
|
---|
67 | * then traversed again and at each node a Cluster is created.
|
---|
68 | *
|
---|
69 | * Note that we rely on \ref Cluster's, objects containing a set of atomicId_t
|
---|
70 | * and that are inside a contained \ref Shape, to fill at each node. We use
|
---|
71 | * Cluster::clone() to create a copy that is subsequently placed at the desired
|
---|
72 | * node via an \ref Inserter functor. This allows to either simply shift the
|
---|
73 | * Cluster or even to perform some random translations and rotations on it, see
|
---|
74 | * the specific implementations of the class \ref Inserter.
|
---|
75 | *
|
---|
76 | *
|
---|
77 | * \date 2012-01-16
|
---|
78 | */
|
---|