# Exercici 10.20

kill(all)$

g(x,y):=x^2-y^2;

z(x,y):=y*f(g(x,y));

diff(z(x,y), x); 
diff(z(x,y), y);

Dxg = diff(g(x,y),x);
Dyg = diff(g(x,y),y);

Dxz(x,y) = diff(z(x,y), x) * diff(g(x,y),x);
Dyz(x,y) = diff(g(x,y),y)*y*('diff(f(x^2-y^2),y,1))+f(x^2-y^2);

Dxz(x,y):=2*x*y*Df(x^2-y^2);
Dyz(x,y):=-2*y^2*Df(x^2-y^2)+f(x^2-y^2);

(1/x)*Dxz(x,y)+(1/y)*Dyz(x,y);

factor(%);

y*f(x^2-y^2)/y^2=z/y^2;