diff options
Diffstat (limited to 'sourcecodes/bnt-master/graph/mk_undirected.m')
| -rw-r--r-- | sourcecodes/bnt-master/graph/mk_undirected.m | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/sourcecodes/bnt-master/graph/mk_undirected.m b/sourcecodes/bnt-master/graph/mk_undirected.m new file mode 100644 index 00000000..0a1614aa --- /dev/null +++ b/sourcecodes/bnt-master/graph/mk_undirected.m @@ -0,0 +1,11 @@ +function U = mk_undirected(G) + +[nr nc] = size(G); +U = G; +for i=1:nr + for j=1:nc + if U(i,j)==1 + U(j,i) = 1; + end + end +end |
