Chaste  Release::2017.1
Node< SPACE_DIM > Class Template Reference

#include <Node.hpp>

+ Collaboration diagram for Node< SPACE_DIM >:

Classes

class  ContainingBoundaryElementIterator
 
class  ContainingElementIterator
 

Public Member Functions

 Node (unsigned index, ChastePoint< SPACE_DIM > point, bool isBoundaryNode=false)
 
 Node (unsigned index, std::vector< double > coords, bool isBoundaryNode=false)
 
 Node (unsigned index, c_vector< double, SPACE_DIM > location, bool isBoundaryNode=false)
 
 Node (unsigned index, bool isBoundaryNode=false, double v1=0, double v2=0, double v3=0)
 
 Node (unsigned index, double *location, bool isBoundaryNode=false)
 
 ~Node ()
 
void SetPoint (ChastePoint< SPACE_DIM > point)
 
void SetIndex (unsigned index)
 
void AddNodeAttribute (double attribute)
 
void SetAsBoundaryNode (bool value=true)
 
ChastePoint< SPACE_DIM > GetPoint () const
 
const c_vector< double, SPACE_DIM > & rGetLocation () const
 
c_vector< double, SPACE_DIM > & rGetModifiableLocation ()
 
unsigned GetIndex () const
 
bool IsBoundaryNode () const
 
void AddElement (unsigned index)
 
void RemoveElement (unsigned index)
 
void RemoveBoundaryElement (unsigned index)
 
void AddBoundaryElement (unsigned index)
 
void AddNeighbour (unsigned index)
 
void ClearNeighbours ()
 
void RemoveDuplicateNeighbours ()
 
bool NeighboursIsEmpty ()
 
void SetNeighboursSetUp (bool flag)
 
bool GetNeighboursSetUp ()
 
std::vector< unsigned > & rGetNeighbours ()
 
std::set< unsigned > & rGetContainingElementIndices ()
 
std::vector< double > & rGetNodeAttributes ()
 
unsigned GetNumNodeAttributes ()
 
bool HasNodeAttributes ()
 
std::set< unsigned > & rGetContainingBoundaryElementIndices ()
 
unsigned GetNumContainingElements () const
 
unsigned GetNumBoundaryElements () const
 
c_vector< double, SPACE_DIM > & rGetAppliedForce ()
 
void ClearAppliedForce ()
 
void AddAppliedForceContribution (const c_vector< double, SPACE_DIM > &rForceContribution)
 
bool IsParticle ()
 
void SetIsParticle (bool isParticle)
 
double GetRadius ()
 
void SetRadius (double radius)
 
void MarkAsDeleted ()
 
bool IsDeleted () const
 
void MarkAsInternal ()
 
bool IsInternal () const
 
void SetRegion (unsigned region)
 
unsigned GetRegion () const
 
ContainingElementIterator ContainingElementsBegin () const
 
ContainingElementIterator ContainingElementsEnd () const
 
ContainingBoundaryElementIterator ContainingBoundaryElementsBegin () const
 
ContainingBoundaryElementIterator ContainingBoundaryElementsEnd () const
 

Private Member Functions

template<class Archive >
void serialize (Archive &archive, const unsigned int version)
 
void CommonConstructor (unsigned index, bool isBoundaryNode)
 
void ConstructNodeAttributes ()
 
void CheckForNodeAttributes () const
 

Private Attributes

unsigned mIndex
 
c_vector< double, SPACE_DIM > mLocation
 
NodeAttributes< SPACE_DIM > * mpNodeAttributes
 
bool mIsBoundaryNode
 
bool mIsInternal
 
bool mIsDeleted
 
std::set< unsignedmElementIndices
 
std::set< unsignedmBoundaryElementIndices
 

Friends

class boost::serialization::access
 
class TestNode
 

Detailed Description

template<unsigned SPACE_DIM>
class Node< SPACE_DIM >

A node in a finite element mesh.

Definition at line 58 of file Node.hpp.

Constructor & Destructor Documentation

