Template Numerical Library version\ main:4e58ea6
Loading...
Searching...
No Matches
TNL::Graphs::Graph< Matrix, GraphType > Struct Template Reference

Public Types

using DeviceType = typename Matrix::DeviceType
 
using IndexType = typename Matrix::IndexType
 
using MatrixType = Matrix
 
using ValueType = typename Matrix::RealType
 

Public Member Functions

 Graph (const Graph &)=default
 
 Graph (const MatrixType &matrix)
 
template<typename OtherGraph >
 Graph (const OtherGraph &&other)
 
template<typename OtherGraph >
 Graph (const OtherGraph &other)
 
 Graph (Graph &&)=default
 
 Graph (IndexType nodesCount, const std::initializer_list< std::tuple< IndexType, IndexType, ValueType > > &data, Matrices::SymmetricMatrixEncoding encoding=Matrices::SymmetricMatrixEncoding::LowerPart)
 
template<typename MapIndex , typename MapValue >
 Graph (IndexType nodesCount, const std::map< std::pair< MapIndex, MapIndex >, MapValue > &map, Matrices::SymmetricMatrixEncoding encoding=Matrices::SymmetricMatrixEncoding::LowerPart)
 
 Graph (MatrixType &&matrix)
 
MatrixType & getAdjacencyMatrix ()
 
const MatrixType & getAdjacencyMatrix () const
 
IndexType getEdgeCount () const
 
IndexType getNodeCount () const
 
ValueType getTotalWeight () const
 
Graphoperator= (const Graph &)=default
 
Graphoperator= (Graph &&)=default
 
bool operator== (const Graph &other) const
 
template<typename Matrix_ >
void setAdjacencyMatrix (Matrix_ matrix)
 
template<typename MapIndex , typename MapValue >
void setEdges (const std::map< std::pair< MapIndex, MapIndex >, MapValue > &map)
 
template<typename Vector >
void setNodeCapacities (const Vector &nodeCapacities)
 
void setNodeCount (IndexType nodesCount)
 

Static Public Member Functions

static constexpr GraphTypes getGraphType ()
 
static constexpr bool isDirected ()
 
static constexpr bool isUndirected ()
 

Protected Attributes

MatrixType adjacencyMatrix
 

The documentation for this struct was generated from the following file: