File: VertexMutableGraph.html

package info (click to toggle)
boost 1.27.0-3
  • links: PTS
  • area: main
  • in suites: woody
  • size: 19,908 kB
  • ctags: 26,546
  • sloc: cpp: 122,225; ansic: 10,956; python: 4,412; sh: 855; yacc: 803; makefile: 257; perl: 165; lex: 90; csh: 6
file content (87 lines) | stat: -rw-r--r-- 2,777 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
<HTML>
<!--
  -- Copyright (c) Jeremy Siek 2001
  --
  -- Permission to use, copy, modify, distribute and sell this software
  -- and its documentation for any purpose is hereby granted without fee,
  -- provided that the above copyright notice appears in all copies and
  -- that both that copyright notice and this permission notice appear
  -- in supporting documentation.  Silicon Graphics makes no
  -- representations about the suitability of this software for any
  -- purpose.  It is provided "as is" without express or implied warranty.
  -->
<Head>
<Title>Vertex Mutable Graph</Title>
<BODY BGCOLOR="#ffffff" LINK="#0000ee" TEXT="#000000" VLINK="#551a8b" 
        ALINK="#ff0000"> 
<IMG SRC="../../../c++boost.gif" 
     ALT="C++ Boost" width="277" height="86"> 

<BR Clear>

<H2><A NAME="concept:VertexMutableGraph">
Vertex Mutable Graph
</H2>

A vertex mutable graph can be changed by adding or removing
vertices. The memory management is the responsibility of the graph
implementation. The graph user need only make calls to
<TT>add_vertex</TT> and <TT>remove_vertex</TT> and the graph
implementation does the rest.

<H3>Refinement of</H3>

<a href="./Graph.html">Graph</a> and <a
href="http://www.sgi.com/tech/stl/DefaultConstructible.html">DefaultConstructible</a>

<H3>Associated Types</H3>

No additional associated types.

<h3>Valid Expressions</h3>

<ul>
<li><a name="sec:add_vertex"><TT>add_vertex(g)</TT></a> 
<b>returns</b> <TT>vertex_descriptor</TT>
<br><br>

<b>Semantics:</b>  Add a new vertex to the graph. The
        <TT>vertex_descriptor</TT> for the new vertex is returned.<br>
</li>

<li><a name="sec:remove_vertex"><tt>remove_vertex(u, g)</tt></a>
<b>returns</b> <tt>void</tt><br><br>

<b> Semantics:</b>  Remove <i>u</i> from the vertex set of the graph.
<br>
<b> Preconditions:</b> <i>u</i> is a valid vertex descriptor of graph <i>g</i>
     and there are no edges incident to vertex <i>u</i>. The function
     <TT>clear_vertex</TT> can be used to remove all incident edges.
<br>
<b> Postconditions: </b> <TT>num_vertices(g)</TT> is one less; <i>u</i>
      no longer appears in the vertex set of the graph and it
      is no longer a valid vertex descriptor. 
</li>

</ul>

<H3>Complexity guarantees</H3>
<ul>
  <li> Vertex insertion is guaranteed to be amortized constant time.
 
  <li> Vertex removal is at most <TT>O(|E| + |V|)</TT>.
</ul>


<br>
<HR>
<TABLE>
<TR valign=top>
<TD nowrap>Copyright &copy 2000-2001</TD><TD>
<A HREF="../../../people/jeremy_siek.htm">Jeremy Siek</A>, Indiana University (<A HREF="mailto:jsiek@osl.iu.edu">jsiek@osl.iu.edu</A>)
<A HREF="../../../people/jeremy_siek.htm">Lie-Quan Lee</A>, Indiana University (<A HREF="mailto:llee@cs.indiana.edu">llee@cs.indiana.edu</A>)
</TD></TR></TABLE>

</BODY>
</HTML>