Update writenec2.m