diff --git a/definitions/grib1/boot.def b/definitions/grib1/boot.def index 9939f8291..4dd9e48e0 100644 --- a/definitions/grib1/boot.def +++ b/definitions/grib1/boot.def @@ -9,6 +9,8 @@ constant ieeeFloats = 0 : hidden, edition_specific; transient eps=0; +constant false=0 : hidden; +constant true=1 : hidden; constant two=1 : hidden; constant three=1 : hidden; constant eight=8 : hidden; diff --git a/definitions/grib1/grid_definition_spherical_harmonics.def b/definitions/grib1/grid_definition_spherical_harmonics.def index f82b5c7f3..eadb3224b 100644 --- a/definitions/grib1/grid_definition_spherical_harmonics.def +++ b/definitions/grib1/grid_definition_spherical_harmonics.def @@ -1,5 +1,5 @@ # GRID DEFINITION spherical harmonic coefficients (including rotated, stretched, or stretched and rotated) -constant isGridded = zero; +constant isGridded = false; # J - pentagonal resolution parameter unsigned[2] J : dump ; diff --git a/definitions/grib1/grid_rotation.def b/definitions/grib1/grid_rotation.def index cd05657fb..1f37d6ab3 100644 --- a/definitions/grib1/grid_rotation.def +++ b/definitions/grib1/grid_rotation.def @@ -8,5 +8,5 @@ meta geography.longitudeOfSouthernPoleInDegrees scale(longitudeOfSouthernPole ,o ibmfloat geography.angleOfRotationInDegrees : dump; -alias angleOfRotation =angleOfRotationInDegrees; -alias isRotatedGrid = one; +alias angleOfRotation = angleOfRotationInDegrees; +alias isRotatedGrid = true; diff --git a/definitions/grib1/scanning_mode.def b/definitions/grib1/scanning_mode.def index 477e63562..31a56e27d 100644 --- a/definitions/grib1/scanning_mode.def +++ b/definitions/grib1/scanning_mode.def @@ -1,4 +1,4 @@ -constant isGridded = one; +constant isGridded = true; # Scanning mode flags[1] scanningMode 'grib1/8.table' : edition_specific,no_copy; diff --git a/definitions/grib1/section.2.def b/definitions/grib1/section.2.def index 0bef0e818..d01dcc490 100644 --- a/definitions/grib1/section.2.def +++ b/definitions/grib1/section.2.def @@ -25,7 +25,7 @@ codetable[1] dataRepresentationType 'grib1/6.table' = 0; meta gridDefinitionDescription codetable_title(dataRepresentationType); # Grid definition (according to data representation type - octet 6 above) -alias isRotatedGrid=zero; +alias isRotatedGrid = false; if (dataRepresentationType < 192) { template dataRepresentation "grib1/grid_definition_[dataRepresentationType:l].def"; diff --git a/definitions/grib2/boot.def b/definitions/grib2/boot.def index 296dba179..a715b7ea7 100644 --- a/definitions/grib2/boot.def +++ b/definitions/grib2/boot.def @@ -13,6 +13,8 @@ constant tablesVersionLatestOfficial = 31 : edition_specific; # If this is different from the official version, then it is the pre-operational version constant tablesVersionLatest = 31 : edition_specific; +constant false = 0 : hidden; +constant true = 1 : hidden; constant million = 1000000 : hidden; constant grib2divider = 1000000; alias extraDimensionPresent=zero; diff --git a/definitions/grib2/section.1.def b/definitions/grib2/section.1.def index 719a9399c..88fd55b80 100644 --- a/definitions/grib2/section.1.def +++ b/definitions/grib2/section.1.def @@ -111,7 +111,7 @@ meta is_aerosol_optical g2_aerosol(productDefinitionTemplateNumber, stepType, 1 transient setCalendarId = 0 ; transient deleteCalendarId = 0 ; -alias calendarIdPresent = zero; +alias calendarIdPresent = false; if ( ((section1Length > 21) or setCalendarId > 0) and deleteCalendarId == 0) { alias calendarIdPresent = present; codetable[2] calendarIdentificationTemplateNumber ('1.5.table',masterDir,localDir) : dump,string_type,no_fail; diff --git a/definitions/grib2/section.2.def b/definitions/grib2/section.2.def index f6081b10b..cc7601295 100644 --- a/definitions/grib2/section.2.def +++ b/definitions/grib2/section.2.def @@ -14,7 +14,7 @@ transient addEmptySection2 = 0; if ( addEmptySection2 == 0 ) { if ( grib2LocalSectionPresent==1 or ( section2Length>5 or new() ) ) { - alias section2Used=one; + alias section2Used=true; if(productionStatusOfProcessedData == 8 || productionStatusOfProcessedData == 9) { # This for adding an expver other than prod/test to UERRA diff --git a/definitions/grib2/section.3.def b/definitions/grib2/section.3.def index d8ce26e6f..40f21e591 100644 --- a/definitions/grib2/section.3.def +++ b/definitions/grib2/section.3.def @@ -33,7 +33,7 @@ if(numberOfOctectsForNumberOfPoints == 0){ codetable[2] gridDefinitionTemplateNumber ('3.1.table',masterDir,localDir) =0 : dump,edition_specific; meta gridDefinitionDescription codetable_title(gridDefinitionTemplateNumber); -alias isRotatedGrid=zero; +alias isRotatedGrid = false; if (gridDefinitionTemplateNumber >= 32768) { template gridDefinitionSection "grib2/local/[centreForLocal]/template.3.[gridDefinitionTemplateNumber:l].def"; diff --git a/definitions/grib2/section.4.def b/definitions/grib2/section.4.def index 1f646f221..ca9349e73 100644 --- a/definitions/grib2/section.4.def +++ b/definitions/grib2/section.4.def @@ -20,7 +20,7 @@ alias numberOfVerticalGridDescriptors=NV ; transient neitherPresent = 0; if (centre==7 || centre==46) { - alias disableGrib1LocalSection=one; + alias disableGrib1LocalSection=true; } concept datasetForLocal(unknown) { diff --git a/definitions/grib2/template.3.10.def b/definitions/grib2/template.3.10.def index fefc41ba4..df1821add 100644 --- a/definitions/grib2/template.3.10.def +++ b/definitions/grib2/template.3.10.def @@ -3,7 +3,7 @@ # TEMPLATE 3.10, Mercator include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; unsigned[4] Ni : dump; alias numberOfPointsAlongAParallel = Ni; diff --git a/definitions/grib2/template.3.100.def b/definitions/grib2/template.3.100.def index 8b1fe16a3..76881b671 100644 --- a/definitions/grib2/template.3.100.def +++ b/definitions/grib2/template.3.100.def @@ -1,7 +1,7 @@ # (C) Copyright 2005- ECMWF. # TEMPLATE 3.100, Triangular grid based on an icosahedron (see Attachment I.2-GRIB-Att.) -constant isGridded = one; +constant isGridded = true; # n2 - exponent of 2 for the number of intervals on main triangle sides unsigned[1] n2 : dump ; diff --git a/definitions/grib2/template.3.1000.def b/definitions/grib2/template.3.1000.def index 407fc16e7..eda324224 100644 --- a/definitions/grib2/template.3.1000.def +++ b/definitions/grib2/template.3.1000.def @@ -3,7 +3,7 @@ # TEMPLATE 3.1000, Cross-section grid, with points equally spaced on the horizontal include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; # Number of horizontal points unsigned[4] numberOfHorizontalPoints : dump ; diff --git a/definitions/grib2/template.3.101.def b/definitions/grib2/template.3.101.def index 65d27a22f..fb8cb71f1 100644 --- a/definitions/grib2/template.3.101.def +++ b/definitions/grib2/template.3.101.def @@ -2,7 +2,7 @@ # TEMPLATE 3.101, General Unstructured Grid -constant isGridded = one; +constant isGridded = true; codetable[1] shapeOfTheEarth ('3.2.table',masterDir,localDir) : dump; diff --git a/definitions/grib2/template.3.110.def b/definitions/grib2/template.3.110.def index dae4a9263..ee332ca7a 100644 --- a/definitions/grib2/template.3.110.def +++ b/definitions/grib2/template.3.110.def @@ -3,7 +3,7 @@ # TEMPLATE 3.110, Equatorial azimuthal equidistant projection include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; # Nx - number of points along X-axis unsigned[4] numberOfPointsAlongXAxis : dump; diff --git a/definitions/grib2/template.3.1100.def b/definitions/grib2/template.3.1100.def index f9bdbef8b..e9c0b75f7 100644 --- a/definitions/grib2/template.3.1100.def +++ b/definitions/grib2/template.3.1100.def @@ -3,7 +3,7 @@ # TEMPLATE 3.1100, Hovmoller diagram grid with points equally spaced on the horizontal include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; # Number of horizontal points unsigned[5] numberOfHorizontalPoints : dump ; diff --git a/definitions/grib2/template.3.12.def b/definitions/grib2/template.3.12.def index d317d6ca8..c96177bf8 100644 --- a/definitions/grib2/template.3.12.def +++ b/definitions/grib2/template.3.12.def @@ -3,7 +3,7 @@ # TEMPLATE 3.12, Transverse Mercator include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; unsigned[4] Ni : dump; alias numberOfPointsAlongAParallel = Ni; diff --git a/definitions/grib2/template.3.120.def b/definitions/grib2/template.3.120.def index 19edb2c6b..34e77d345 100644 --- a/definitions/grib2/template.3.120.def +++ b/definitions/grib2/template.3.120.def @@ -2,7 +2,7 @@ # TEMPLATE 3.120, Azimuth-range projection -constant isGridded = one; +constant isGridded = true; # Nb - number of data bins along radials (A data bin is a data point representing the volume centred on it) unsigned[4] numberOfDataBinsAlongRadials; diff --git a/definitions/grib2/template.3.1200.def b/definitions/grib2/template.3.1200.def index 93ebe91fb..0b7e234ae 100644 --- a/definitions/grib2/template.3.1200.def +++ b/definitions/grib2/template.3.1200.def @@ -1,7 +1,7 @@ # (C) Copyright 2005- ECMWF. # TEMPLATE 3.1200, Time section grid -constant isGridded = one; +constant isGridded = true; # NT - Number of time steps unsigned[4] numberOfTimeSteps : dump; diff --git a/definitions/grib2/template.3.130.def b/definitions/grib2/template.3.130.def index 168080b47..960a65b82 100644 --- a/definitions/grib2/template.3.130.def +++ b/definitions/grib2/template.3.130.def @@ -2,7 +2,7 @@ # TEMPLATE 3.130, Irregular Latitude/longitude grid -constant isGridded = one; +constant isGridded = true; # Note: This template is deprecated. diff --git a/definitions/grib2/template.3.140.def b/definitions/grib2/template.3.140.def index 83ece859c..59e3830a2 100644 --- a/definitions/grib2/template.3.140.def +++ b/definitions/grib2/template.3.140.def @@ -3,7 +3,7 @@ # TEMPLATE 3.140, Lambert azimuthal equal area projection include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; # Nx - number of points along X-axis unsigned[4] numberOfPointsAlongXAxis : dump; diff --git a/definitions/grib2/template.3.20.def b/definitions/grib2/template.3.20.def index fd1e33b7a..fa596d063 100644 --- a/definitions/grib2/template.3.20.def +++ b/definitions/grib2/template.3.20.def @@ -3,7 +3,7 @@ # TEMPLATE 3.20, Polar stereographic projection include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; # Nx - number of points along X-axis unsigned[4] Nx : dump; diff --git a/definitions/grib2/template.3.30.def b/definitions/grib2/template.3.30.def index 6e9466426..387009b85 100644 --- a/definitions/grib2/template.3.30.def +++ b/definitions/grib2/template.3.30.def @@ -3,7 +3,7 @@ # TEMPLATE 3.30, Lambert conformal include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; unsigned[4] Nx : dump; alias Ni = Nx; diff --git a/definitions/grib2/template.3.31.def b/definitions/grib2/template.3.31.def index 0db29f7a4..e10d53b99 100644 --- a/definitions/grib2/template.3.31.def +++ b/definitions/grib2/template.3.31.def @@ -3,7 +3,7 @@ # TEMPLATE 3.31, Albers equal area include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; # Nx - number of points along the X-axis unsigned[4] Nx : dump; diff --git a/definitions/grib2/template.3.90.def b/definitions/grib2/template.3.90.def index 00f359383..62db324da 100644 --- a/definitions/grib2/template.3.90.def +++ b/definitions/grib2/template.3.90.def @@ -3,7 +3,7 @@ # TEMPLATE 3.90, Space view perspective or orthographic include "grib2/template.3.shape_of_the_earth.def"; -constant isGridded = one; +constant isGridded = true; unsigned[4] Nx : dump; alias Ni = Nx; diff --git a/definitions/grib2/template.3.bf.def b/definitions/grib2/template.3.bf.def index 7274dedcd..a70991aa5 100644 --- a/definitions/grib2/template.3.bf.def +++ b/definitions/grib2/template.3.bf.def @@ -1,6 +1,6 @@ label "BiFourier coefficients"; constant biFourierCoefficients=1; -constant isGridded = one; +constant isGridded = true; codetable[1] spectralType ('3.6.table',masterDir,localDir) = 2 : no_copy; alias spectralDataRepresentationType=spectralType; diff --git a/definitions/grib2/template.3.grid.def b/definitions/grib2/template.3.grid.def index 28070d542..2a317ea82 100644 --- a/definitions/grib2/template.3.grid.def +++ b/definitions/grib2/template.3.grid.def @@ -1,6 +1,6 @@ # (C) Copyright 2005- ECMWF. -constant isGridded = one; +constant isGridded = true; unsigned[4] Ni : can_be_missing,dump; alias numberOfPointsAlongAParallel=Ni; diff --git a/definitions/grib2/template.3.healpix.def b/definitions/grib2/template.3.healpix.def index 47e1a63f8..bd59c3246 100644 --- a/definitions/grib2/template.3.healpix.def +++ b/definitions/grib2/template.3.healpix.def @@ -2,7 +2,7 @@ # See https://healpix.jpl.nasa.gov/pdf/intro.pdf -constant isGridded = one; +constant isGridded = true; # Number of grid points along one side of one of the 12 base resolution pixels (>=1) # The number of data points should be = 12 * Nside * Nside diff --git a/definitions/grib2/template.3.rotation.def b/definitions/grib2/template.3.rotation.def index 33c319735..5e7b67d4f 100644 --- a/definitions/grib2/template.3.rotation.def +++ b/definitions/grib2/template.3.rotation.def @@ -18,4 +18,4 @@ alias geography.angleOfRotationInDegrees=angleOfRotation; alias angleOfRotationOfProjection=angleOfRotation; -alias isRotatedGrid=one; +alias isRotatedGrid = true; diff --git a/definitions/grib2/template.3.shape_of_the_earth.def b/definitions/grib2/template.3.shape_of_the_earth.def index 6bd4deceb..fcee8e659 100644 --- a/definitions/grib2/template.3.shape_of_the_earth.def +++ b/definitions/grib2/template.3.shape_of_the_earth.def @@ -24,13 +24,13 @@ alias scaleFactorOfMinorAxisOfOblateSpheroidEarth=scaleFactorOfEarthMinorAxis ; unsigned[4] scaledValueOfEarthMinorAxis = missing(): can_be_missing, edition_specific; alias scaledValueOfMinorAxisOfOblateSpheroidEarth=scaledValueOfEarthMinorAxis; -alias earthIsOblate=one; +alias earthIsOblate = true; _if (shapeOfTheEarth == 0) { transient radius=6367470; alias radiusOfTheEarth=radius; alias radiusInMetres=radius; - alias earthIsOblate=zero; + alias earthIsOblate=false; } _if (shapeOfTheEarth == 1){ meta radius from_scale_factor_scaled_value( @@ -38,20 +38,20 @@ _if (shapeOfTheEarth == 1){ scaledValueOfRadiusOfSphericalEarth); alias radiusOfTheEarth=radius; alias radiusInMetres=radius; - alias earthIsOblate=zero; + alias earthIsOblate=false; } _if (shapeOfTheEarth == 6){ transient radius=6371229; alias radiusOfTheEarth=radius; alias radiusInMetres=radius; - alias earthIsOblate=zero; + alias earthIsOblate=false; } _if (shapeOfTheEarth == 8){ transient radius=6371200; alias radiusOfTheEarth=radius; alias radiusInMetres=radius; - alias earthIsOblate=zero; + alias earthIsOblate=false; } diff --git a/definitions/grib2/template.3.spherical_harmonics.def b/definitions/grib2/template.3.spherical_harmonics.def index 2adbe405b..0a295c2f7 100644 --- a/definitions/grib2/template.3.spherical_harmonics.def +++ b/definitions/grib2/template.3.spherical_harmonics.def @@ -26,4 +26,4 @@ alias spectralDataRepresentationType=spectralType; codetable[1] spectralMode ('3.7.table',masterDir,localDir) = 1 : no_copy; alias spectralDataRepresentationMode=spectralMode; -constant isGridded = zero; +constant isGridded = false; diff --git a/definitions/grib2/template.4.horizontal.def b/definitions/grib2/template.4.horizontal.def index 67a1909da..db0913dbc 100644 --- a/definitions/grib2/template.4.horizontal.def +++ b/definitions/grib2/template.4.horizontal.def @@ -54,10 +54,10 @@ alias vertical.level=level; alias vertical.bottomLevel=bottomLevel; alias vertical.topLevel=topLevel; -alias extraDim=zero; +alias extraDim=false; if (defined(extraDimensionPresent)) { if (extraDimensionPresent) { - alias extraDim=one; + alias extraDim=true; } } if (extraDim) {