powered by
Generates a connection matrix for a random undirected graph. Intended for input to QAOA_maxcut.
randomConnectionMatrix(nNodes,nEdges)
Number of nodes in generated graph
Number of undirected edges in generated graph
Connection Matrix specifying the edges of an undirected graph. Rows are source nodes, columns are destination nodes.
# NOT RUN { randomConnectionMatrix(5,3) # }
Run the code above in your browser using DataLab