modify the Graph