Assuming you mean r = (x² + y² + z²)^(1/2):
Let g = r^n = (x² + y² + z²)^(n/2).
So, g_x = nx(x² + y² + z²)^(n/2 - 1)
==> g_xx = n(x² + y² + z²)^(n/2 - 1) + nx * (n/2 - 1) 2x(x² + y² + z²)^(n/2 - 2)
...............= n(x² + y² + z²)^(n/2 - 1) + n(n - 2)x²(x² + y² + z²)^(n/2 - 2).
Similarly,
g_yy = n(x² + y² + z²)^(n/2 - 1) + n(n - 2)y²(x² + y² + z²)^(n/2 - 2)
g_zz = n(x² + y² + z²)^(n/2 - 1) + n(n - 2)z²(x² + y² + z²)^(n/2 - 2)
Hence, the Laplacian ∇²g = g_xx + g_yy + g_zz equals
3n(x² + y² + z²)^(n/2 - 1) + n(n-2)(x² + y² + z²) (x² + y² + z²)^(n/2 - 2)
= 3n(x² + y² + z²)^(n/2 - 1) + n(n-2) (x² + y² + z²)^(n/2 - 1)
= [3n + n(n-2)] (x² + y² + z²)^(n/2 - 1)
= n(n+1) (x² + y² + z²)^(n/2 - 1)
Therefore, ∇²g = 0 <==> n(n+1) = 0 <==> n = 0, -1.
I hope this helps!
Let g = r^n = (x² + y² + z²)^(n/2).
So, g_x = nx(x² + y² + z²)^(n/2 - 1)
==> g_xx = n(x² + y² + z²)^(n/2 - 1) + nx * (n/2 - 1) 2x(x² + y² + z²)^(n/2 - 2)
...............= n(x² + y² + z²)^(n/2 - 1) + n(n - 2)x²(x² + y² + z²)^(n/2 - 2).
Similarly,
g_yy = n(x² + y² + z²)^(n/2 - 1) + n(n - 2)y²(x² + y² + z²)^(n/2 - 2)
g_zz = n(x² + y² + z²)^(n/2 - 1) + n(n - 2)z²(x² + y² + z²)^(n/2 - 2)
Hence, the Laplacian ∇²g = g_xx + g_yy + g_zz equals
3n(x² + y² + z²)^(n/2 - 1) + n(n-2)(x² + y² + z²) (x² + y² + z²)^(n/2 - 2)
= 3n(x² + y² + z²)^(n/2 - 1) + n(n-2) (x² + y² + z²)^(n/2 - 1)
= [3n + n(n-2)] (x² + y² + z²)^(n/2 - 1)
= n(n+1) (x² + y² + z²)^(n/2 - 1)
Therefore, ∇²g = 0 <==> n(n+1) = 0 <==> n = 0, -1.
I hope this helps!