pub fn edge_degree_product_ratio(graph: &Graph) -> IgraphResult<f64>Expand description
Compute the product-sum ratio index over edges.
Σ_{(u,v)∈E} d(u)·d(v) / (d(u) + d(v))²
Each edge contributes a value in (0, 0.25]. Equals m/4 for
regular graphs. Self-loops and zero-degree endpoints are skipped.
§Examples
use rust_igraph::{Graph, edge_degree_product_ratio};
// K_3: all (2,2) → 4/16 = 0.25 per edge → 0.75
let g = Graph::from_edges(&[(0,1),(1,2),(0,2)], false, Some(3)).unwrap();
assert!((edge_degree_product_ratio(&g).unwrap() - 0.75).abs() < 1e-10);