pull gradient into Util