graph simulation