Chaste  Build::
VesselNode< DIM > Class Template Reference

#include <VesselNode.hpp>

+ Inheritance diagram for VesselNode< DIM >:
+ Collaboration diagram for VesselNode< DIM >:

Public Member Functions

 VesselNode (double v1, double v2, double v3, units::quantity< unit::length > referenceLength)
 
 VesselNode (double v1=0.0, double v2=0.0, double v3=0.0)
 
 VesselNode (const DimensionalChastePoint< DIM > &location)
 
 VesselNode (const VesselNode< DIM > &rExistingNode)
 
 ~VesselNode ()
 
unsigned GetComparisonId ()
 
units::quantity< unit::length > GetDistance (const DimensionalChastePoint< DIM > &rLocation) const
 
boost::shared_ptr< NodeFlowProperties< DIM > > GetFlowProperties () const
 
const DimensionalChastePoint< DIM > & rGetLocation () const
 
unsigned GetNumberOfSegments () const
 
std::map< std::string, double > GetOutputData ()
 
units::quantity< unit::length > GetReferenceLengthScale () const
 
boost::shared_ptr< VesselSegment< DIM > > GetSegment (unsigned index) const
 
std::vector< boost::shared_ptr< VesselSegment< DIM > > > GetSegments () const
 
bool IsAttachedTo (const boost::shared_ptr< VesselSegment< DIM > > pSegment) const
 
bool IsCoincident (const DimensionalChastePoint< DIM > &rLocation) const
 
bool IsMigrating () const
 
void SetComparisonId (unsigned id)
 
void SetFlowProperties (const NodeFlowProperties< DIM > &rFlowProperties)
 
void SetIsMigrating (bool isMigrating)
 
void SetLocation (const DimensionalChastePoint< DIM > &rLocation)
 
void SetLocation (double x, double y, double z=0.0, units::quantity< unit::length > referenceLength=1.e-6 *unit::metres)
 
void SetReferenceLengthScale (units::quantity< unit::length > lenthScale)
 
- Public Member Functions inherited from AbstractVesselNetworkComponent< DIM >
 AbstractVesselNetworkComponent ()
 
virtual ~AbstractVesselNetworkComponent ()
 
virtual unsigned GetId () const
 
virtual double GetOutputDataValue (const std::string &rKey)
 
virtual std::vector< std::string > GetOutputDataKeys ()
 
virtual units::quantity< unit::length > GetRadius () const
 
virtual void SetId (unsigned id)
 
virtual void SetOutputData (const std::string &rKey, double value)
 
virtual void SetRadius (units::quantity< unit::length > radius)
 

Static Public Member Functions

static boost::shared_ptr< VesselNode< DIM > > Create (double v1=0.0, double v2=0.0, double v3=0.0)
 
static boost::shared_ptr< VesselNode< DIM > > Create (double v1, double v2, double v3, units::quantity< unit::length > referenceLength)
 
static boost::shared_ptr< VesselNode< DIM > > Create (const DimensionalChastePoint< DIM > &location)
 
static boost::shared_ptr< VesselNode< DIM > > Create (const VesselNode< DIM > &rExistingNode)
 
static boost::shared_ptr< VesselNode< DIM > > Create (boost::shared_ptr< VesselNode< DIM > > pExistingNode)
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 
void AddSegment (boost::shared_ptr< VesselSegment< DIM > > pVesselSegment)
 
void RemoveSegment (boost::shared_ptr< VesselSegment< DIM > > pVesselSegment)
 

Private Attributes

DimensionalChastePoint< DIM > mLocation
 
std::vector< boost::weak_ptr< VesselSegment< DIM > > > mSegments
 
bool mIsMigrating
 
boost::shared_ptr< NodeFlowProperties< DIM > > mpFlowProperties
 
unsigned mPtrComparisonId
 

Friends

class boost::serialization::access
 
class VesselSegment< DIM >
 

Additional Inherited Members

- Protected Attributes inherited from AbstractVesselNetworkComponent< DIM >
std::map< std::string, double > mOutputData
 
unsigned mId
 
units::quantity< unit::length > mRadius
 

Detailed Description

template<unsigned DIM>
class VesselNode< DIM >

This is a class for vessel nodes, which are vessel network components.

Nodes are point locations along a vessel. They are used for describing the end positions of straight line vessel segments.

Definition at line 65 of file VesselNode.hpp.

Constructor & Destructor Documentation

template<unsigned DIM>
VesselNode< DIM >::VesselNode ( double  v1,
double  v2,
double  v3,
units::quantity< unit::length >  referenceLength 
)

