The partial derivative of the sum with respect to x or y equals 1 (i.e. if you only see addition, the result be always 1):

The partial derivative of x multiplied by y, with respect to x or y, equals the other output (i.e. if you only see multiplication between x and y, they exchange their values with each other, always):

The partial derivative of max() of 2 variables with respect to either of them is 1 if that variable is the biggest, otherwise 0:

The derivative of the max() of a single variable x equals 1 if x > 0, otherwise 0:

  • 1 if x > y else 0
  • 1 if x > 0 else 0

The derivative of chained functions equals the product of the partial derivatives of subsequent functions:


Gradient

The gradient is a vector of all possible partial derivatives (i.e. the inverted triangle is just the notation/symbol for the “things” where the red arrow is pointing):