code: def gradient(poly):
      
      return differential(poly, chaospy.poly.collection.basis(1, 1, poly.dim))
docs: Gradient of a polynomial.
  
      Args:
          poly (Poly) : polynomial to take gradient of.
  
      Returns:
          (Poly) : The resulting gradient.
  
      Examples:
          >>> q0, q1, q2 = chaospy.variable(3)
          >>> poly = 2*q0 + q1*q2
          >>> print(chaospy.gradient(poly))
          [2, q2, q1]