Find maximal cliques for large & sparse network

Version 1.5.0.0 (3.43 KB) by max Wei
Find maximal cliques for large & sparse network
945 Downloads
Updated 13 Aug 2014

View License

IN A NUTSHELL: The code is based on maximalCliques() by Jeffrey Wildman, 2011. It uses logical indexing instead of set operations for better memory performance, and uses degeneracy ordering for faster performance with large and sparse network.
-----------------------------------
MORE DETAILS: It finds maximal cliques using the Bron-Kerbosch algorithm with both pivoting and degeneracy ordering. Degeneracy ordering speeds up the algorithm especially when the graph is large & sparse.
Given a graph's adjacency matrix, A, it finds all maximal cliques on A using the Bron-Kerbosch algorithm in a recursive manner. The graph is required to be undirected and must contain no self-edges.
The output is a sparse matrix where each column indicates a clique.

Part of the code is based on maximalCliques() by Jeffrey Wildman, 2011.

Algorithm Reference: Eppstein, Loffler, and Strash "Listing All Maximal Cliques in Sparse Graphs in Near-Optimal Time
", 2010

Cite As

max Wei (2024). Find maximal cliques for large & sparse network (https://www.mathworks.com/matlabcentral/fileexchange/47524-find-maximal-cliques-for-large-sparse-network), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2014a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Graph and Network Algorithms in Help Center and MATLAB Answers
Tags Add Tags
Acknowledgements

Inspired by: Bron-Kerbosch maximal clique finding algorithm

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.5.0.0

trivial

1.4.0.0

Changed the output to be sparse (saving memory). Updated descriptions and tags.

1.3.0.0

Change title

1.2.0.0

Add reference

1.1.0.0

Add description

1.0.0.0