Code for the surface nodes in place. Doesn't work though, needs debugging.