clear all;
x = 17;
y = 14;
u = 8;
v = 3;

G = u^2/(u+v)+v^2/(u+v)+...
    x^2/(x+y)+y^2/(x+y)+...
   -(u+x)^2/(u+v+x+y)-(v+y)^2/(u+v+x+y)