I wonder whether there is an algorithm to efficiently calculate a discrete 1-dimensional Minkowski sum. The Minkowski sum is defined as:
S + T = { x + y | x in S, y in T }
Could it be that we can represent the sets as lists, sort S and T, and then do something similarly to computing the union of two sets. i.e. walk along the sets in parallel and generate the result.
Are there such algorithms known where I don't have to additionally sort the result to remove overlapping cases x1+y1 = x2+y2? Preferably formulated in Java?