You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+31-22Lines changed: 31 additions & 22 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,18 +2,36 @@
2
2
3
3
This project implements several algorithm to compute the [modular decomposition](https://en.wikipedia.org/wiki/Modular_decomposition) of a graph.
4
4
5
-
+`fracture`
6
-
+ A $O(n + m \log n)$ algorithm based on [[HPV99]](https://doi.org/10.1142/S0129054199000125) and [[CHM02]](https://doi.org/10.46298/dmtcs.298).
7
-
+ First sketch based on a Julia implementation [[Kar19]](https://github.com/StefanKarpinski/GraphModularDecomposition.jl), but now heavily modified.
8
-
+`skeleton`
9
-
+ A $O(n + m \log n)$ algorithm based on [[MS00]](https://doi.org/10.46298/dmtcs.274).
10
-
+`linear (ref)`
11
-
+ A $O(n + m)$ algorithm based on [[TCHP08]](https://doi.org/10.1007/978-3-540-70575-8_52).
12
-
+ A wrapper for the C++ implementation of [[Miz23]](https://github.com/mogproject/modular-decomposition).
13
-
+`linear`
14
-
+ A $O(n + m)$ algorithm based on [[TCHP08]](https://doi.org/10.1007/978-3-540-70575-8_52).
15
-
+ A port of the C++ implementation of [[Miz23]](https://github.com/mogproject/modular-decomposition) to Rust.
16
-
+ Some additional modifications.
5
+
The project is structures as follows.
6
+
7
+
**Library**
8
+
+`crates/modular-decomposition` A package providing the `fracture` algorithm based on [[HPV99]](https://doi.org/10.1142/S0129054199000125) and [[CHM02]](https://doi.org/10.46298/dmtcs.298) as a library.
9
+
10
+
**Algorithms**
11
+
+`crates/linear-ref-sys`/`crates/linear-ref` Bindings and wrapper to reference C++ implementation [[Miz23]](https://github.com/mogproject/modular-decomposition) based on [[TCHP08]](https://doi.org/10.1007/978-3-540-70575-8_52).
12
+
+`crates/linear` Rust port of [[Miz23]](https://github.com/mogproject/modular-decomposition) based on [[TCHP08]](https://doi.org/10.1007/978-3-540-70575-8_52).
13
+
+`crates/skeleton` Based on [[MS00]](https://doi.org/10.46298/dmtcs.274).
14
+
+`crates/fracture` Based on [[HPV99]](https://doi.org/10.1142/S0129054199000125) and [[CHM02]](https://doi.org/10.46298/dmtcs.298). Uses the implementation in `crates/modular-decomposition`.
15
+
16
+
**Others**
17
+
+`crates/common` Common utilities shared by the algorithm crate
18
+
+`crates/playground` A crate to experiment with related algorithms and data structures.
19
+
+`crates/evaluation` Evaluation of the algorithms on real-world and generated data.
20
+
21
+
## Usage
22
+
23
+
The crate `crates/modular-decomposition` provides an API to compute the modular decomposition.
@@ -22,16 +40,7 @@ This project implements several algorithm to compute the [modular decomposition]
22
40
This figure shows the algorithm performance for some datasets.
23
41
The time for multiple runs is averaged for each instance and algorithm. The time for each algorithm is divided by the best time and the distribution is plotted.
24
42
The `fracture` algorithm performs best for most instances.
25
-
26
-
## As a library
27
-
28
-
The crates implementing the algorithms provide a API for the modular decompostion.
29
-
```
30
-
pub fn modular_decomposition<N, E>(graph: &Graph<N, E, Undirected>) -> DiGraph<MDNodeKind, ()>
31
-
{
32
-
prepare(graph).compute().finalize()
33
-
}
34
-
```
43
+
The evaluation code can be found in `crates/evaluation`.
Determining whether a graph is a [cograph](https://en.wikipedia.org/wiki/Cograph).
8
30
9
-
This figure shows the algorithm performance for some datasets.
10
-
The time for multiple runs is averaged for each instance and algorithm. The time for each algorithm is divided by the best time and the distribution is plotted.
11
-
The `fracture` algorithm performs best for most instances.
The algorithm is implemented for structs that implement the `petgraph`
47
+
traits `NodeCompactIndexable`, `IntoNeighbors`, and `GraphProp<EdgeType = Undirected>`.
48
+
49
+
## Evaluation
50
+
51
+

14
52
15
-
+[HPV99] Michel Habib, Christophe Paul, and Laurent Viennot. “Partition Refinement Techniques: An Interesting Algorithmic Tool Kit”. https://doi.org/10.1142/S0129054199000125.
16
-
+[CHM02] Christian Capelle, Michel Habib, and Fabien Montgolfier. “Graph Decompositions and Factorizing Permutations”. https://doi.org/10.46298/dmtcs.298
17
-
+[MS00] Ross M. Mcconnell and Jeremy P. Spinrad. “Ordered Vertex Partitioning”. https://doi.org/10.46298/dmtcs.274
18
-
+[TCHP08] Marc Tedder, Derek Corneil, Michel Habib, and Christophe Paul. “Simpler Linear-Time Modular Decomposition Via Recursive Factorizing Permutations”. https://doi.org/10.1007/978-3-540-70575-8_52.
0 commit comments