htcp

Properties of water suspended in clouds
git clone git://git.meso-star.fr/htcp.git
Log | Files | Refs | README | LICENSE

les2htcp.1 (4566B)


      1 .\" Copyright (C) 2018, 2020-2023, 2025, 2025 |Méso|Star> (contact@meso-star.com)
      2 .\" Copyright (C) 2018 Centre National de la Recherche Scientifique
      3 .\" Copyright (C) 2018 Université Paul Sabatier
      4 .\"
      5 .\" This program is free software: you can redistribute it and/or modify
      6 .\" it under the terms of the GNU General Public License as published by
      7 .\" the Free Software Foundation, either version 3 of the License, or
      8 .\" (at your option) any later version.
      9 .\"
     10 .\" This program is distributed in the hope that it will be useful,
     11 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
     12 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
     13 .\" GNU General Public License for more details.
     14 .\"
     15 .\" You should have received a copy of the GNU General Public License
     16 .\" along with this program. If not, see <http://www.gnu.org/licenses/>.
     17 .Dd February 05, 2024
     18 .Dt LES2HTCP 1
     19 .Os
     20 .Sh NAME
     21 .Nm les2htcp
     22 .Nd convert cloud properties from netCDF to
     23 .Xr htcp 5
     24 .Sh SYNOPSIS
     25 .Nm
     26 .Op Fl cfhqv
     27 .Op Fl m Ar float_to_meter
     28 .Op Fl o Ar output
     29 .Op Fl p Ar pagesize
     30 .Fl i Ar netcdf
     31 .Sh DESCRIPTION
     32 .Nm
     33 generates a
     34 .Xr htcp 5
     35 file from cloud properties stored in a netCDF file.
     36 The variables expected in the submitted netCDF file are:
     37 .Bl -dash -offset indent
     38 .It
     39 .Va W_E_direction
     40 and
     41 .Va S_N_direction :
     42 one-dimensional list of the position at the center of each cell along the
     43 west-east and south-north horizontal axis, respectively.
     44 The mesh must be homogeneous: each cell must have the same width along each
     45 axis.
     46 The unit is assumed to be meters, but this can be adjusted via
     47 the
     48 .Fl m
     49 option.
     50 .It
     51 .Va VLEV
     52 or
     53 .Va vertical_levels :
     54 position at the center of each cell along the vertical axis.
     55 The vertical mesh can be inhomogeneous, i.e. each cell can have a different
     56 vertical extent.
     57 At least one of these variables must be defined.
     58 Note that
     59 .Va VLEV
     60 is a four-dimensional variable, whereas
     61 .Va vertical_levels
     62 is assumed to be one-dimensional.
     63 In all cases
     64 .Nm
     65 assumes that the vertical columns are
     66 the same for each cell along the west-east and south-north axes.
     67 The unit is assumed to be meters, but this can be adjusted via the
     68 .Fl m
     69 option.
     70 .It
     71 .Va RVT :
     72 water vapor mixing ratio in each grid cell; in kg of water per kg of
     73 air.
     74 .It
     75 .Va RCT :
     76 mixing ratio of liquid suspended water in each grid cell; in kg of water per kg
     77 of dry air.
     78 .It
     79 .Va PABST :
     80 pressure in each grid cell in Pascal.
     81 .It
     82 .Va THT :
     83 potential temperature in each grid cell in Kelvin.
     84 .El
     85 .Pp
     86 The options are as follows:
     87 .Bl -tag -width Ds
     88 .It Fl c
     89 Advanced checks of the validity of the input
     90 .Ar netcdf
     91 file against
     92 .Nm
     93 prerequisites on netCDF data.
     94 Note that this option can significantly increase conversion time.
     95 .It Fl f
     96 Forces overwriting of
     97 .Ar output
     98 file.
     99 .It Fl h
    100 Display short help.
    101 .It Fl i Ar netcdf
    102 netCDF file to convert.
    103 .It Fl m Ar float_to_meter
    104 Scale factor to be applied to floating-point number
    105 .Li 1.0
    106 to convert it to meters.
    107 By default, it is set to
    108 .Li 1 .
    109 .It Fl o Ar output
    110 Output file.
    111 If not defined, data is written to standard output.
    112 .It Fl p Ar pagesize
    113 Page size in bytes on which htcp data will be aligned.
    114 It must be a power of 2 and greater than or equal to the size of a system page,
    115 which is the default value
    116 .Pq see Xr sysconf 3 .
    117 .It Fl q
    118 Writes nothing to the output.
    119 Can be used in conjunction with the
    120 .Fl c
    121 option to check only the validity of the input netCDF.
    122 .It Fl v
    123 Display the version number and exit.
    124 .El
    125 .Sh EXIT STATUS
    126 .Ex -std
    127 .Sh EXAMPLES
    128 Convert the netCDF
    129 .Pa clouds.nc
    130 file.
    131 The resulting
    132 .Xr htcp 5
    133 file is stored in the
    134 .Pa cloud.htcp
    135 file unless it already exists; in this case, an error is notified, the program
    136 stops and the
    137 .Pa cloud.htcp
    138 file remains unchanged:
    139 .Pp
    140 .Dl les2htcp -i clouds.nc -o clouds.htcp
    141 .Pp
    142 Converts netCDF file
    143 .Pa clouds_km.nc
    144 to
    145 .Xr htcp 5
    146 format.
    147 Use the
    148 .Fl f
    149 option to write the output file
    150 .Pa clouds.htcp
    151 even if it already exists.
    152 The input file to be converted has its spatial unit in kilo-meters, whereas the
    153 htcp file format assumes meters; use the
    154 .Fl m Ar 1000
    155 option to perform the conversion:
    156 .Pp
    157 .Dl les2htcp -i clouds_km.nc -m 1000 -o clouds.htcp
    158 .Pp
    159 Check that the netCDF file
    160 .Pa clouds.nc
    161 is a valid input file for
    162 .Nm .
    163 Use the
    164 .Fl q
    165 option to disable file conversion:
    166 .Pp
    167 .Dl les2htcp -c -i clouds.nc -q
    168 .Sh SEE ALSO
    169 .Xr htrdr 1 ,
    170 .Xr sysconf 3 ,
    171 .Xr htcp 5
    172 .Sh STANDARDS
    173 .Rs
    174 .%A Edward Hartnett
    175 .%D March 2011
    176 .%R ESDS-RFC-022v1
    177 .%T netCDF4/HDF5 File Format
    178 .Re
    179 .Sh HISTORY
    180 .Nm
    181 has been developed to generate cloud properties as input to the
    182 .Xr htrdr 1
    183 program.