how to find all aliques of a node from an adjacency matrix?

2 vues (au cours des 30 derniers jours)
rumin diao
rumin diao le 13 Oct 2022
i ran into a problem that find all cliques that a node have...
for example, here's an adjacency matrix:
X = [0 1 1 1 1
1 0 1 1 1
1 1 0 1 0
1 1 1 0 0
1 1 0 0 0];
1 means the two nodes can connect and 0 is the opposite meaning.
all the cliques that the first node have is [1 2 3 4] and [1 2 5], and that's the result i find by drawing a picture instead of by coding. my question is how to code and find the result?
i totally have no idea😭if anyone helps me, thanks a lot!!!

Réponses (0)

Catégories

En savoir plus sur Directed Graphs dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by