V
- the graph vertex typeE
- the graph edge typepublic class SmallestDegreeLastColoring<V,E> extends GreedyColoring<V,E>
This is the greedy coloring algorithm with the smallest-last ordering of the vertices. The basic
idea is as follows: Assuming that vertices vk+1, ..., vn
have been already selected,
choose v_k
so that the degree of v_k
in the subgraph induced by V - {vk+1,
..., v_n}
is minimal. See the following paper for details.
VertexColoringAlgorithm.Coloring<V>, VertexColoringAlgorithm.ColoringImpl<V>
graph, SELF_LOOPS_NOT_ALLOWED
Constructor and Description |
---|
SmallestDegreeLastColoring(Graph<V,E> graph)
Construct a new coloring algorithm.
|
Modifier and Type | Method and Description |
---|---|
protected Iterable<V> |
getVertexOrdering()
Get the ordering of the vertices used by the algorithm.
|
getColoring
protected Iterable<V> getVertexOrdering()
getVertexOrdering
in class GreedyColoring<V,E>
Copyright © 2017. All rights reserved.