John’s relation
Abs[x-y]
Max[x,y]
+
Min[x,y]
x+y-Min[x,y]
1;
Step by step, you found that the relation can be re-arranged
Min[x,y]
x+y-Min[x,y]
1-
Abs[x-y]
Max[x,y]
;
with the RHS
1-
Abs[x-y]
Max[x,y]

Max[x,y]-Abs[x-y]
Max[x,y]
;
So now John’s relation is
Min[x,y]
x+y-Min[x,y]

Max[x,y]-Abs[x-y]
Max[x,y]
;
And solving for the LHS denominator yields your version:
Min[x,y]*Max[x,y]
Max[x,y]-Abs[x-y]
x+y-Min[x,y];
This means that for the summation expression
p
∑
i=1
Abs[
x
i
-
y
i
]
p
∑
i=1
Max[
x
i
,
y
i
]
+
p
∑
i=1
Min[
x
i
,
y
i
]
p
∑
i=1
x
i
+
p
∑
i=1
y
i
-
p
∑
i=1
Min[
x
i
,
y
i
]
;
the denominator of the second term is
p
∑
i=1
x
i
+
p
∑
i=1
y
i
-
p
∑
i=1
Min[
x
i
,
y
i
]
Min[x1,y1]*Max[x1,y1]
Max[x1,y1]-Abs[x1-y1]
+
Min[x2,y2]*Max[x2,y2]
Max[x2,y2]-Abs[x2-y2]
+...