yields True if the graph g is an undirected graph and False otherwise.
Examplesopen allclose all
Basic Examples (2)
Test whether a graph is undirected:
UndirectedGraphQ gives False for inputs that are not undirected graphs:
UndirectedGraphQ works with undirected graphs:
UndirectedGraphQ gives False for anything that is not an undirected graph:
UndirectedGraphQ works with large graphs:
Properties & Relations (5)
The empty graphs are undirected graphs:
An undirected graph can have self-loops:
A graph is either undirected or directed:
A symmetric adjacency matrix is interpreted to be an undirected graph:
Use DirectedEdges->True to interpret it as a directed graph:
The incidence matrix of an undirected graph has no negative entries:
Possible Issues (1)
UndirectedGraphQ gives False for non-explicit graphs:
Wolfram Research (2010), UndirectedGraphQ, Wolfram Language function, https://reference.wolfram.com/language/ref/UndirectedGraphQ.html.
Wolfram Language. 2010. "UndirectedGraphQ." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/UndirectedGraphQ.html.
Wolfram Language. (2010). UndirectedGraphQ. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/UndirectedGraphQ.html