Constructor. Create a node using xyz coordinates

Parameters
v1the node's x-coordinate
v2the node's y-coordinate
v3the node's z-coordinate
referenceLengththe reference length scale, defaults to micron

Definition at line 41 of file VesselNode.cpp.

References VesselNode< DIM >::mpFlowProperties.

template<unsigned DIM>
VesselNode< DIM >::VesselNode ( double  v1 = 0.0,
double  v2 = 0.0,
double  v3 = 0.0 
)

Constructor. Create a node using xyz coordinates

Parameters
v1the node's x-coordinate (defaults to 0)
v2the node's y-coordinate (defaults to 0)
v3the node's z-coordinate (defaults to 0)

Definition at line 52 of file VesselNode.cpp.

References VesselNode< DIM >::mpFlowProperties.

template<unsigned DIM>
VesselNode< DIM >::VesselNode ( const DimensionalChastePoint< DIM > &  location)

Constructor. Create a node using ublas c_vector

Parameters
locationthe node's location (defaults to 0.0)

Definition at line 63 of file VesselNode.cpp.

References VesselNode< DIM >::mpFlowProperties.

template<unsigned DIM>
VesselNode< DIM >::VesselNode ( const VesselNode< DIM > &  rExistingNode)

Copy constructor.

Parameters
rExistingNodethe node to copy from

Definition at line 74 of file VesselNode.cpp.

References VesselNode< DIM >::GetFlowProperties(), VesselNode< DIM >::IsMigrating(), VesselNode< DIM >::mIsMigrating, and VesselNode< DIM >::SetFlowProperties().

template<unsigned DIM>
VesselNode< DIM >::~VesselNode ( )

Destructor

Definition at line 88 of file VesselNode.cpp.

Member Function Documentation

template<unsigned DIM>
void VesselNode< DIM >::AddSegment ( boost::shared_ptr< VesselSegment< DIM > >  pVesselSegment)
private

Add a vessel segment the node. Private because node-segment connectivity needs to be managed.

Parameters
pVesselSegmentthe segment to be added

Definition at line 132 of file VesselNode.cpp.

References VesselNode< DIM >::mSegments.

template<unsigned DIM>
boost::shared_ptr< VesselNode< DIM > > VesselNode< DIM >::Create ( double  v1 = 0.0,
double  v2 = 0.0,
double  v3 = 0.0 
)
static

Construct a new instance of the class and return a shared pointer to it.

Parameters
v1the node's x-coordinate (defaults to 0 micron)
v2the node's y-coordinate (defaults to 0 micron)
v3the node's z-coordinate (defaults to 0 micron)
Returns
a pointer to the newly created node

Definition at line 100 of file VesselNode.cpp.

Referenced by Vessel< DIM >::DivideSegment(), AngiogenesisSolver< DIM >::DoAnastamosis(), VesselNetwork< DIM >::FormSprout(), and AngiogenesisSolver< DIM >::UpdateNodalPositions().

template<unsigned DIM>
boost::shared_ptr< VesselNode< DIM > > VesselNode< DIM >::Create ( double  v1,
double  v2,
double  v3,
units::quantity< unit::length >  referenceLength 
)
static

Construct a new instance of the class and return a shared pointer to it.

Parameters
v1the node's x-coordinate (defaults to 0 micron)
v2the node's y-coordinate (defaults to 0 micron)
v3the node's z-coordinate (defaults to 0 micron)
referenceLengththe reference length scale
Returns
a pointer to the newly created node

Definition at line 93 of file VesselNode.cpp.

template<unsigned DIM>
boost::shared_ptr< VesselNode< DIM > > VesselNode< DIM >::Create ( const DimensionalChastePoint< DIM > &  location)
static

Construct a new instance of the class and return a shared pointer to it.

Parameters
locationthe node's location (defaults to 0.0 micron)
Returns
a pointer to the newly created node

Definition at line 107 of file VesselNode.cpp.

template<unsigned DIM>
boost::shared_ptr< VesselNode< DIM > > VesselNode< DIM >::Create ( const VesselNode< DIM > &  rExistingNode)
static

Construct a new instance of the class and return a shared pointer to it.

Parameters
rExistingNodethe node to copy from
Returns
a pointer to the newly created node

Definition at line 114 of file VesselNode.cpp.

template<unsigned DIM>
boost::shared_ptr< VesselNode< DIM > > VesselNode< DIM >::Create ( boost::shared_ptr< VesselNode< DIM > >  pExistingNode)
static

