lotsa headers and Graphviz
refactored