This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
> Date: Tue, 19 Nov 1996 11:19:14 -0800 > From: address@hidden (P.J.Flatau) > To: address@hidden > Subject: Re: netCDF and complex numbers Piotr, > thanks for the help with "complex". I have hacked it like this > > > complex cxrfr > > id2 ... > idncom ... > > iddim(1)=id2 > iddim(2)=idncomp > idcxrfr=ncvdef(idnc,'cxrfr',ncfloat,2,iddim, ierr) > > > istart(1)=1 > istart(2)=1 > icount(1)=2 > icount(2)=ncomp > call ncvpt(idnc, idcxrfr, istart, icount, cxrfr, ierr) Yes, that will work fine. I made a mistake in my NCVGT() call, forgetting the one dimensional array of complex numbers had been defined as a two-dimensional array of reals, so I should have used length 2 vectors for the start and count arguments, as you have done. --Russ P.S. I've forwarded your general recommendations for improving the Fortran interface to Steve Emmerson, who is now working on an all-new Fortran interface for netCDF-3.