a b c d e f |- -| a | 0 0 0 1 1 0 | b | 0 0 0 1 1 1 | c | 0 0 0 0 1 1 | d | 1 1 0 0 1 0 | e | 1 1 1 1 0 1 | f | 0 1 1 0 1 0 | |_ _|
In graph 2, there are 4 vertices of odd degree (1, 5, 7 and 3), so there
is no Euler circuit or Euler path. In graph 1, there are exactly
two vertices of odd degree (b and e), so there is an Euler path. It
starts at b and ends at e, or vice versa. Using the algorithm
for finding Euler paths, we starting by choosing any path from b to e.
For example, we could start with
b → c → f → h → g → d → a → e
Here's what remains:
The next step is to find an Euler circuit in what remains. We'll start
with any circuit, for example
a → b → f → h → g → d → a
Here's what now remains:
and an Euler circuit through this is
b → e →c → f → e → d → b
Splicing the last circuit into the second-to last gives
a → b → e →c → f → e → d → b →
f → h → g → d → a
Finally, shift this circuit to start at b, and splice it
into the start of the original path, giving
b → e →c → f → e → d → b →
f → h → g → d → a →
b → c → f → h → g → d → a → e
In the dual, there are 5 vertices, 4 regions, and 7 edges. Now
v-e+r=5-7+4 = 2.
Step # | a | b | c | d | e | f | g | Next closest vertex: |
---|---|---|---|---|---|---|---|---|
0 | (0, a) | (∞, -) | (∞, -) | (∞, -) | (∞, -) | (∞, -) | (∞, -) | a |
1 | (14, a) | (∞, -) | (∞, -) | (17, a) | (∞, -) | (10, a) | g | |
2 | (13, g) | (∞, -) | (14, g) | (16, g) | (∞, -) | b | ||
3 | (22, b) | (14, g) | (16, g) | (24, b) | d | |||
4 | (22, b) | (15, d) | (21, d) | e | ||||
5 | (22, b) | (21, d) | f | |||||
6 | (22, b) | c |