Skip to main content

chronon::sender::DirectedGraph

Directed graph with weighted edges; weights encode communication delay in cycles.

#include <Graph.hpp>

Public Classes

Name
structEdge

Public Functions

Name
const std::vector< Edge > &predecessors(size_t node) const
size_tnumNodes() const
size_tnumEdges() const
const std::vector< Edge > &neighbors(size_t node) const
boolhasEdge(size_t from, size_t to) const
uint32_tedgeWeight(size_t from, size_t to) const
Returns INF if no edge exists.
voidaddEdge(size_t from, size_t to, uint32_t weight =1)
DirectedGraph(size_t num_nodes)

Public Attributes

Name
uint32_tINF

Public Functions Documentation

function predecessors

inline const std::vector< Edge > & predecessors(
size_t node
) const

function numNodes

inline size_t numNodes() const

function numEdges

inline size_t numEdges() const

function neighbors

inline const std::vector< Edge > & neighbors(
size_t node
) const

function hasEdge

inline bool hasEdge(
size_t from,
size_t to
) const

function edgeWeight

inline uint32_t edgeWeight(
size_t from,
size_t to
) const

Returns INF if no edge exists.

function addEdge

inline void addEdge(
size_t from,
size_t to,
uint32_t weight =1
)

function DirectedGraph

inline explicit DirectedGraph(
size_t num_nodes
)

Public Attributes Documentation

variable INF

static uint32_t INF = std::numeric_limits<uint32_t>::max() / 2;

Updated on 2026-05-26 at 05:42:32 +0000