How to calculate the max value of cantor pairing function given the min and max of the inputs?

223 Views Asked by At

For the cantor pairing function

https://en.wikipedia.org/wiki/Pairing_function

which takes 2 numbers and returns another number. If I know the min and max values of each of the 2 inputs, is there a way I can automatically know what the biggest value of the cantor pairing function for some input within the ranges?