Representation of relations using Graph