Construct a new instance of the class and return a shared pointer to it.

Parameters
pExistingNodethe node to copy from
Returns
a pointer to the newly created node

Definition at line 121 of file VesselNode.cpp.

template<unsigned DIM>
unsigned VesselNode< DIM >::GetComparisonId ( )

Return the Id for comparing pointer contents

Returns
the node id

Definition at line 147 of file VesselNode.cpp.

References VesselNode< DIM >::mPtrComparisonId.

template<unsigned DIM>
units::quantity< unit::length > VesselNode< DIM >::GetDistance ( const DimensionalChastePoint< DIM > &  rLocation) const

Return the distance between the input location and the node

Parameters
rLocationthe location to calculate the distance to
Returns
the distance to the location

Definition at line 153 of file VesselNode.cpp.

References VesselNode< DIM >::mLocation.

template<unsigned DIM>
boost::shared_ptr< NodeFlowProperties< DIM > > VesselNode< DIM >::GetFlowProperties ( ) const

Return the flow properties of the component

Returns
the flow properties of the component

Definition at line 159 of file VesselNode.cpp.

References VesselNode< DIM >::mpFlowProperties.

Referenced by VesselNode< DIM >::VesselNode().

template<unsigned DIM>
unsigned VesselNode< DIM >::GetNumberOfSegments ( ) const

Return the number of attached segments

Returns
the number of segments attached to the node

Definition at line 171 of file VesselNode.cpp.

References VesselNode< DIM >::mSegments.

template<unsigned DIM>
std::map< std::string, double > VesselNode< DIM >::GetOutputData ( )
virtual
template<unsigned DIM>
units::quantity< unit::length > VesselNode< DIM >::GetReferenceLengthScale ( ) const

Return the reference length scale for the node, default is micron

Returns
a ublas c_vector at the location of the node

Definition at line 189 of file VesselNode.cpp.

References VesselNode< DIM >::mLocation.

template<unsigned DIM>
boost::shared_ptr< VesselSegment< DIM > > VesselNode< DIM >::GetSegment ( unsigned  index) const

Return a pointer to the indexed vessel segment

Parameters
indexthe segment index
Returns
a vector of pointers to the attached vessel segments

Definition at line 195 of file VesselNode.cpp.

References VesselNode< DIM >::mSegments.

template<unsigned DIM>
std::vector< boost::shared_ptr< VesselSegment< DIM > > > VesselNode< DIM >::GetSegments ( ) const

Return a vector of pointers to the attached vessel segments.

Returns
a vector of pointers to the attached vessel segments

Definition at line 209 of file VesselNode.cpp.

References VesselNode< DIM >::mSegments.

template<unsigned DIM>
bool VesselNode< DIM >::IsAttachedTo ( const boost::shared_ptr< VesselSegment< DIM > >  pSegment) const

Return true if the input segment is attached to the node

Parameters
pSegmenta pointer to the segment to query
Returns
whether the input segment is attached to the node

Definition at line 221 of file VesselNode.cpp.

template<unsigned DIM>
bool VesselNode< DIM >::IsCoincident ( const DimensionalChastePoint< DIM > &  rLocation) const

Return true if the node is coincident with the input location

Parameters
rLocationthe query location
Returns
whether then node is coincident with the input location

Definition at line 228 of file VesselNode.cpp.

References VesselNode< DIM >::mLocation.

template<unsigned DIM>
bool VesselNode< DIM >::IsMigrating ( ) const

Has the node been designated as migrating. This is useful for keeping track of nodes in angiogenesis simulations.

Returns
whether the node is marked as migrating.

Definition at line 234 of file VesselNode.cpp.

References VesselNode< DIM >::mIsMigrating.

Referenced by VesselNode< DIM >::GetOutputData(), and VesselNode< DIM >::VesselNode().

template<unsigned DIM>
void VesselNode< DIM >::RemoveSegment ( boost::shared_ptr< VesselSegment< DIM > >  pVesselSegment)
private

Remove a vessel segment from the node. Private because node-segment connectivity needs to be managed.

Parameters
pVesselSegmentthe segment to be removed

Definition at line 240 of file VesselNode.cpp.

References VesselNode< DIM >::mSegments.

template<unsigned DIM>
const DimensionalChastePoint< DIM > & VesselNode< DIM >::rGetLocation ( ) const

Return a reference to the location of the node, default is micron

Returns
a ublas c_vector at the location of the node

Definition at line 165 of file VesselNode.cpp.

