I am trying to find either a name or a way of modeling the following phenomenon:
Let's use the functions $add(x, y)$ and $max(x, y)$. Both these functions are known to be associative and commutative.
Now consider the following functions, which take a series of values and produce a single outcome using the above functions as "reduce" functions:
$$sum(x_1, x_2) := add(x_1, x_2)$$ $$sum(x_1, x_2, \cdots, x_n) := sum(add(x_1, x_2), x_3, \cdots, x_n)\quad\forall \;n>2$$
$$mmax(x_1, x_2) := max(x_1, x_2)$$ $$mmax(x_1, x_2, \cdots, x_n) := mmax(max(x_1, x_2), x_3, \cdots, x_n)\quad\forall \;n>2$$
Now because $sum$ and $mmax$ collapse down to compositions of $add$ and $max$ respectively, which are associative and commutative, any order of the arguments $x1, x2, \cdots, xn$ produces the same outcome.
We can further say:
$$sum(x_1, x_2, \cdots, x_n) = add(x_1, sum(x_2, x_3, \cdots, x_n))$$ $$mmax(x_1, x_2, \cdots, x_n) = max(x_1, mmax(x_2, x_3, \cdots, x_n))$$
which shows that calculating $sum$ or $max$ over a series of values is equivalent to calculating it over a subset of those values and applying it over that subresult's result and the additional values.
For my case this means I can calculate the sum of a large set of values, and later throw in more values without having to redo the whole summation, and instead just add that new value in.
For $add$, which has an inverse function $subtract$, there exist another phenomenon: If I want to remove a value from a summation, I can do that just as trivially by subtracting the value. For $max$, this property does not exist.
My question is: How is this phenomenon called? I came up with the following sentence, but I feel like there might be a term describing it as a whole.
Given a function $f(x, y)$ that is associative and commutative, the reduction of a series of values $V = v_1, v_2, ..., v_n$ using $f(x)$ can be built by reducing the result of a subset of $V$ with the remaining elements. If $f$ has a reverse function $f'$, so that $f'(f(a, b), b) = a$, the reduction can also be built by reducing the result of a superset of $V$ with the superfluous elements using $f'$.
From what I can tell, this seems like a reduction, which is used in program optimization. The function is “reducible”. Funnily enough you used the word a couple of times in your question.