romanian ego
romanian ego

Reputation: 105

Can a Directed acyclic graph have zero edges?

Suppose Graph G is a directed acyclic graph with 'n' no of vertices. Would this be a DAG if I remove all the edges from the graph and make it completely disconnected?

Upvotes: 3

Views: 1991

Answers (1)

Patrick87
Patrick87

Reputation: 28292

According to Wikipedia, a directed graph is just a set of vertices and a set of directed edges. A set can be empty, so you can have a directed graph with an empty set of edges. The same object would probably qualify as an undirected graph with no undirected edges as well. A graph with no edges cannot contain a cycle, so such a graph must be acyclic.

Upvotes: 8

Related Questions