How can I convert an adjacency matrix to its corresponding node list?Please help.
조회 수: 3 (최근 30일)
이전 댓글 표시
I have an adjacency matrix
A = 0 1 1 1 1 0
1 0 1 1 1 1
1 0 0 1 0 1
1 1 1 0 1 1
1 0 1 1 0 1
0 0 0 0 1 0
I want to get the output as:
1 2
1 3
2 3
1 4
2 4
3 4
1 5
2 5
4 5
2 6
3 6
4 6
5 6
댓글 수: 0
답변 (1개)
Steven Lord
2017년 4월 24일
Use the find function. Or if you've built a digraph object out of this adjacency matrix, see the Edges property of that digraph.
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Graph and Network Algorithms에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!