graph representation idea