EuclideanDistanceRandomConnections Class Reference

Implementation of a ConnectionIterator which generates connections which a connection probability which depends on the spatial distance between SimObject's. More...

#include <EuclideanDistanceRandomConnections.h>

Inheritance diagram for EuclideanDistanceRandomConnections:

Inheritance graph
[legend]
Collaboration diagram for EuclideanDistanceRandomConnections:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 EuclideanDistanceRandomConnections (const double C, const double lambda)
 New EuclideanDistanceRandomConnections with given parameters C and lambda.
 EuclideanDistanceRandomConnections (const double C, const double lambda, MPI::Intracomm const &mpiComm)
 New EuclideanDistanceRandomConnections with given parameters C and lambda and an additional MPI::Intracomm specification.
virtual ~EuclideanDistanceRandomConnections ()
virtual void init (const SimObjectPopulation &srcPopulation, const SimObjectPopulation &destPopulation)
 Tell the iterator about the populations to connect.
virtual void reset (SimObject::ID::SortedVector::const_iterator src_begin_it, SimObject::ID::SortedVector::const_iterator src_end_it, SimObject::ID::SortedVector::const_iterator dest_begin_it, SimObject::ID::SortedVector::const_iterator dest_end_it)
 Reset/Prepare the iterator to connect src to dst (specified by the begin and end iterators).
virtual bool next (pair< SimObject::ID, SimObject::ID > &connection)
 Move on to the next connection. If true is returned the connection pair is set properly.


Detailed Description

Implementation of a ConnectionIterator which generates connections which a connection probability which depends on the spatial distance between SimObject's.

Deprecated:
Use PredicateBasedConnections together with EuclidianDistanceConnectionPredicate.
The connection probability is C * exp( -|x-y|^2 / lambda^2 ) where |x-y| is the Euclidian distance between the SimObject's x and y.

Definition at line 24 of file EuclideanDistanceRandomConnections.h.


Constructor & Destructor Documentation

EuclideanDistanceRandomConnections::EuclideanDistanceRandomConnections ( const double  C,
const double  lambda 
)

New EuclideanDistanceRandomConnections with given parameters C and lambda.

Definition at line 19 of file EuclideanDistanceRandomConnections.cpp.

EuclideanDistanceRandomConnections::EuclideanDistanceRandomConnections ( const double  C,
const double  lambda,
MPI::Intracomm const &  mpiComm 
)

New EuclideanDistanceRandomConnections with given parameters C and lambda and an additional MPI::Intracomm specification.

Definition at line 25 of file EuclideanDistanceRandomConnections.cpp.

virtual EuclideanDistanceRandomConnections::~EuclideanDistanceRandomConnections (  )  [inline, virtual]

Definition at line 34 of file EuclideanDistanceRandomConnections.h.


Member Function Documentation

void EuclideanDistanceRandomConnections::init ( const SimObjectPopulation src,
const SimObjectPopulation dst 
) [virtual]

Tell the iterator about the populations to connect.

Implements ConnectionIterator.

Definition at line 30 of file EuclideanDistanceRandomConnections.cpp.

void EuclideanDistanceRandomConnections::reset ( SimObject::ID::SortedVector::const_iterator  src_begin,
SimObject::ID::SortedVector::const_iterator  src_end,
SimObject::ID::SortedVector::const_iterator  dst_begin,
SimObject::ID::SortedVector::const_iterator  dst_end 
) [virtual]

Reset/Prepare the iterator to connect src to dst (specified by the begin and end iterators).

Implements ConnectionIterator.

Definition at line 38 of file EuclideanDistanceRandomConnections.cpp.

bool EuclideanDistanceRandomConnections::next ( pair< SimObject::ID, SimObject::ID > &  connection  )  [virtual]

Move on to the next connection. If true is returned the connection pair is set properly.

Implements ConnectionIterator.

Definition at line 55 of file EuclideanDistanceRandomConnections.cpp.

References SpatialSimObjectPopulation::getLocation(), ConnectionIterator::last_conn_idx, ConnectionIterator::last_conn_valid, ConnectionIterator::m_rnd_eng, and sqr_distance().

Here is the call graph for this function:


The documentation for this class was generated from the following files:

Generated on Wed Jul 9 16:34:50 2008 for PCSIM by  doxygen 1.5.5