結果 : gradient function of a graph