pub fn centralization_degree_tmax(
n: u32,
directed: bool,
mode: CentralizationMode,
loops: LoopMode,
) -> f64Expand description
Theoretical maximum degree centralization for a star graph.
Returns NaN for n == 0.
ยงExamples
use rust_igraph::{CentralizationMode, LoopMode, centralization_degree_tmax};
// Undirected, no loops, 5 vertices: (5-1)*(5-2) = 12
let tmax = centralization_degree_tmax(5, false, CentralizationMode::All, LoopMode::NoLoops);
assert!((tmax - 12.0).abs() < 1e-9);