Graph
Definition. A graph is a finite set of nodes together with a set of edges, each edge joining two nodes. In a directed graph each edge has a direction, from one node to another; in an undirected graph it does not, and two nodes joined by an edge are adjacent. A path from to is a sequence of nodes beginning at and ending at in which each consecutive pair is joined by an edge, and a cycle is a path from a node back to itself.
A graph is encoded as a string by listing its nodes and then the pairs that are edges, so a graph on nodes has an encoding of length polynomial in . Defined in Lecture 9 for ; the problems of Lectures 10 and 11, such as and , are stated in the same vocabulary.