Skip to content

PrescribedOpticalProperties

James Manners edited this page Jan 28, 2026 · 2 revisions

Prev: Preparing input files of atmospheric profiles

Prescribed optical properties for clouds and aerosols

The basic optical properties required by the radiation code for each layer of the atmosphere are the coefficients for absorption, scattering and the scattering phase function. These are generally parametrised for each radiatively active species in the spectral file, but in the case of clouds and aerosols it is also possible to prescribe the optical properties directly for the given atmospheric profile.

An example for cloud droplets

An example of prescribing optical properties for cloud droplets is given in examples/prsc which we will run through here. To begin we set up a set of input files using the raw_input routine described in the previous tutorial:

cd $RAD_DIR/examples/prsc
raw_input > /dev/null << EOF
input_prsc
XX
n
EOF

Here we want all the output to be in files with the same base-name. We can use the utility sbin/csbn to rename all the files with a given base-name (and remove the unwanted pressure file):

csbn XX_1 x_cl
csbn XX_2 x_cl
csbn XX_3 x_cl
rm x_cl.p

We now need to generate the prescribed optical properties. For this we can use the Mie code "Cscatter". This program calculates the monochromatic single scattering properties of spherical particles averaged over a size distribution at a range of specified wavelengths. A full description of the options available is given in the man page:

man Cscatter

For this example we generate droplet properties for two different size distributions:

Cscatter -w $RAD_DATA/cloud/wl_cloud -r $RAD_DATA/cloud/refract_water \
    -l -g 1.0 5.e-7 1.2 -n 1.0e10 -o xcl1 -P 51 -t 2 -M
Cscatter -w $RAD_DATA/cloud/wl_cloud -r $RAD_DATA/cloud/refract_water \
    -l -g 1.0 8.e-7 1.15 -n 1.0e10 -o xcl2 -P 51 -t 2 -M

The options we have used:

  • -w $RAD_DATA/cloud/wl_cloud: gives a table of wavelengths at which the droplet properties are calculated. This should be at a high enough wavelength resolution to capture the variation. We will average over these wavelengths later to give the properties for the actual bands used in the spectral file.
  • -r $RAD_DATA/cloud/refract_water: table of complex refractive indices covering the required wavelength range.
  • -l: linear interpolation used to determine the refractive index at a given wavelength.
  • -g 1.0 5.e-7 1.2: droplets have a log-normal size distribution with one mode and a geometric mean radius of 5.e-7 metres and geometric standard deviation of 1.2 (dimensionless). Note, be careful to use geometric values here, appropriate for a log-normal.
  • -n 1.0e10: the number density of droplets in m-3.
  • -P 51: calculate 51 moments of the phase function.
  • -t 2: type of scatterer is droplets.
  • -M: perform a full Mie caclulation.
  • -o xcl1: the output file.

It's useful to look at the output files:

less xcl1
less xcl2

These are now averaged over the spectral bands we are to use for the calculation given in the spectral file sp_cksa. The averaging is done using the routine Cscatter_average. A full description of the options available is given in the man page:

man Cscatter_average

Here, we are simply outputting the averaged optical properties (weighted with a solar spectrum) to the file xcla1/2:

Cscatter_average -s sp_cksa \
   -S $RAD_DATA/solar/labs_neckel_70d -w -a xcla1 -P 51 xcl1
Cscatter_average -s sp_cksa \
   -S $RAD_DATA/solar/labs_neckel_70d -w -a xcla2 -P 51 xcl2
less xcla1
less xcla2

We now want to prescribe these as the cloud optical properties at two different pressure levels. For this we need to create an input file with the extension .op_water. Within the radiative transfer code the optical properties will be required on the standard grid, but the levels in the .op file do not have to match this. Using cubic splines, the program will interpolate from the levels in the file of prescribed properties to the midpoints of the layers, and will assume that the optical properties are zero outside the specified range. For this example we will specify our optical properties at the boundaries of our single cloud layer (7.0e4 and 8.0e4 Pa) and let the code interpolate the values for the cloud layer at 7.5e4 Pa.

To create the .op_water file we will use the prep_opt_profile routine which does not have a man page but is described in the Socrates User Guide (chapter 5).

First set up a file containing on each line a pressure level and the name of a file of averaged scattering properties:

cat > x_input_level_list << EOF
7.0e4 xcla1
8.0e4 xcla2
EOF

Then run prep_opt_profile outputting to the file x_cl.op_water:

prep_opt_profile > /dev/null << EOF
x_input_level_list
0 0
x_cl.op_water
EOF

Finally the radiative transfer code is run in spherical harmonics mode. By specifying the type of droplets to be -d 0 we indicate the .op_water file should be used:

Cl_run_cdl -s sp_cksa -R 1 6 -S -g 1 1 -r -G 5 0 -C 3 \
   -B x_cl -d 0 +F -H -K 1 +R +S 3 3 0 0
ncplot x_cl.hrts &

Prescribed aerosol properties

These are treated in a similar way to the cloud prescribed properties. The option -a to the Cl_run_cdl script indicates that aerosols are to be included. If this is specified alone the program will expect to find files of mass mixing ratios on the usual grid (such as .soot for soot): parametrized data from the spectral file will be used. If +A is specified as well the program will first check for the existence of files with suffixes consisting of the string op followed by that for the aerosol (such as .op_soot) which will be assumed to contain the optical properties of the particular aerosol and these data will be used instead of a parametrization. Prescribed profiles may be set for only a selection of the aerosols in the spectral file, however aerosols must exist in the spectral file for prescribed properties to be used.

For example in the CIRC case 6 (examples/netcdf/CIRC_case6), a single prescribed aerosol is used in the .op_soot file:

cdfdump $RAD_DIR/examples/netcdf/CIRC_case6/case6.op_soot_hadgem | less

This was created from the text files provided for the CIRC intercomparison, and converted to netCDF input format using the python routine ncout_opt_prop (in nctools.py). The full script used to convert all the CIRC text file information into the full set of CIRC input profiles can be seen in the script circ2nc.py. We won't go into the details here but the script can be found in the python directory here:

less $RAD_DIR/python/circ2nc.py

Next: Modifying the spectral configuration: spectral files

Clone this wiki locally