template<unsigned SPACE_DIM>
Node< SPACE_DIM >::Node ( unsigned  index,
ChastePoint< SPACE_DIM >  point,
bool  isBoundaryNode = false 
)

There are many ways of creating a node, depending on how you wish to specify its spatial location. Constructor that takes in the node's location as a ChastePoint.

Parameters
indexthe index of the node in the mesh
pointthe location of the node in the mesh
isBoundaryNodewhether the node is a boundary node (defaults to false)

Definition at line 56 of file Node.cpp.

References ChastePoint< DIM >::rGetLocation().

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
Node< SPACE_DIM >::Node ( unsigned  index,
std::vector< double coords,
bool  isBoundaryNode = false 
)

Constructor that takes in the node's location as a std::vector.

Parameters
indexthe index of the node in the mesh
coordsthe location of the node in the mesh
isBoundaryNodewhether the node is a boundary node (defaults to false)

Definition at line 63 of file Node.cpp.

template<unsigned SPACE_DIM>
Node< SPACE_DIM >::Node ( unsigned  index,
c_vector< double, SPACE_DIM >  location,
bool  isBoundaryNode = false 
)

Constructor that takes in the node's location as a c_vector.

Parameters
indexthe index of the node in the mesh
locationthe location of the node in the mesh
isBoundaryNodewhether the node is a boundary node (defaults to false)

Definition at line 73 of file Node.cpp.

template<unsigned SPACE_DIM>
Node< SPACE_DIM >::Node ( unsigned  index,
bool  isBoundaryNode = false,
double  v1 = 0,
double  v2 = 0,
double  v3 = 0 
)

Constructor that takes the coordinates of the node's location as separate input arguments.

Parameters
indexthe index of the node in the mesh
isBoundaryNodewhether the node is a boundary node (defaults to false)
v1the x-coordinate of the node in the mesh (defaults to 0)
v2the y-coordinate of the node in the mesh (defaults to 0)
v3the z-coordinate of the node in the mesh (defaults to 0)

Definition at line 80 of file Node.cpp.

template<unsigned SPACE_DIM>
Node< SPACE_DIM >::Node ( unsigned  index,
double location,
bool  isBoundaryNode = false 
)

Constructor that takes in the coordinates of the node's location as an array pointer.

Parameters
indexthe index of the node in the mesh
isBoundaryNodewhether the node is a boundary node (defaults to false)
locationaddress of the x-coordinate of the node in the mesh (other coordinates are assumed to be in contiguous memory)

Definition at line 95 of file Node.cpp.

template<unsigned SPACE_DIM>
Node< SPACE_DIM >::~Node ( )

Explicit destructor to free memory from mpNodeAttributes.

Definition at line 105 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

Member Function Documentation

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::AddAppliedForceContribution ( const c_vector< double, SPACE_DIM > &  rForceContribution)

Add a contribution to the force applied to this node.

Parameters
rForceContributionthe force vector to add to mAppliedForce

Definition at line 224 of file Node.cpp.

