Changes

16,492 bytes added ,  11:32, 6 September 2007
Copy text from Wikipedia under GFDL : Revision of 16:08, 6 September 2006 by Jon Awbrey
{{for|an introduction to graph theory|Graph (mathematics)}}

In [[mathematics]] and [[computer science]], '''graph theory''' has for its subject matter the properties of ''[[graph (mathematics)|graphs]]''. Informally speaking, a graph is a set of objects called ''points'' or ''vertices'' connected by links called ''lines'' or ''edges''. In a graph proper, which is by default ''undirected'', a line from point ''A'' to point ''B'' is considered to be the same thing as a line from point ''B'' to point ''A''. In a ''digraph'', short for ''directed graph'', the two directions are counted as being distinct ''arcs'' or ''directed edges''.

==History==
One of the first results in graph theory appeared in [[Leonhard Euler]]'s paper on ''[[Seven Bridges of Königsberg]]'', published in [[1736]]. It is also regarded as one of the first topological results in geometry; that is, it does not depend on any measurements. This illustrates the deep connection between graph theory and [[topology]].

In [[1845]] [[Gustav Kirchhoff]] published his [[Kirchhoff's circuit laws]] for calculating the [[voltage]] and [[current (electricity)|current]] in [[electric circuit]]s.

In [[1852]] [[Francis Guthrie]] posed the [[four color problem]] which asks if it is possible to color, using only four colors, any map of countries in such a way as to prevent two bordering countries from having the same color. This problem, which was only solved a century later in [[1976]] by [[Kenneth Appel]] and [[Wolfgang Haken]], can be considered the birth of graph theory. While trying to solve it mathematicians invented many fundamental graph theoretic terms and concepts.

==Definition==

[[Image:Undirected.svg|125px|right]]
Definitions of graphs vary in style and substance, according to the level of abstraction that is approriate to a particular approach or application. For the sake of perspective, the following definitions present the same substance in two different styles:

First, a classic definition, that covers most of the essential ideas in a very short space:
<blockquote>
A ''graph'' ''G'' consists of a finite nonempty set ''V'' = ''V''(''G'') of ''p'' ''points'' together with a prescribed set ''X'' of ''q'' unordered pairs of distinct points of ''V''. Each pair ''x'' = {''u'', ''v''} of points in ''X'' is a ''line'' of ''G'', and ''x'' is said to ''join'' ''u'' and ''v''. We write ''x'' = ''uv'' and say that ''u'' and ''v'' are ''adjacent points'' (sometimes denoted ''u'' adj ''v''); point ''u'' and line ''x'' are ''incident'' with each other, as are ''v'' and ''x''. If two distinct lines ''x'' and ''y'' are incident with a common point, then they are ''adjacent lines''. A graph with ''p'' points and ''q'' lines is called a (''p'',&nbsp;''q'') ''graph''. The (1, 0) graph is ''trivial''. (Harary, ''Graph Theory'', p.&nbsp;9).
</blockquote>

Next, a style of definition that is preferred in some approaches and applications:

A '''graph''' or '''undirected graph''' ''G'' is an [[ordered triple]] ''G'':=(''V'', ''E'', ''f'') subject to the following conditions:

* ''V'' is a [[set]], whose elements are variously referred to as '''nodes''', '''points''', or '''vertices'''.
* ''E'' is a set, whose elements are known as '''edges''' or '''lines'''.
* ''f'' is a function that maps each element of ''E'' to an unordered pair of distinct vertices in ''V'', referred to as the '''ends''', '''endpoints''', or '''end vertices''' of the edge.

''V'' (and hence ''E'') are usually taken to be finite sets, and many of the well-known results are not true (or are rather different) for '''infinite graphs''' because many of the arguments fail in the infinite case.

[[Image:Directed.svg|125px|right]]A '''digraph''' or a '''directed graph''' ''G'' is an ordered pair ''G'':=(''V'', ''A'') subject to the following conditions:

* ''V'' is a [[set]], whose elements are variously referred to as '''nodes''', '''points''', or '''vertices'''.

* ''A'' is a set of ordered pairs of vertices, called '''arcs''', '''arrows''', or '''directed edges'''. An edge ''e'' = (''x'', ''y'') is said to be directed '''from''' ''x'' '''to''' ''y'', where ''x'' is the '''tail''' of ''e'' and ''y'' is the '''head''' of ''e''.

Alternatively, a '''digraph''' or a '''directed graph''' may be defined as an ordered triple ''G'':=(''V'', ''E'', ''f'') subject to the following conditions:

* ''V'' is a [[set]], whose elements are variously referred to as '''nodes''', '''points''', or '''vertices'''.

* ''E'' is a set, whose elements are known as '''arcs''', '''arrows''', or '''directed edges'''.

* ''f'' is a function that maps each element in ''E'' to an ordered pair of vertices in ''V''.

There are also some mixed type of graphs with undirected and directed edges.

See [[Glossary of graph theory]] for further definitions.

==Drawing graphs==
{{main|Graph drawing}}

Graphs are represented graphically by drawing a dot for every vertex, and drawing an arc between two vertices if they are connected by an edge. If the graph is directed, the direction is indicated by drawing an arrow.

A graph drawing should not be confused with the graph itself (the abstract, non-graphical structure) as there are several ways to structure the graph drawing. All that matters is which vertices are connected to which others by how many edges and not the exact layout. In practice it is often difficult to decide if two drawings represent the same graph. Depending on the problem domain some layouts may be better suited and easier to understand than others.

==Graph-theoretic data structures==
{{main|Graph (data structure)}}

There are different ways to store graphs in a computer system. The [[data structure]] used depends on both the graph structure and the [[algorithm]] used for manipulating the graph. Theoretically one can distinguish between list and matrix structures but in concrete applications the best structure is often a combination of both. List structures are often preferred for [[sparse graph]]s as they have smaller memory requirements. Matrix structures on the other hand provide faster access but can consume huge amounts of memory if the graph is very large.

===List structures===

* '''[[Incidence list]]''' - The edges are represented by an [[array]] containing pairs (ordered if directed) of vertices (that the edge connects) and eventually weight and other data.

* '''[[Adjacency list]]''' - Much like the incidence list, each vertex has a list of which vertices it is adjacent to. This causes redundancy in an undirected graph: for example, if vertices A and B are adjacent, A's adjacency list contains B, while B's list contains A. Adjacency queries are faster, at the cost of extra storage space.

===Matrix structures===

* '''[[Incidence matrix]]''' - The graph is represented by a [[Matrix (mathematics)|matrix]] of E (edges) by V (vertices), where [edge, vertex] contains the edge's data (simplest case: 1 - connected, 0 - not connected).

* '''[[Adjacency matrix]]''' - there is an N by N matrix, where N is the number of vertices in the graph. If there is an edge from some vertex x to some vertex y, then the element <math>M_{x, y}</math> is 1, otherwise it is 0. This makes it easier to find subgraphs, and to reverse graphs if needed.

* '''[[Laplacian matrix]]''' or '''[[Kirchhoff matrix]]''' or '''Admittance matrix''' - is defined as [[degree matrix]] minus [[adjacency matrix]] and thus contains adjacency information and degree information about the vertices

* '''[[Distance matrix]]''' - A symmetric N by N matrix an element <math>M_{x, y}</math> of which is the length of shortest path between x and y; if there is no such path <math>M_{x, y}</math> = infinity. It can be derived from powers of the '''[[Adjacency matrix]]'''.

==Problems in graph theory==
===Problems about subgraphs===

A common problem, called [[subgraph isomorphism problem]], is finding [[subgraph]]s in a given graph. Many [[graph properties]] are ''hereditary'', which means that a graph has a property if and only if all subgraphs have it too. For example a graph is [[planar graph|planar]] if it contains neither the [[complete bipartite graph]] <math>K_{3,3}</math> (See [[Three cottage problem]]) nor the [[complete graph]] <math>K_{5}</math>. Unfortunately, finding maximal subgraphs of a certain kind is often an [[NP-complete problem]].

* Finding the largest [[complete graph]] is called the [[clique problem]] (NP-complete)

* Finding the largest [[independent set]] is called the [[independent set problem]] (NP-complete)

Another class of problems has to do with the extent to which various species and generalizations of graphs are determined by their ''point-deleted subgraphs'', for example:

* [[Reconstruction conjecture]]

===Graph coloring===

Many problems have to do with various ways of [[graph coloring|coloring graphs]], for example:

* The [[four-color theorem]]
* The [[perfect graph|strong perfect graph theorem]]
* The [[Erdős-Faber-Lovász conjecture]] (unsolved)
* The [[total coloring|total coloring conjecture]] (unsolved)
* The [[list edge-coloring|list coloring conjecture]] (unsolved)

===Route problems===

* [[Hamiltonian path problem|Hamiltonian path and cycle problems]]
* [[Seven Bridges of Königsberg]]
* [[Minimum spanning tree]]
* [[Steiner tree]]
* [[Shortest path problem]]
* [[Route inspection problem]] (also called the "Chinese Postman Problem")
* [[Traveling salesman problem]] (NP-Complete)

===Network flow===

There are numerous problems arising especially from applications that have to do with various notions of [[network flow|flows in networks]], for example:

* [[Max flow min cut theorem]]

=== Visibility graph problems===

* [[Visibility graph|Museum guard problem]]

===Covering problems===

[[Covering (graph theory)|Covering problems]] are specific instances of subgraph-finding problems, and they tend to be closely related to the [[clique problem]] or the [[independent set problem]].

* [[Set cover problem]]
* [[Vertex cover problem]]

==Applications==

Applcations of graph theory are primarily, but not exclisively, concerned with labeled graphs and various specializations of these.

Structures that can be represented as graphs are ubiquitous, and many problems of practical interest can be represented by graphs. The link structure of a [[website]] could be represented by a directed graph: the vertices are the web pages available at the website and a directed edge from page ''A'' to page ''B'' exists if and only if ''A'' contains a link to ''B''. A similar approach can be taken to problems in travel, biology, computer chip design, and many other fields. The development of [[algorithm]]s to handle graphs is therefore of major interest in [[computer science]].

A graph structure can be extended by assigning a weight to each edge of the graph. Graphs with weights can be used to represent many different concepts; for example if the graph represents a road network, the weights could represent the length of each road.<ref name="Note1">The only information a weighted graph provides as such is (a) the vertices, (b) the edges and (c) the weights. Therefore the example in which the weights represent the roads' lengths doesn't imply that the weights are merely redundant annotations: there is no actual topographical information associated with the graph, so unlike reading a map, measuring the distances between the vertices is completely meaningless -- without the weights, there would be no way of telling what the distance between the vertices is in real life.</ref> A digraph with weighted edges is called a [[network (mathematics)|network]].

Networks have many uses in the practical side of graph theory, [[network analysis]] (for example, to model and analyze traffic networks or to discover the ''shape'' of the internet -- see [[#Applications|Applications]] below). Within network analysis, the definition of the term "network" varies, and may often refer to a simple graph.

Many applications of graph theory exist in the form of [[network analysis]]. These split broadly into two categories. Firstly, analysis to determine structural properties of a network, such as the distribution of vertex degrees and the [[Distance (graph theory) |diameter]] of the graph. A vast number of graph measures exist, and the production of useful ones for various domains remains an active area of research. Secondly, analysis to find a measurable quantity within the network, for example, for a [[Transportation network (graph theory)|transportation network]], the level of vehicular flow within any portion of it.

Graph theory is also used to study molecules in [[chemistry]] and [[physics]]. In [[condensed matter physics]], the three dimensional structure of complicated simulated atomic structures can be studied quantitatively by gathering statistics on graph-theoretic properties related to the topology of the atoms. For example, Franzblau's shortest-path (SP) rings.

==Notes==
<references/>

==References==

* [[Frank Harary|Harary, Frank]], ''Graph Theory'', Addison-Wesley, Reading, MA, 1969.

==See also==

* [[Gallery of named graphs]]
* [[Glossary of graph theory]]
* [[List of graph theory topics]]
* [[List of publications in mathematics#Graph theory|Publications in graph theory]]

===Related topics===
{{col-begin}}
{{col-break}}
* [[Conceptual graph]]
* [[Data structure]]
* [[Disjoint-set data structure]]
* [[Entitative graph]]
{{col-break}}
* [[Existential graph]]
* [[Graph (data structure)|Graph data structure]]
* [[Graph coloring]]
* [[Graph drawing]]
{{col-break}}
* [[Logical graph]]
* [[Loop (graph theory)|Loop]]
* [[Null graph]]
* [[Tree (data structure)|Tree data structure]]
{{col-end}}

===Algorithms===
{{col-begin}}
{{col-break}}
* [[Bellman-Ford algorithm]]
* [[Dijkstra's algorithm]]
* [[Ford-Fulkerson algorithm]]
{{col-break}}
* [[Kruskal's algorithm]]
* [[Nearest neighbour algorithm]]
* [[Prim's algorithm]]
{{col-end}}

===Subareas===
{{col-begin}}
{{col-break}}
* [[Algebraic graph theory]]
* [[Geometric graph theory]]
* [[Extremal graph theory]]
{{col-break}}
* [[Metric graph theory]]
* [[Random graph|Probabilistic graph theory]]
* [[Topological graph theory]]
{{col-end}}

===Related areas of mathematics===
{{col-begin}}
{{col-break}}
* [[Combinatorics]]
* [[Group theory]]
{{col-break}}
* [[Knot theory]]
* [[Ramsey theory]]
{{col-end}}

===Prominent graph theorists===
{{col-begin}}
{{col-break}}
* [[Paul Erdős|Erdős, Paul]]
* [[Claude Berge|Berge, Claude]]
* [[Frank Harary|Harary, Frank]]
{{col-break}}
* [[Denes König|König, Denes]]
* [[W.T. Tutte|Tutte, W.T.]]
{{col-end}}

==External links==

* More people and publications at: ''[http://www1.cs.columbia.edu/~sanders/graphtheory/people/alphabetic.html Graph Theory White Pages]''

;Online textbooks
* [http://www.math.uni-hamburg.de/home/diestel/books/graph.theory/ Graph Theory] (1997/2005) by Reinhard Diestel
* [http://www.ecp6.jussieu.fr/pageperso/bondy/books/gtwa/gtwa.html Graph Theory with Applications] (1976) by Bondy and Murty
*[http://arxiv.org/PS_cache/cond-mat/pdf/0602/0602129.pdf Phase Transitions in Combinatorial Optimization Problems, Section 3: Introduction to Graphs] (2006) by Hartmann and Weigt

;Other resources
* [http://www.utm.edu/departments/math/graph/ Graph theory tutorial]
* [http://www2.hig.no/~algmet/animate.html The compendium of algorithm visualisation sites]
* [http://www.nlsde.buaa.edu.cn/~kexu/benchmarks/graph-benchmarks.htm Challenging Benchmarks for Maximum Clique, Maximum Independent Set, Minimum Vertex Cover and Vertex Coloring]
*[http://www.nd.edu/~networks/gallery.htm Image gallery no.1: Some real-life networks]
*[http://www.aisee.com/graphs/ Image gallery no.2: More real-life graphs]
*[http://people.freenet.de/Emden-Weinert/graphs.html Graph links collection]
*[http://www.utc.edu/Faculty/Christopher-Mawata/petersen/lesson4.htm Useful tools and Explanation]
*[http://ttt.upv.es/~arodrigu/grafos/index.htm Grafos Spanish copyleft software]
*[http://www.ffconsultancy.com/products/ocaml_for_scientists/complete/ Source code for computing neighbor shells in particle systems under periodic boundary conditions]
*[http://www1.cs.columbia.edu/~sanders/graphtheory/ Graph Theory Resources]
* {{MathWorld | urlname=GraphTheory | title=Graph Theory }}, hosted by the makers of ''[[Mathematica]][http://www.wolfram.com/]''

[[Category:Combinatorics]]
[[Category:Graph Theory]]
[[Category:Mathematics]]
[[Category:Visualization]
12,080

edits