Kdistribution computes k-distribution data sets from high-resolution spectra
that have been produced by Kspectrum. The user
should specify some basic information to the code by editing the
data.in input files:
options.in: various quadratures can be selected; a Legendre quadrature is used by default. Then the quadrature order should be specified, and various quadrature-dependant parameters can be adjusted. One interesting option is the possibility to use quadratic splines over high-resolution spectra instead of a linear interpolation between two successive values of the absorption coefficient.
data.in: lets the user specify the first and last levels of the high-resolution spectra set that should be converted to k-distribution data.
Before using the code, the user should create a link named
hires_spectra within the
/data directory; this link
should be pointing to the directory that contains the high-resolution spectra
produced by Kspectrum for a given atmospheric profile, as well as the
composition.in file used by Kspectrum. The
directory should also contain a file named
narrowbands.in used to
describe the spectral intervals over which the k-distribution data set should
be computed. This file has to use the same format as the
narrowbands.in Kspectrum input data file. However, the
narrowbands.in file used by Kdistribution does not necessarily
have to be identical to the file used by Kspectrum.
You will have to download both the
.tgz file and the
installation script, and place both files in the same directory. Then run the
installation script. This will mainly uncompress the archive.
Prerequisites: all you need is a fortran compiler. The gfortran compiler is used for development, but compilation should also work with other fortran compilers (ifort, pgfortran, etc.).
Then you can try to compile Kdistribution: go to the main Kdistribution
directory, then use the
make all command to compile. The most
common sources of failure can be fixed by editing the
file in order to check compilation options (and more specifically options
related to the target architecture and optimisations). Whenever you modify a
source file, you can re-compile using the
make all command. But in
the case you have to modify a include file, you will have to erase all existing
object files first using the
make clean command, before
recompiling from scratch using the
make all command again.
Kdistribution is free software released under the CeCILL v2.1 license. You are welcome to redistribute it under certain conditions; refer to the license for details.