Referenced by RepulsionForce< DIM >::AddForceContribution(), BuskeCompressionForce< DIM >::AddForceContribution(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::AddBoundaryElement ( unsigned  index)

Add an boundary element that contains this node.

Parameters
indexof the element to add.

Definition at line 294 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::AddElement ( unsigned  index)
template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::AddNeighbour ( unsigned  index)

Add a neighbour to this node's vector of neighbouring node indices.

Parameters
indexof the node to add.

Definition at line 328 of file Node.cpp.

Referenced by ObsoleteBoxCollection< DIM >::CalculateNodePairs(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::AddNodeAttribute ( double  attribute)

Add an attribute to the list of node attributes.

Parameters
attributethe value of the attribute to be added

Definition at line 170 of file Node.cpp.

Referenced by NodesOnlyMesh< SPACE_DIM >::AddMovedNode(), DistributedTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMeshReader(), TetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMeshReader(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::CheckForNodeAttributes ( ) const
private

Check that node attributes have been set up, and throw an exception if not.

Definition at line 388 of file Node.cpp.

References EXCEPTION.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::ClearAppliedForce ( )

Clear the vector associated with the force.

Definition at line 216 of file Node.cpp.

Referenced by AbstractCentreBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::AddCell(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::ClearNeighbours ( )

Clear this node's vector of neighbour indices.

Definition at line 336 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::CommonConstructor ( unsigned  index,
bool  isBoundaryNode 
)
private

Extraction of commonality between the constructors.

Parameters
indexthe index of the node in the mesh
isBoundaryNodewhether the node is a boundary node

Definition at line 46 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::ConstructNodeAttributes ( )
private

Construct an empty NodeAttributes container.

Definition at line 397 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
ContainingBoundaryElementIterator Node< SPACE_DIM >::ContainingBoundaryElementsBegin ( ) const
inline
Returns
a ContainingBoundaryElementIterator pointing to the first containing boundary element

Definition at line 554 of file Node.hpp.

template<unsigned SPACE_DIM>
ContainingBoundaryElementIterator Node< SPACE_DIM >::ContainingBoundaryElementsEnd ( ) const
inline
Returns
a ContainingBoundaryElementIterator pointing to one past the last containing boundary element

Definition at line 562 of file Node.hpp.

References EXPORT_TEMPLATE_CLASS_SAME_DIMS, Node< SPACE_DIM >::GetIndex(), Node< SPACE_DIM >::IsBoundaryNode(), and Node< SPACE_DIM >::rGetLocation().

template<unsigned SPACE_DIM>
unsigned Node< SPACE_DIM >::GetIndex ( ) const
Returns
the index of this node in the mesh.

Definition at line 158 of file Node.cpp.

Referenced by RepulsionForce< DIM >::AddForceContribution(), AbstractTwoBodyInteractionForce< ELEMENT_DIM, SPACE_DIM >::AddForceContribution(), MutableMesh< ELEMENT_DIM, SPACE_DIM >::AddNode(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::AddNode(), QuadraticMeshHelper< DIM >::AddNodesToBoundaryElements(), NodesOnlyMesh< SPACE_DIM >::AddNodeWithFixedIndex(), ObsoleteBoxCollection< DIM >::CalculateNodePairs(), MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::CalculateRestLengths(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::CheckForSwapsFromShortEdges(), CellwiseSourceEllipticPde< DIM >::ComputeLinearInUCoeffInSourceTermAtNode(), CellwiseSourceParabolicPde< DIM >::ComputeSourceTermAtNode(), NodesOnlyMesh< SPACE_DIM >::ConstructNodesWithoutMesh(), Node< SPACE_DIM >::ContainingBoundaryElementsEnd(), LuoRudySpiralWaveCellFactory::CreateCardiacCellForTissueNode(), HeartConfigRelatedCellFactory< SPACE_DIM >::CreateCardiacCellForTissueNode(), AbstractPurkinjeCellFactory< ELEMENT_DIM, SPACE_DIM >::CreateJunctionFromFile(), AbstractPurkinjeCellFactory< ELEMENT_DIM, SPACE_DIM >::CreatePurkinjeCellForNode(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DeleteElementPriorToReMesh(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DivideEdge(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DivideElementAlongGivenAxis(), StreeterFibreGenerator< SPACE_DIM >::GetAveragedThicknessLocalNode(), Toroidal2dVertexMesh::GetMeshForVtk(), Cylindrical2dVertexMesh::GetMeshForVtk(), PottsMesh< DIM >::GetNeighbouringElementIndices(), VertexBasedCellPopulation< DIM >::GetTetrahedralMeshForPdeModifier(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::IdentifySwapType(), AbstractCorrectionTermAssembler< ELEM_DIM, SPACE_DIM, PROBLEM_DIM >::IncrementInterpolatedQuantities(), CellBasedParabolicPdeSolver< DIM >::IncrementInterpolatedQuantities(), LinearParabolicPdeSystemWithCoupledOdeSystemSolver< ELEMENT_DIM, SPACE_DIM, PROBLEM_DIM >::IncrementInterpolatedQuantities(), LessThanNode< SPACE_DIM >::operator()(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformIntersectionSwap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformNodeMerge(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformProtorosetteResolution(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformRosetteRankDecrease(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformRosetteRankIncrease(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT1Swap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT2Swap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT3Swap(), Node< SPACE_DIM >::serialize(), MutableMesh< ELEMENT_DIM, SPACE_DIM >::SplitEdge(), MutableMesh< ELEMENT_DIM, SPACE_DIM >::SplitLongEdges(), PottsBasedCellPopulation< DIM >::UpdateCellLocations(), VertexMesh< ELEMENT_DIM, SPACE_DIM >::VertexMesh(), and DistanceMapCalculator< ELEMENT_DIM, SPACE_DIM >::WorkOnLocalQueue().

template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::GetNeighboursSetUp ( )
Returns
a flag to indicate that the neighbours of this node have/have not been updated.

Definition at line 368 of file Node.cpp.

Referenced by NodeBasedCellPopulation< DIM >::GetNeighbouringNodeIndices(), NodeBasedCellPopulation< DIM >::GetNodesWithinNeighbourhoodRadius(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
unsigned Node< SPACE_DIM >::GetNumBoundaryElements ( ) const
Returns
the number of boundary elements in the mesh that contain this node.

Definition at line 318 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
unsigned Node< SPACE_DIM >::GetNumContainingElements ( ) const
template<unsigned SPACE_DIM>
unsigned Node< SPACE_DIM >::GetNumNodeAttributes ( )
Returns
the number of node attributes associated with this node.

Definition at line 186 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
unsigned Node< SPACE_DIM >::GetRegion ( ) const
template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::HasNodeAttributes ( )
Returns
Whether mpNodeAttributes has been set. Used in archiving of attributes in a mesh.

Definition at line 202 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::IsInternal ( ) const
Returns
whether the node is internal (not vertex) in a quadratic element.

Definition at line 424 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::IsParticle ( )
Returns
whether this node is a particle or not

Definition at line 232 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::MarkAsDeleted ( )

Mark the node as having been removed from the mesh.

Definition at line 406 of file Node.cpp.

Referenced by MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT3Swap(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::MarkAsInternal ( )

Mark the node as being internal (not vertex) in a quadratic element.

Definition at line 418 of file Node.cpp.

Referenced by QuadraticMeshHelper< DIM >::AddInternalNodesToElements(), QuadraticMesh< DIM >::MakeNewInternalNode(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::NeighboursIsEmpty ( )

Check whether the node neighbours collection is empty.

Returns
whether this node has any neighbours.

Definition at line 352 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::RemoveBoundaryElement ( unsigned  index)

Remove an boundary element that contains this node.

Parameters
indexof the boundary element to be removed.

Definition at line 284 of file Node.cpp.

References EXCEPTION.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::RemoveDuplicateNeighbours ( )

Remove duplicates from the vector of node neighbour indices.

Definition at line 344 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::RemoveElement ( unsigned  index)

Remove an element that contains this node.

Parameters
indexof the element to be removed.

Definition at line 274 of file Node.cpp.

References EXCEPTION.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
c_vector< double, SPACE_DIM > & Node< SPACE_DIM >::rGetAppliedForce ( )
Returns
the force applied to this node.

Definition at line 208 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
std::set< unsigned > & Node< SPACE_DIM >::rGetContainingBoundaryElementIndices ( )
Returns
a set of indices of boundary elements containing this node as a vertex.

Definition at line 306 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
std::set< unsigned > & Node< SPACE_DIM >::rGetContainingElementIndices ( )
Returns
a set of indices of elements containing this node as a vertex.

Definition at line 300 of file Node.cpp.

Referenced by MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::CheckForRosettes(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::CheckForSwapsFromShortEdges(), MutableMesh< ELEMENT_DIM, SPACE_DIM >::CheckIsVoronoi(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DeleteElementPriorToReMesh(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DivideEdge(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DivideElementAlongGivenAxis(), NagaiHondaDifferentialAdhesionForce< DIM >::GetAdhesionParameter(), NagaiHondaForce< DIM >::GetAdhesionParameter(), VertexBasedCellPopulation< DIM >::GetCellDataItemAtPdeNode(), FarhadifarForce< DIM >::GetLineTensionParameter(), VertexMesh< ELEMENT_DIM, SPACE_DIM >::GetNeighbouringElementIndices(), MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::GetVolumeOfCell(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::HandleHighOrderJunctions(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::IdentifySwapType(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformIntersectionSwap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformNodeMerge(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformProtorosetteResolution(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformRosetteRankDecrease(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformRosetteRankIncrease(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT1Swap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT2Swap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT3Swap(), Node< SPACE_DIM >::serialize(), MutableMesh< ELEMENT_DIM, SPACE_DIM >::SplitEdge(), MeshBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::Update(), PottsBasedCellPopulation< DIM >::UpdateCellLocations(), and VertexMesh< ELEMENT_DIM, SPACE_DIM >::VertexMesh().

template<unsigned SPACE_DIM>
const c_vector< double, SPACE_DIM > & Node< SPACE_DIM >::rGetLocation ( ) const
Returns
the node's location as a c_vector.

The returned location may not be modified; if you want that functionality use rGetModifiableLocation instead.

Definition at line 139 of file Node.cpp.

Referenced by RepulsionForce< DIM >::AddForceContribution(), BuskeCompressionForce< DIM >::AddForceContribution(), AbstractFeCableIntegralAssembler< ELEMENT_DIM, SPACE_DIM, PROBLEM_DIM, CAN_ASSEMBLE_VECTOR, CAN_ASSEMBLE_MATRIX, INTERPOLATION_LEVEL >::AssembleOnCableElement(), AbstractFeVolumeIntegralAssembler< ELEMENT_DIM, SPACE_DIM, PROBLEM_DIM, CAN_ASSEMBLE_VECTOR, CAN_ASSEMBLE_MATRIX, INTERPOLATION_LEVEL >::AssembleOnElement(), ObsoleteBoxCollection< DIM >::CalculateContainingBox(), DistributedBoxCollection< DIM >::CalculateContainingBox(), BuskeAdhesiveForce< DIM >::CalculateForceBetweenNodes(), BuskeElasticForce< DIM >::CalculateForceBetweenNodes(), GeneralisedLinearSpringForce< ELEMENT_DIM, SPACE_DIM >::CalculateForceBetweenNodes(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::CheckOutwardNormals(), FineCoarseMeshPair< DIM >::ComputeFineElementsAndWeightsForCoarseNodes(), AbstractTetrahedralMesh< ELEMENT_DIM, SPACE_DIM >::ConstructFromMesh(), Node< SPACE_DIM >::ContainingBoundaryElementsEnd(), LuoRudySpiralWaveCellFactory::CreateCardiacCellForTissueNode(), Cylindrical2dMesh::Cylindrical2dMesh(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DivideEdge(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DivideElementAlongGivenAxis(), NodeBasedCellPopulation< DIM >::GetNeighbouringNodeIndices(), NodeBasedCellPopulation< DIM >::GetNodesWithinNeighbourhoodRadius(), VertexBasedCellPopulation< DIM >::GetTetrahedralMeshForPdeModifier(), NodeBasedCellPopulation< DIM >::GetVolumeOfCell(), CryptSimulationBoundaryCondition< DIM >::ImposeBoundaryCondition(), PlaneBoundaryCondition< ELEMENT_DIM, SPACE_DIM >::ImposeBoundaryCondition(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformIntersectionSwap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformNodeMerge(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformProtorosetteResolution(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformRosetteRankDecrease(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT1Swap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformT3Swap(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::PerformVoidRemoval(), Node< SPACE_DIM >::serialize(), MutableMesh< ELEMENT_DIM, SPACE_DIM >::SplitEdge(), NodeBasedCellPopulationWithBuskeUpdate< DIM >::UpdateNodeLocations(), CryptSimulationBoundaryCondition< DIM >::VerifyBoundaryCondition(), VertexMesh< ELEMENT_DIM, SPACE_DIM >::VertexMesh(), and DistanceMapCalculator< ELEMENT_DIM, SPACE_DIM >::WorkOnLocalQueue().

template<unsigned SPACE_DIM>
std::vector< unsigned > & Node< SPACE_DIM >::rGetNeighbours ( )
template<unsigned SPACE_DIM>
std::vector< double > & Node< SPACE_DIM >::rGetNodeAttributes ( )
Returns
a vector containing the node attributes. An exception is thrown if the node has no attributes.

Definition at line 178 of file Node.cpp.

Referenced by AbstractCentreBasedCellPopulation< ELEMENT_DIM, SPACE_DIM >::AddCell(), NodesOnlyMesh< SPACE_DIM >::ConstructNodesWithoutMesh(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
template<class Archive >
void Node< SPACE_DIM >::serialize ( Archive &  archive,
const unsigned int  version 
)
inlineprivate

Archive the member variables.

Parameters
archivethe archive
versionthe current version of this class

Definition at line 99 of file Node.hpp.

References Node< SPACE_DIM >::AddAppliedForceContribution(), Node< SPACE_DIM >::AddBoundaryElement(), Node< SPACE_DIM >::AddElement(), Node< SPACE_DIM >::AddNeighbour(), Node< SPACE_DIM >::AddNodeAttribute(), Node< SPACE_DIM >::CheckForNodeAttributes(), Node< SPACE_DIM >::ClearAppliedForce(), Node< SPACE_DIM >::ClearNeighbours(), Node< SPACE_DIM >::CommonConstructor(), Node< SPACE_DIM >::ConstructNodeAttributes(), Node< SPACE_DIM >::GetIndex(), Node< SPACE_DIM >::GetNeighboursSetUp(), Node< SPACE_DIM >::GetNumBoundaryElements(), Node< SPACE_DIM >::GetNumContainingElements(), Node< SPACE_DIM >::GetNumNodeAttributes(), Node< SPACE_DIM >::GetPoint(), Node< SPACE_DIM >::GetRadius(), Node< SPACE_DIM >::GetRegion(), Node< SPACE_DIM >::HasNodeAttributes(), Node< SPACE_DIM >::IsBoundaryNode(), Node< SPACE_DIM >::IsDeleted(), Node< SPACE_DIM >::IsInternal(), Node< SPACE_DIM >::IsParticle(), Node< SPACE_DIM >::MarkAsDeleted(), Node< SPACE_DIM >::MarkAsInternal(), Node< SPACE_DIM >::mpNodeAttributes, Node< SPACE_DIM >::NeighboursIsEmpty(), Node< SPACE_DIM >::Node(), Node< SPACE_DIM >::RemoveBoundaryElement(), Node< SPACE_DIM >::RemoveDuplicateNeighbours(), Node< SPACE_DIM >::RemoveElement(), Node< SPACE_DIM >::rGetAppliedForce(), Node< SPACE_DIM >::rGetContainingBoundaryElementIndices(), Node< SPACE_DIM >::rGetContainingElementIndices(), Node< SPACE_DIM >::rGetLocation(), Node< SPACE_DIM >::rGetModifiableLocation(), Node< SPACE_DIM >::rGetNeighbours(), Node< SPACE_DIM >::rGetNodeAttributes(), Node< SPACE_DIM >::SetAsBoundaryNode(), Node< SPACE_DIM >::SetIndex(), Node< SPACE_DIM >::SetIsParticle(), Node< SPACE_DIM >::SetNeighboursSetUp(), Node< SPACE_DIM >::SetPoint(), Node< SPACE_DIM >::SetRadius(), Node< SPACE_DIM >::SetRegion(), and Node< SPACE_DIM >::~Node().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::SetIndex ( unsigned  index)

Set the index of the node in the mesh.

Parameters
indexthe index of the node

Definition at line 121 of file Node.cpp.

Referenced by MutableMesh< ELEMENT_DIM, SPACE_DIM >::AddNode(), NodesOnlyMesh< SPACE_DIM >::AddNode(), MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::AddNode(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::SetIsParticle ( bool  isParticle)

Set whether this node is a particle, for cell_based simulations.

Parameters
isParticlewhether this node is a particle or not.

Definition at line 240 of file Node.cpp.

Referenced by NodesOnlyMesh< SPACE_DIM >::AddMovedNode(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::SetNeighboursSetUp ( bool  flag)

Sets a flag to indicate that the neighbours of this node have/have not been updated.

Parameters
flagwhether the neighbours are set up or not.

Definition at line 360 of file Node.cpp.

Referenced by Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::SetPoint ( ChastePoint< SPACE_DIM >  point)

Set the node's location.

Note: setting the point in space is dangerous, because the Jacobian and JacobianDeterminant of any corresponding elements need to be updated.

Parameters
pointthe new location of the node

Definition at line 115 of file Node.cpp.

References ChastePoint< DIM >::rGetLocation().

Referenced by MutableVertexMesh< ELEMENT_DIM, SPACE_DIM >::DivideEdge(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::SetRadius ( double  radius)

Set the radius of the node.

Parameters
radiusthe value to assign to the radius property. Should be >= 0.0

Definition at line 256 of file Node.cpp.

Referenced by NodeBasedCellPopulation< DIM >::AddCell(), NodesOnlyMesh< SPACE_DIM >::AddMovedNode(), NodesOnlyMesh< SPACE_DIM >::AddNodeWithFixedIndex(), NodesOnlyMesh< SPACE_DIM >::ConstructNodesWithoutMesh(), and Node< SPACE_DIM >::serialize().

template<unsigned SPACE_DIM>
void Node< SPACE_DIM >::SetRegion ( unsigned  region)

Set the node's region ID.

Parameters
regionthe new region ID

Definition at line 430 of file Node.cpp.

Referenced by NodesOnlyMesh< SPACE_DIM >::AddMovedNode(), and Node< SPACE_DIM >::serialize().

Friends And Related Function Documentation

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

Needed for serialization.

Definition at line 90 of file Node.hpp.

Member Data Documentation

template<unsigned SPACE_DIM>
std::set<unsigned> Node< SPACE_DIM >::mBoundaryElementIndices
private

Set of indices of boundary elements containing this node as a vertex.

Definition at line 87 of file Node.hpp.

template<unsigned SPACE_DIM>
std::set<unsigned> Node< SPACE_DIM >::mElementIndices
private

Set of indices of elements containing this node as a vertex.

Definition at line 84 of file Node.hpp.

template<unsigned SPACE_DIM>
unsigned Node< SPACE_DIM >::mIndex
private

The index of this node within the mesh.

Definition at line 63 of file Node.hpp.

template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::mIsBoundaryNode
private

Whether this node is a boundary node.

Definition at line 72 of file Node.hpp.

template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::mIsDeleted
private

Whether this node has been deleted, and hence whether its location in the mesh can be re-used (for use in the MutableMesh class).

Definition at line 81 of file Node.hpp.

template<unsigned SPACE_DIM>
bool Node< SPACE_DIM >::mIsInternal
private

Whether this node is an internal node (for use in the QuadraticMesh class).

Definition at line 75 of file Node.hpp.

template<unsigned SPACE_DIM>
c_vector<double, SPACE_DIM> Node< SPACE_DIM >::mLocation
private

The location of this node within the mesh.

Definition at line 66 of file Node.hpp.

template<unsigned SPACE_DIM>
NodeAttributes<SPACE_DIM>* Node< SPACE_DIM >::mpNodeAttributes
private

A pointer to a NodeAttributes object associated with this node.

Definition at line 69 of file Node.hpp.

Referenced by Node< SPACE_DIM >::serialize().


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