nocad.matching.Matching#
- class nocad.matching.Matching(matched_by)[source]#
Bases:
objectA matching of a directed network.
- Attributes:
- matched_by
ndarrayofshape(N,) matched_by[i] = jif the edge \(x_j\to x_i\) is in the matching,-1if \(x_i\) is unmatched (MATLABmatchedByminus one).
- matched_by
- property edges#
Matched edges as an
(|M|, 2)array of (start, end) pairs.
- property matched#
Nodes with an incoming matched edge.
- property matches#
matches[j] = iif \(x_j\to x_i\) is matched, else-1(out-copy view).
- property size#
Number of matched edges \(|\mathcal{M}|\).
- property unmatched#
Nodes without an incoming matched edge (driver candidates).