update function addArc