pub fn reciprocal_transmission_index(graph: &Graph) -> IgraphResult<f64>Expand description
Compute the reciprocal transmission index.
RT(G) = Σ_v 1/σ(v) where σ(v) = Σ_w d(v,w).
Vertices with σ(v) = 0 (isolated or single-vertex components) are skipped.
§Examples
use rust_igraph::{Graph, reciprocal_transmission_index};
// Path 0-1-2: σ=[3,2,3], RT = 1/3 + 1/2 + 1/3 = 7/6
let g = Graph::from_edges(&[(0,1),(1,2)], false, Some(3)).unwrap();
assert!((reciprocal_transmission_index(&g).unwrap() - 7.0/6.0).abs() < 1e-10);