I have been working on graph representations in Haskell in early 2017. Related work is the article Algebraic graphs with class (functional pearl) by Andrey Mokhov. The difference between my representation and Mokhov’s is his addition of the Overlay and Empty operators that allows the representation of more graphs. I suspect there is a deep relation between Mokhov’s representation and classical propositional logic, but more on that topic later.
For a copy of my literate Haskell file, see the paper of 21-05-2017.Graphs in Haskell
Algebraic graphs with class