Putting x=y=1 in (2) yields f(1)=f(1)2, that is f(1)∈{0,1}.
Case 1: f(1)=0
(a) If k=0, (2) becomes for x=y=t, t=0: f(1)=t2f(t)2, whence f(t)=0, t=0. Let k=0. Then y=1 and x=t in (2) yields f(tk)=tf(t)f(1)=0. Letting x=y in (2) finally leads to f((x2)k)=x2f(x)2, that is 0=x2f(x)2, whence f(x)=0, x=0.
Case 2: f(1)=1
Letting x=t and y=1/t, t=0, in (2) shows f(1)=f(t)⋅f(1/t). Therefore, f(t)=0, t=0. Putting x=y=−1 in (2) yields f((−1)2k)=(−1)2f(−1)2, that is f(−1)2=1. Thus f(−1)∈{−1,1}.
(a) Let k be odd. Then x=1 and y=−1 in (2) leads to
f((−1)k)=−f(−1)(3)
that is f(−1)=−f(−1). Therefore, we get the contradiction f(−1)=0.
(b) For k even we get from (3): f(−1)=−1.
i) If k=0, (2) yields for y=1 and x=t, t=0: f(1)=tf(t) that is f(t)=1/t.
ii) For k=0 we get from (2) for x=1, y=t, t=0:
f(tk)=tf(t).(4)
This and (2) imply
xyf(x)f(y)=f(xkyk)=f((xy)k)=xyf(xy).
Therefore,
f(xy)=f(x)f(y)(5)
Putting x=t and y=tk−1, t=0, yields in view of (4) and (5):
tf(t)=f(tk)=f(t⋅tk−1)=f(t)f(tk−1).
Therefore, f(tk−1)=t, t=0. As k is even all real numbers x, x=0, have a unique representation x=tk−1, t=0. Thus, finally f(x)=x1/(k−1)=tk−1/2.
It is easily checked that all functions obtained in the course of our solution satisfy (2).
Summary: All solutions to (2) are given by
* f(x)=0, x∈R, for all integers k and additionally
* f(x)={x1/(k−1),0,x=0x=0, if k is an even integer.