2D graph plotter in final state
2D graph does the job well but some error handling part are left