22 #ifndef NGRandomNetBuilder_h 23 #define NGRandomNetBuilder_h
NGNodeList myOuterNodes
The list of outer nodes.
void findPossibleOuterNodes(NGNode *node)
finds possible connections between Node and OuterNodes complying with restrictions ...
void createNet(int numNodes)
Builds a NGNet using the set values.
double myMinLinkAngle
Minimum angle allowed between two links.
double myMinDistance
Minimum distance allowed between two nodes.
double myConnectivity
Probability of connecting to a existing node if possible.
std::list< NGEdge * > NGEdgeList
A list of edges (edge pointers)
bool checkAngles(NGNode *node)
Checks whether the angle of this node's connections are valid.
bool canConnect(NGNode *baseNode, NGNode *newNode)
Checks whether connecting the given two nodes complies with the set restrictions. ...
std::list< NGNode * > NGNodeList
A list of nodes (node pointers)
int myNumNodes
Number of nodes to be created.
The class storing the generated network.
NGRandomNetBuilder & operator=(const NGRandomNetBuilder &)
Invalidated assignment operator.
void removeOuterNode(NGNode *node)
Removes the given node from the list of outer nodes.
NGEdgeList myOuterLinks
The list of outer links.
NGRandomNetBuilder(NGNet &net, double minAngle, double minDistance, double maxDistance, double connectivity, int numTries, const RandomDistributor< int > &neighborDist)
Constructor.
double myMaxDistance
Maximum distance allowed between two nodes.
A class that builds random network using an algorithm by Markus Hartinger.
A netgen-representation of a node.
bool createNewNode(NGNode *baseNode)
Creates new random node.
int myNumTries
Number of tries to create a new node.
RandomDistributor< int > myNeighbourDistribution
The distribution of number of neighbours.
NGNet & myNet
The network to fill.