write xdmf only if kernel wavefields are written

causing paraview to crash otherwise without any useful errormsg