Folks,
we have quite big output files from a seismic wavefield simulation and
want to fourier transform them for further use.
The idea would be that the output file is opened, the wavefields are
read and transformed and copied into a new file.
However, there are a lot of smaller variables in the file, which should
be copied to the new file as well. I do not want to declare temporary
arrays for all of them and so I gave NF_COPY_VAR a try.
The questions:
1. NetCDF-C has the routine nc_copy_var, which seems to be perfectly
suited. Can you call it from a Fortran90 code?
2. There is the undocumented NF_COPY_VAR. However, using this like
status = nf_copy_var(ncin_grpid, varid, ncout_id)
print *, nf_strerror(status), status
Results in
NetCDF: Invalid dimension ID or name -46
even though nf90_get_var can read perfectly from this variable with the
same group and variable id. Also, the error does not seem to make much
sense, since neither dimensions or names are even involved.
3. Is there any reliable documentation for NF_COPY_VAR or a Fortran90
version of it?
Since the code is to be distributed, we would not like it to rely on NCO
or similar external routines and do everything with the normal Fortran
interface.
Any ideas?
cheers,
Simon
--
o»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«o
| Simon Stähler PhD student |
| |
| Geophysik, Ludwig-Maximilians-Universität München |
| Theresienstrasse 41 80333 München Germany |
| Tel. : +49 (0)89 2180 4143 |
| www.geophysik.uni-muenchen.de/members/staehler |
o»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«»«o