horokai_network/lib.rs
1//!
2//! # Define struct Network for graph theory
3//!
4//! This is my experimental project to use Rust for numerical calculation of complex network theory.
5//!
6//! ## struct Network is the universe of the graph system
7//! The struct Network is the universe of the system in mathmatics literature.
8//! This struct is the simplest expression of the network or graph. See pages of the struct Network.
9//! Functions exist to manage the struct Network.
10//! This is the design of this crate.
11//!
12
13mod create;
14mod get;
15
16///
17/// # Definition of struct Network, the implementation of network in mathmatics.
18///
19/// Expression of network or graph is "The set of vertexes and the set of links which is pair of the vertex".
20/// I use this index rule: the vertex is denoted by number 0 ~ n-1, n as the amount of the vertexes.
21/// So the expression of the struct Network becomes simple and smart.
22///
23/// Note : A famous way of the expression of network is adjacency matrix, but it use O(n^2) memory space.
24/// I may prepare the access to the adjacency matrix bia function, but it is not inevitable.
25/// Many of the calculation experiment program for the network dynamics like percolation is written with using edge list expression of the network, not adjacency matrix.
26///
27#[derive(Clone)]
28pub struct Network {
29 n: u32,
30 edge_list: Vec<(u32, u32)>,
31}