|
NetSci
|
Represents a node in a graph. More...
#include <node.h>
Public Member Functions | |
| Node () | |
| Default constructor for Node. | |
| ~Node () | |
| Destructor for Node. | |
| Node (unsigned int numFrames, unsigned int index_) | |
| Constructor for Node with specified number of frames and index. | |
| void | addAtom (Atom *atom, CuArray< float > *coordinates, CuArray< float > *nodeCoordinates) |
| Add an Atom to the Node. | |
| std::string | tag () |
| Get the tag of the Node. | |
| unsigned int | numAtoms () const |
| Get the number of Atoms in the Node. | |
| unsigned int | index () const |
| Get the index of the Node. | |
| float | totalMass () const |
| Get the total mass of the Node. | |
| unsigned int | hash () const |
| Get the hash value of the Node. | |
| std::vector< Atom * > | atoms () const |
| Get a vector of pointers to the Atoms in the Node. | |
Private Attributes | |
| unsigned int | _numAtoms |
| std::vector< int > | atomIndices_ |
| unsigned int | _index |
| float | _totalMass |
| std::string | _tag |
| std::vector< Atom * > | atoms_ |
| unsigned int | _hash = 0 |
| unsigned int | _numFrames |
Friends | |
| class | Network |
Represents a node in a graph.
| Node::Node | ( | unsigned int | numFrames, |
| unsigned int | index_ | ||
| ) |
Constructor for Node with specified number of frames and index.
| numFrames | Number of frames. |
| index_ | Index of the node. |
| std::vector< Atom * > Node::atoms | ( | ) | const |
Get a vector of pointers to the Atoms in the Node.
Returns a vector of pointers to the Atoms contained in the Node.
Python Example
| unsigned int Node::hash | ( | ) | const |
| unsigned int Node::index | ( | ) | const |
Get the index of the Node.
Returns the index of the Node.
Python Example
| unsigned int Node::numAtoms | ( | ) | const |
Get the number of Atoms in the Node.
Returns the number of Atoms contained in the Node.
Python Example
| std::string Node::tag | ( | ) |
Get the tag of the Node.
Returns the tag of the Node, which represents its unique identifier.
Python Example
| float Node::totalMass | ( | ) | const |
Get the total mass of the Node.
Returns the total mass of the Node, calculated as the sum of the masses of all the Atoms in the Node.
Python Example