References VesselNode< DIM >::mLocation.

template<unsigned DIM>
template<class Archive >
void VesselNode< DIM >::serialize ( Archive &  ar,
const unsigned int  version 
)
inlineprivate

Do the serialize

Parameters
arthe archive
versionthe archive version number

Definition at line 81 of file VesselNode.hpp.

References VesselNode< DIM >::mIsMigrating, VesselNode< DIM >::mLocation, VesselNode< DIM >::mpFlowProperties, and VesselNode< DIM >::mPtrComparisonId.

template<unsigned DIM>
void VesselNode< DIM >::SetComparisonId ( unsigned  id)

Set the id used for comparing the contents of pointers. This is only used by certain methods in the VesselNetwork class. Use SetId for generic node labelling.

Parameters
idfor node comparison

Definition at line 254 of file VesselNode.cpp.

References VesselNode< DIM >::mPtrComparisonId.

template<unsigned DIM>
void VesselNode< DIM >::SetFlowProperties ( const NodeFlowProperties< DIM > &  rFlowProperties)

Set the flow properties of the node

Parameters
rFlowPropertiesthe flow properties to be set

Definition at line 260 of file VesselNode.cpp.

References VesselNode< DIM >::mpFlowProperties.

Referenced by VesselNode< DIM >::VesselNode().

template<unsigned DIM>
void VesselNode< DIM >::SetIsMigrating ( bool  isMigrating)

Set that the node is migrating

Parameters
isMigratingwhether the node is migrating

Definition at line 278 of file VesselNode.cpp.

References VesselNode< DIM >::mIsMigrating.

template<unsigned DIM>
void VesselNode< DIM >::SetLocation ( const DimensionalChastePoint< DIM > &  rLocation)

Set the location of the node. It is assumed that this location is consistent with the nodes reference length scale, default is micron.

Parameters
rLocationa ublas c_vector specifying the location

Definition at line 266 of file VesselNode.cpp.

References VesselNode< DIM >::mLocation.

template<unsigned DIM>
void VesselNode< DIM >::SetLocation ( double  x,
double  y,
double  z = 0.0,
units::quantity< unit::length >  referenceLength = 1.e-6*unit::metres 
)

Set the location of the node. It is assumed that this location is consistent with the nodes reference length scale, default is micron.

Parameters
xthe x location
ythe y location
zthe z location
referenceLengththe reference length scale

Definition at line 272 of file VesselNode.cpp.

References VesselNode< DIM >::mLocation.

template<unsigned DIM>
void VesselNode< DIM >::SetReferenceLengthScale ( units::quantity< unit::length >  lenthScale)

Set the length scale used to dimensionalize the node location as stored in mLocation. If you want locations to be in metres, for example, set it to unit::metres. The node location values are changed accordingly when this value is changed.

Parameters
lenthScalethe reference length scale for node locations

Definition at line 284 of file VesselNode.cpp.

References VesselNode< DIM >::mLocation.

Friends And Related Function Documentation

template<unsigned DIM>
friend class boost::serialization::access
friend

Archiving. Note that mSegments is not serialized here. Segments should add or remove themselves from nodes when serializing/de-serializing. It is not managed by nodes.

Definition at line 73 of file VesselNode.hpp.

template<unsigned DIM>
friend class VesselSegment< DIM >
friend

Allow segments to manage adding and removing themselves from nodes.

Definition at line 93 of file VesselNode.hpp.

Member Data Documentation

template<unsigned DIM>
bool VesselNode< DIM >::mIsMigrating
private

Is the vessel allowed to extend at this node

Definition at line 108 of file VesselNode.hpp.

Referenced by VesselNode< DIM >::IsMigrating(), VesselNode< DIM >::serialize(), VesselNode< DIM >::SetIsMigrating(), and VesselNode< DIM >::VesselNode().

template<unsigned DIM>
boost::shared_ptr<NodeFlowProperties<DIM> > VesselNode< DIM >::mpFlowProperties
private
template<unsigned DIM>
unsigned VesselNode< DIM >::mPtrComparisonId
private

This is used for comparing nodes in some VesselNetwork methods. It should not be used otherwise.

Definition at line 119 of file VesselNode.hpp.

Referenced by VesselNode< DIM >::GetComparisonId(), VesselNode< DIM >::serialize(), and VesselNode< DIM >::SetComparisonId().

template<unsigned DIM>
std::vector<boost::weak_ptr<VesselSegment<DIM> > > VesselNode< DIM >::mSegments
private

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