Grib1 To Grib2 Converter Money

Posted By admin On 26.01.20
Grib1 To Grib2 Converter Money Rating: 4,7/5 2082 reviews

Guide to GRIB PART II A GUIDE TO THE CODE FORM FM 92-IX Ext. GRIB Edition 1 TABLE OF CONTENTS The World Meteorological Organization (WMO) Commission for Basic Systems (CBS) Extraordinary Meeting Number VIII (1985) approved a general purpose, bit-oriented data exchange format, designated FM 92-VIII Ext.

GRIB (GRIdded Binary). It is an efficient vehicle for transmitting large volumes of gridded data to automated centers over high-speed telecommunication lines using modern protocols. By packing information into the GRIB code, messages (or records - the terms are synonymous in this context) can be made more compact than character oriented bulletins, which will produce faster computer-to-computer transmissions.

GRIB can equally well serve as a data storage format, generating the same efficiencies relative to information storage and retrieval devices. Changes and extensions to GRIB were approved at the regular meeting of the WMO/CBS in February 1988; additional changes were introduced at the CBS/WGDM/Sub-Group on Data Representation (SGDR) meetings in May 1989 and in October 1990. The 1990 changes were of such structural magnitude as to require a new Edition of GRIB, Edition 1, which this document describes. The Sub-Group made further augmentations and interpretations on Data Representation and Codes (SGDRC) in September 1993, with approval by the WGDM in February 1994. These changes did not result in a new Edition to GRIB, but did change some of the Tables, resulting a new Version number for them.

This brings us now to Table Version 2. The changes from Version 1 were mainly additions of new parameters or more precise definition of existing ones. It is not anticipated that there will be any large-scale structural changes to GRIB for at least four to five years, or more. The SGDRC is undertaking a thorough review of the present and future requirements that GRIB is supposed to satisfy. The plan is to design a major revision of GRIB capable of accommodating these requirements and more, without 'straining' the structure of the data representation form. Some things are getting a little strained even now. Note: the Edition number is placed in the same location, relative to the start of the GRIB message, for all Editions.

Thus, decoding programs can detect which Edition was used to construct a particular GRIB message and behave accordingly. This is useful for archives of messages encoded in earlier Editions or during transition periods. Of course, this requires that data centers retain copies of older editions of the code, and older versions of the parameter tables.

Each GRIB record intended for either transmission or storage contains a single parameter with values located at an array of grid points, or represented as a set of spectral coefficients, for a single level (or layer), encoded as a continuous bit stream. Logical divisions of the record are designated as 'sections', each of which provides control information and/or data. A GRIB record consists of six sections, two of which are optional: (0) Indicator Section (1) Product Definition Section (PDS) (2) Grid Description Section (GDS) - optional (3) Bit Map Section (BMS) - optional (4) Binary Data Section (BDS) (5) '7777' (ASCII Characters) Although the Grid Description Section is indicated as optional, it is highly desirable that it be included in all messages. That way there will be no question about just what is the 'correct' geographical grid for a particular field. Most centers require bulletin headers to enable them to receive, identify, and switch messages.

The standard WMO abbreviated heading for GRIB is described in Appendix A. In this documentation, certain symbols are used to clarify the contents of octets (groups of eight consecutive binary bits). If unadorned letters are used, they are symbolic and their meanings are described in the text; a decimal number is simply printed as is; a character or string of characters is represented inside single quote marks. International Alphabet No. 5, which is identical in its essential elements to the U.S. National Standard 7-bit ASCII, is used for character representation in the GRIB code.

Octets are numbered consecutively from the start of each section; bits within an octet are also numbered from left (the most significant bit) to right (the least significant bit). Thus an octet with bit 8 set to the value 1 would have the integer value 1; bit 7 set to one would have a value of 2, etc. The numbering of Tables in the following text corresponds to the description of GRIB in the WMO Manual on Codes. Some additional tables not found in the WMO Manual are indicated by letters. These, generally, contain information unique to a particular processing center. A caveat: The Official International Documentation for GRIB is the just referenced Manual on Codes. This document is, in part, intended to be a guide to the use of GRIB and may not include all of the features currently found in the Manual.

The features described here are intended to be a completely consistent sub-set of the full WMO documentation; if there are any discrepancies the Manual on Codes is the final authority. DATA PACKING METHODS The code form represents numeric data as a series of binary digits (bits). Such data representation is independent of any particular machine representation; by convention data lengths are measured in octets. Data are coded as binary integers using the minimum number of bits required for the desired precision. Numeric values, with units as shown in Table 2, may first be scaled by a power of ten to achieve an appropriate decimal precision, a reference value is subtracted from them to reduce redundancy and eliminate negative values, and they may then be further scaled by a power of two to pack them into a pre-selected word length.

The two scaling operations are independent; which, or both, are used in any given case depends upon choices made as to the method of packing. The representation of a single value is such that: Y x 10 D = R + (X x 2 E) Where Y = original or unpacked value; units as in Table 2; D = decimal scale factor, to achieve desired precision (sign bit, followed by a 15-bit integer); R = reference value (32 bits); X = internal value (No. Of bits varies for each record); E = binary scale factor for variable bit word length packing (sign bit, followed by a 15-bit integer). The reference value (R) is the minimum value of the (possibly) decimally scaled data that is being encoded. R is placed in the Binary Data Section in four octets as a single precision floating-point number: sAAAAAAA BBBBBBBB BBBBBBBB BBBBBBBB where s = sign bit, encoded as 0 = positive, 1 = negative A = 7-bit binary integer, the characteristic B = 24-bit binary integer, the mantissa. The appropriate formula to recover the value of R is: R = (-1) s x 2 (-24) x B x 16 (A-64) This formula is the standard IBM representation for a single precision (real) floating point number.

(Consideration is being given to using the IEEE floating point representation in the future, in a later Edition of GRIB.) If second order (or 'complex') packing is used (see the description of that later on) the internal value, X, will be made up of two values, a 'local minimum value', Xi, and a 'second order packed value', Xj. There will be one Xj for each grid point and a variable number of Xi values. This will all become clear later on when we get to the description of second-order packing. What follows is a description, slightly simplified, of the process that one would go through to pack a (meteorological) field into a GRIB message, using 'simple packing'.

It includes some explanations of why certain steps are taken, some of the consequences, and what choices have to be made. Some of the choices are interrelated; the relationships should be clear when the explanation is done.

The additional features of complex or 'second order' packing will be dealt with in a later section. Give that a full field is available, the first step, if necessary, is to convert the units of the parameter into those shown in Table 2, the SI standard units, also known as the mks system.

Some of the units may seem a little peculiar (kg/m 2, for example, for precipitation - 1 kg/m 2 is equivalent to a water depth of 1 mm); others may seem inappropriate (Pa for pressure, for example, implies substantially greater precision than is typical in meteorological usage; inverse seconds are not nearly precise enough for divergence and vorticity) but they are all self consistent. The precision of the parameters, as actually packed in a message, can be set to any desired degree through the appropriate use of the power-of-10 ('D') scaling and the power-of-2 ('E') scaling. Just how this comes about will be described momentarily. At this point there is a choice to be made.

If it is desired to use a pre-selected bit word length for the packed variables, then just proceed on to the next step. However, if a variable bit word length is to be used, where the word length is adjusted to accommodate the data values, then it is necessary to undertake the power-of-ten scaling. The D value should be selected such that, when the original data, in the SI units of Table 2, is multiplied by 10 D, the integer part of the result will have enough precision to contain all the appropriate information of the variable. Anticipating things a little bit, the (scaled) value will be rounded to an integer as a part of the packing process; thus the 'significant part' of the value of the variable has to be moved to the left of the decimal point prior to the rounding. Temperature might be scaled with D=1, thus changing the units to deci-degrees; pressure, on the other hand, might be scaled with D=-2, thus actually reducing the precision to hectoPascals (mb), a more reasonable meteorological precision; vorticity would be scaled up by D=8, and so on. The second step in the packing operation is to scan through the field, which may or may not have been 'D-scaled' at this point, find the minimum value of the parameter, and subtract that minimum - the reference value, R - from all the data points, leaving a residual of non-negative numbers.

This step has two benefits. The first of these is convenience - making all the data points non-negative bypasses problems with different computer hardware that represent negatives in various ways: 1's complement, 2's complement, signed positive integers, whatever. The GRIB message is rendered just that much more machine independent by being non-negative throughout. The second benefit is more consequential: it can result in a substantial compression of the bulletin size without any loss of information content. If a field has an appreciable bias away from zero, the residuals formed by the minimum removal operation will all be much smaller numbers than otherwise.

Thus they will need fewer bits to contain them when they are, eventually, packed as integers. The third step is simply to scan through the field of residuals and find the maximum value.

At this point another choice must be made, similar to the one made previously. This time, if a variable bit word length is to be used, then it is necessary to calculate how many bits (per word or per data grid point) are going to be needed to contain that largest data value, when the latter has been rounded to an integer.

Recall that at the previous decision point, the variables were power-of-ten ('D') scaled such that a rounding operation will preserve all the significant part of the information. Discovering how many bits are needed is a simple scan through a table of powers of two, of course. The power-of-two-scaling is not employed and E is set equal to 0. Then go on to the fourth step. If, alternatively, it is desired to use a pre-selected bit word length for the packed variables, the data must now be scaled, this time by a power of two (the 'E' scaling), sufficient to either reduce the maximum value down to just fit into the available number of bits, or enlarge the value to just fit. This latter step takes care of the problem of small numbers where the precision is all in the fractional part of the number.

How much precision is retained, for the eventual rounding, is a function of the pre-selected bit word length and the 'typical' range, or maximum value with the minimum removed, of the particular variable. The choice of bit word length, which is made ahead of time, must be made with full knowledge of the characteristics of the particular variable that is to be packed and a prior assumption of how much precision needs to be retained for the largest likely value. The fourth step is to round all the values to integers, now that they have all been scaled to appropriate units, and pack them in the specified bit length words. The last step is then to set up the various identification fields and put the GRIB bulletin in proper form. We shall turn to this 'proper form' in the next section. We have ended up with two alternate ways to construct a GRIB messages: a fixed bit word length method and a variable bit word length method.

What are the relative advantages or disadvantages, or at least the differences, of one with respect to the other? Message length: the fixed word length bulletins are always the same length, for a given parameter; the variable word length bulletins are, naturally, variable. The variation is driven by the range of the value of the parameter over the field (or the maximum value) which can change from day to day. Whether variations in message length is a problem or not depends on the computer systems used to work with the GRIB records. Precision: The variable word length bulletins have a fixed and unchanging precision, determined by the 'D' scaling. This assures that the same information content is available day after day. It is straightforward to change the precision in a familiar manner, that is, simply by orders of magnitude, just by altering the D value.

This comes at a cost, of course; increasing the precision by a power of 10 adds about 3.3 bits (average) to each data point in the message. The fixed word length bulletins show a variable precision which is case by case data driven and is determined by the 'E' (power-of-two) scaling that was used to fit the numbers into the available space. This can happen even with the same data, on the same date, but at adjacent grid areas. If one area shows a low variability and the neighboring one a high variability such that a different power-of-two scaling is needed in the two areas, then, unfortunately, the values on a common boundary will not be exactly equal after they are unpacked. This can be disconcerting and a cause for confusion. It will not happen if D-scaling (only) is employed. On the other hand, the variable precision can be viewed as a strength: a data field with a low variability will be encoded at a higher precision, thus preserving the character of the field; a high variability field will be represented with less precision, but that is not a problem as the small, and possibly lost, variations will not matter in the presence of the large ones.

The precision of the encoded field can be increased by adding bits to the fixed word length, but the degree of change (a power of 2 for each bit) may not be as easy to deal with (or explain to people) as the simple order of magnitude change afforded by the 'D' scaling method. No matter which packing method was employed, a proper GRIB decoding program, that took account of the transmitted values of both 'D' and 'E', would return the correct unpacked numbers, regardless of which packing method was employed.

It would be transparent to the user except for the questions of precision outlined above. FORM With the exception of the first four octets of the Indicator Section, and the End Section, all octets contain binary values. All sections contain an even number of octets; the variable length sections are padded with zero values as necessary.

These extra bits must be accounted for in finding one's way through the sections; their content should be ignored.: THE INDICATOR SECTION (IS) The indicator section serves to: identify the start of the record in a human readable form, indicate the total length of the message, and indicate the Edition number of GRIB used to construct or encode the message. The section is always eight octets long.

IS Content 1-4 'GRIB' (Coded CCITT-ITA No. 5) (ASCII); 5-7 Total length, in octets, of GRIB message(including Sections 0 & 5); 8 Edition number - currently 1: THE PRODUCT DEFINITION SECTION (PDS). The PDS contains indicators for the Parameter table Version, the originating center, the numerical model (or 'generating process') that created the data, the geographical area covered by the data, the parameter itself, the values for the appropriate vertical level or layer where the data reside, the decimal scale factor, and date/time information. The PDS is normally 28 octets long but it may be longer if an originating center chooses to make it so. Users of GRIB messages are strongly urged to use the length-of-section portion of the PDS to determine where the next section begins.

Never assume a fixed octet length in this, or any other, section. PDS Content 1 - 3 Length in octets of the Product Definition Section 4 Parameter Table Version number. Currently Version 2 for international exchange. Parameter table version numbers 128-254 are reserved for local use. 5 Identification of center (Table 0 - Part 1) 6 Generating process ID number (allocated by the originating center; See Table A) 7 Grid Identification (geographical location and area; See Table B) 8 Flag specifying the presence or absence of a GDS or a BMS (See Table 1) 9 Indicator of parameter and units (Table 2) 10 Indicator of type of level or layer (See Tables 3 & 3a) 11-12 Height, pressure, etc. Of the level or layer (See Table 3) 13 14 15 16 17 Year of century Month of year Day of month Hour of day Minute of hour Initial (or Reference) time of forecast - UTC or for averaging or accumulation of / analyses 18 Forecast time unit (see Table 4) 19 P1 - Period of time (Number of time units) (0 for analysis or initialized analysis.) Units of time given by content of octet 18. 20 P2 - Period of time (Number of time units) or Time interval between successive analyses, successive initialized analyses, or forecasts, undergoing averaging or accumulation.

Units given by octet 18. 21 Time range indicator (See Table 5) 22-23 Number included in average, when octet 21 (Table 5) indicates an average or accumulation; otherwise set to zero. 24 Number Missing from averages or accumulations. 25 Century of Initial (Reference) time (=20 until Jan. 1, 2001) 26 Identification of sub-center (Table 0 - Part 2) 27-28 The decimal scale factor D. A negative value is indicated by setting the high order bit (bit No.

1) in octet 27 to 1 (on). 29-40 Reserved (need not be present) 41. Reserved for originating center use.

Note: Octet 8 may indicate the presence of the Grid Description Section (GDS) even though octet 7 specifies a predefined grid. In this case the GDS must describe that grid -this device serves as a mechanism for transmitting new 'predefined' grids to users prior to their formal publication in this or the official WMO documentation. It is, however, the desired practice to always include the GDS in GRIB bulletins.

Another Note: The use of octet 26 to indicate a 'sub-center' is not (yet) an officially sanctioned WMO practice. The Manual indicates the octet is to be 'reserved', and set to 0. The use arises out of an upcoming change in the Manual in which the 'originating centers' for both GRIB and BUFR (FM 94) will reference a single common table. The difficulty is that BUFR has two octets available for an originating center number while GRIB has only one.

Unit

The compromise solution is to allow the use of octet 26 as the 'second' octet for GRIB, but only in a national context. The WMO will coordinate the assignment of the numbers for octet 5 for national and international centers (for both GRIB and BUFR), while each national center will then be free to assign sub-center numbers at will to be placed in the octet 26. A zero value in octet 26 will serve as the default indicating that there is no sub-center associated with a particular center. Table 0, in this document, shows, in Part 1, a selection of the WMO recognized originating centers (those that are currently active) as would be found in octet 5. TABLES FOR THE PDS TABLE 0 - Part 1 NATIONAL/INTERNATIONAL ORIGINATING CENTERS (Assigned By The WMO) (PDS Octet 5) Value Contents 07 US Weather Service - National Met. Center 08 US Weather Service - NWS Telecomms Gateway 09 US Weather Service - Field Stations 34 Japanese Meteorological Agency - Tokyo 52 National Hurricane Center, Miami 54 Canadian Meteorological Service - Montreal 57 U.S.

Air Force - Global Weather Center 58 US Navy - Fleet Numerical Oceanography Center 59 NOAA Forecast Systems Lab, Boulder CO 74 U.K. Met Office - Bracknell 85 French Weather Service - Toulouse 97 European Space Agency (ESA) 98 European Center for Medium-Range Weather Forecasts - Reading 99 DeBilt, Netherlands TABLE 0 - Part 2 NATIONAL SUB-CENTERS (Assigned By The Nation) (PDS Octet 26) National sub-centers, if any, would be found here. TABLE A.Generating Process or Model (PDS Octet 6) VALUE MODEL These values and model ('generating process') numbers would be supplied by the individual centers. GRID IDENTIFICATION (PDS Octet 7) Various National Grids would be identified here by the Center International exchange grids are included here.

VALUE GRID 21-26 International Exchange grids - see below 37-44 Eight lat-long 1.25 x 1.25 'thinned' grids, covering the globe by octants of 3447 points. Full GRIB specifications below. For WAFC, ICAO, and International exchange. 61-64 International Exchange grids - see below. Octets Variable & Value 7-8 Ni = all bits set to 1 (missing) 9-10 Nj = 73 GRID: 37 38 39 40 41 42 43 44 11-13 La1 = 0 0 0 0 90S 90S 90S 90S 14-16 Lo1 = 330 60 150 240 330 60 150 240 17 Resolution & Component Flag = 10000000 (binary) GRID: 37 38 39 40 41 42 43 44 18-20 La2 = 90N 90N 90N 90N 0 0 0 0 21-23 Lo2 = 60 150 240 330 60 150 240 330 24-25 Di = all bits set to 1 (missing) 26-27 Dj = 1.25 deg 28 Scan Mode = 01000000 (binary) 29-32 Set to 0 (unused) Note that the scanning direction is from the bottom (south edge) to the top of the octant grids, regardless of the hemisphere.

Thus in the northern hemisphere the first 73 data points (in the BDS) will be the equatorial values and the last two will be the polar values. The PL counts in the GDS octets 33-178 will, of course, indicate contain these numbers. In the southern hemisphere, the first two data points will be the south pole values, and the last 73 points will be the equatorial values. Octets 33-34 in the GDS will contain '2', octets 35-36 will contain a '3', and so on to octets 177-178 which will contain '73'. FLAG FOR GDS OR BMS (PDS Octet 8) The bit flag indicates the omission or inclusion of the Grid Description and/or Bit Map Sections. BIT VALUE MEANING 1 0 GDS Omitted 1 GDS Included 2 0 BMS Omitted 1 BMS Included 3-8 0 reserved TABLE 2. VALUE TIME UNIT 0 minute 1 hour 2 day 3 month 4 year 5 decade 6 normal (30 years) 7 century 8-253 reserved 254 second TABLE 5.

TIME RANGE INDICATOR (PDS Octet 21) VALUE MEANING 0 Forecast product valid at reference time + P1 P10), or Uninitialized analysis product for reference time (P1=0). Or Image product for reference time (P1=0) 1 Initialized analysis product for reference time (P1=0). 2 Product with a valid time ranging between reference time + P1 and reference time + P2 3 Average(reference time + P1 to reference time + P2) 4 Accumulation (reference time + P1 to reference time + P2) product considered valid at reference time + P2 5 Difference(reference time + P2 minus reference time + P1) product considered valid at reference time + P2 6-9 reserved 10 P1 occupies octets 19 and 20; product valid at reference time + P1 11-50 reserved 51 Climatological Mean Value: multiple year averages of quantities which are themselves means over some period of time (P2) less than a year. The reference time (R) indicates the date and time of the start of a period of time, given by R to R + P2, over which a mean is formed; N indicates the number of such period-means that are averaged together to form the climatological value, assuming that the N period-mean fields are separated by one year. The reference time indicates the start of the N-year climatology.

N is given in octets 22-23 of the PDS. If P1 = 0 then the data averaged in the basic interval P2 are assumed to be continuous, i.e., all available data are simply averaged together. If P1 = 1 (the units of time - octet 18, code table 4 - are not relevant here) then the data averaged together in the basic interval P2 are valid only at the time (hour, minute) given in the reference time, for all the days included in the P2 period. The units of P2 are given by the contents of octet 18 and Table 4.

52-112 reserved 113 Average of N forecasts (or initialized analyses); each product has forecast period of P1 (P1=0 for initialized analyses); products have reference times at intervals of P2, beginning at the given reference time. 114 Accumulation of N forecasts (or initialized analyses); each product has forecast period of P1 (P1=0 for initialized analyses); products have reference times at intervals of P2, beginning at the given reference time.

115 Average of N forecasts, all with the same reference time; the first has a forecast period of P1, the remaining forecasts follow at intervals of P2. 116 Accumulation of N forecasts, all with the same reference time; the first has a forecast period of P1, the remaining follow at intervals of P2. 117 Average of N forecasts, the first has a period of P1, the subsequent ones have forecast periods reduced from the previous one by an interval of P2; the reference time for the first is given in octets 13-17, the subsequent ones have reference times increased from the previous one by an interval of P2. Thus all the forecasts have the same valid time, given by the initial reference time + P1. 118 Temporal variance, or covariance, of N initialized analyses; each product has forecast period P1=0; products have reference times at intervals of P2, beginning at the given reference time.

119 -122 reserved 123 Average of N uninitialized analyses, starting at the reference time, at intervals of P2. 124 Accumulation of N uninitialized analyses, starting at the reference time, at intervals of P2.

125-254 reserved NOTES:. For analysis products, or the first of a series of analysis products, the reference time (octets 13 to 17) indicates the valid time.

For forecast products, or the first of a series of forecast products, the reference time indicates the valid time of the analysis upon which the (first) forecast is based. Initialized analysis products are allocated numbers distinct from those allocated to uninitialized analysis products. A value of 10 allows the period of a forecast to be extended over two octets; this accommodates extended range forecasts. Where products or a series of products are averaged or accumulated, the number involved is to be represented in octets 22-23 of Section 1, while any number missing is to be represented in octet 24. Forecasts of the accumulation or difference of some quantity (e.g. Quantitative precipitation forecasts), indicated by values of 4 or 5 in octet 21, have a product valid time given by the reference time + P2; the period of accumulation, or difference, can be calculated as P2 - P1. A few examples may help to clarify the use of Table 5: For analysis products P1 is zero and the time range indicator is also zero; for initialized products (sometimes called 'zero hour forecasts') P1 is zero, but octet 21 is set to 1.

Grib2

For forecasts, typically, P1 contains the number of hours of the forecast (the unit indicator given in octet 18 would be 1) and octet 21 contains a zero. Value 51 allows for the identification of the most common climatological entities.

With P1=0, it could represent (or identify) the multiple year climatology of anything from daily means (or less) to semi-annual means (or more, up to a full year). The assumption is that all the available values within the basic period P2 are averaged together. (An 'annual mean climatology' would just be an average over the total climatological period - Table 5, entry 3.) P1=1 allows for a diurnal sub-stratification of the data within the P2 period, such as 30-year climatology of February mean 00Z temperature starting at a date certain, or all the 12Z surface radiation fluxes averaged for all the days in a season, or whatever.

If other sub-stratifications are appropriate they could be identified by different values of P1. No others have been proposed at this time. Value 115 would be used, typically, for multiple day mean forecasts, all derived from the same initial conditions. Value 117 would be used, typically, for Monte Carlo type calculations: many forecasts valid at the same time from different initial (reference) times. Averages, accumulations, and differences get a somewhat specialized treatment. If octet 21 (Table 5) has a value between 2 and 5 (inclusive) then the reference time + P1 is the initial date/time and the reference time + P2 is the final date/time of the period over which averaging or accumulation takes place.

If, however, octet 21 has a value of 113, 114, 115, 116, 117, 118, 123, or 124 then P2 specifies the time interval between each of the fields (or the forecast initial times) that have been averaged or accumulated. These latter values of octet 21 require the quantities averaged to be equally separated in time; the former values, 3 and 4 in particular, allow for irregular or unspecified intervals of time between the fields that are averaged or accumulated.: GRID DESCRIPTION SECTION (GDS) The purpose of the (optional) GDS is to provide a grid description for grids not defined by number in Table 3. Octet no.GDS Content 1 - 3 Length in octets of the Grid Description Section 4 NV, the number of vertical coordinate parameters 5 PV, the location (octet number) of the list of vertical coordinate parameters, if present or PL, the location (octet number) of the list of numbers of points in each row (when no vertical parameters are present), if present or 255 (all bits set to 1) if neither are present 6 Data representation type (See Table 6) 7 - 32 Grid description, according to data representation type, except Lambert, Mercator or Space View.

Or 7 - 42 Grid description for Lambert or Mercator grid or 7 - 44 Grid description for Space View perspective grid PV List of vertical coordinate parameters (length = NV x 4 octets); if present, then PL = 4 x NV + PV PL List of numbers of points in each row, used for quasi-regular grids (length = NROWS x 2 octets, where NROWS is the total number of rows defined within the grid description) Note: NV and PV relate to features of GRIB not, at present, in use in international exchange. See the WMO Manual on Codes for the descriptions of those features. PL is used for 'quasi-regular' or 'thinned' grids; e.g., a lat/lon grid where the number of points in each row is reduced as one moves poleward from the equator. The reduction usually follows some mathematical formula involving the cosine of the latitude, to generate an (approximately) equally spaced grid array. The association of the numbers in octet PL (and following) with the particular row follows the scanning mode specification in Table 8.

TABLES FOR THE GDS TABLE 6. DATA REPRESENTATION TYPE (GDS Octet 6). CONTENT & MEANING 7 - 8 Ni - Number of points along a latitude circle 9 - 10 Nj - Number of points along a longitude meridian 11 - 13 La1 - Latitude of first grid point 14 - 16 Lo1 - Longitude of first grid point 17 Resolution and component flags (see Table 7) 18 - 20 La2 - latitude of last grid point 21 - 23 Lo2 - longitude of last grid point 24 - 26 Latin - The latitude(s) at which the Mercator projection cylinder intersects the earth. 27 Reserved (set to 0) 28 Scanning mode (see Table 8) 29 - 31 Di - the longitudinal direction increment (see Note 2) 32 - 34 Dj - the latitudinal direction increment (see note 2) 35 - 42 Reserved (set to 0) Notes:.

Latitude and longitude are in millidegrees (thousandths). Grid lengths are in units of meters, at the circle of latitude specified by Latin. Latitude values are limited to the range 0 - 90,000. Bit 1 is set to 1 to indicate south latitude. Longitude values are limited to the range 0 - 360,000. Bit one is set to 1 to indicate west longitude. The latitude and longitude of the last grid point should always be given.

The first and last grid points may not necessarily be the same as the first and last data points if the bit map section (BMS) is used. BIT VALUE MEANING 1 0 Points scan in +i direction 1 Points scan in -i direction 2 0 Points scan in -j direction 1 Points scan in +j direction 3 0 Adjacent points in i direction are consecutive (FORTRAN: (I,J)) 1 Adjacent points in j direction are consecutive (FORTRAN: (J,I)) Note: i direction is defined as west to east along a parallel of latitude, or left to right along an x axis. J direction is defined as south to north along a meridian of longitude, or bottom to top along a y axis. SPECTRAL REPRESENTATION TYPE (GDS Octet 13) VALUE MEANING 1 Associated Legendre Polynomials of the First Kind with normalization such that the integral equals 1 TABLE 10. COEFFICIENT STORAGE MODE (GDS Octet 14) VALUE MEANING 1 The complex coefficients X nm are stored for m 0 as pairs of real numbers Re(Xnm), Im(Xnm) ordered with n increasing from m to N(m), first for m = 0 and then for m = 1, 2, 3.M. The real part of the (0,0) coefficient is stored in octets 12-15 of the BDS, as a floating point number in the same manner as the packing reference value, with units as in Table 2.

The remaining coefficients, starting with the imaginary part of the (0,0) coefficient, are packed according to the GRIB packing algorithm, with units as given in Table 5, in octets 16 and onward in the BDS. NOTES ON SPECTRAL TRUNCATION: Using the associated Legendre Polynomials of the First Kind, Pnm, as typical expansion functions, any variable x(l,F), which is a function of longitude, l, and sin(latitude), F, can be represented by In the summations, M is the maximum zonal wave number that is to be included, and K & J together define the maximum meridional total wave number N(m), which, it should be noted, is a function of m. A sketch shows the relationships: In this figure, the ordinate is n the zonal wave number, the abscissa, m, is the total meridional wave number, the vertical line at m = M is the zonal truncation, and the diagonal passing through (0,0) is the line n = m. The Legendre Polynomials are defined only on or above this line, that is for n m. On the n-axis, the horizontal line at n = K indicates the upper limit to n values, and the diagonal that intersects the n-axis at n = J indicates the upper limit of the area in which the Polynomials are defined.

Money Converter Google

The shaded irregular pentagon defined by the n-axis, the diagonal from n = J, the horizontal n = K, the vertical m = M, and the other diagonal n = m surrounds the region of the (n x m) plane containing the Legendre Polynomials used in the expansion. This general pentagonal truncation reduces to some familiar common truncations as special cases: Triangular: K = J = M and N(m) = J Rhomboidal: K = J + M and N(m) = J + m Trapezoidal: K = J, K M and N(m) = J In all of the above m can take on negative values to represent the imaginary part of the spectral coefficients.: BIT MAP SECTION (BMS) The purpose of the (optional) BMS is to provide either a bit map or a reference to a bit map pre-defined by the center. The bit map consists of contiguous bits with a bit-to-data-point correspondence as defined in the grid description. A bit set equal to 1 implies the presence of a datum for that grid point in the BDS; a value of zero implies the absence of such. This is useful in shrinking fields where fair portions of the field are not defined. An example would be global grids of sea surface temperature; the bit map would be used to suppress the 'data' at grid points over land.

One would not want to use the BMS if the data were un-defined at only a small number of grid points as the overhead of adding the bit map array (one bit for each grid point) might add more bits to the overall message that were subtracted by the removal of a few data values. 1 - 3 Length in octets of Bit Map Section 4 Number of unused bits at end of Section 3. 5 - 6 Numeric: = 0: a bit map follows; otherwise: the numeric refers to a predefined bit map provided by the center 7 - nnn Bit map, zero filled to an even number of octets: BINARY DATA SECTION (BDS).

The BDS contains the packed data and the binary scaling information needed to reconstruct the original data from the packed data. The required decimal scale factor is found in the PDS, above. The data stream is zero filled to an even number of octets. 1 - 3 Length in octets of binary data section 4 Bits 1 through 4: Flag - See Table 11 Bits 5 through 8: Number of unused bits at end of Section 4. 5 - 6 The binary scale factor (E). A negative value is indicated by setting the high order bit (bit No. 1) in octet 5 to 1 (on).

7 - 10 Reference value (minimum value); floating point representation of the number. 11 Number of bits into which a datum point is packed 12 -nnn Variable, depending on octet 4; zero filled to an even number of octets. 14 Optionally, may contain an extension of the flags in octet 4. See Table 11. Here are some of the various forms the binary data can take; the flag table in BDS octet 4, possibly extended into octet 14, identifies which variant is in use. Grid-point data - Simple packing Here the data simply begin in octet 12 and continue, packed according to the simple packing algorithm described above, without any particular regard for computer 'word' boundaries, until there is no more data. There may be some 'zero-fill' bits at the end.

Exchange

If all the data in a grid point field happen to have the same value, then all of the deviations from the reference value are set to zero. Since a zero value requires no bits for packing, octet 11 is set to zero, thus indicating a field of constant data, the value of which is given by the reference value.

Under these circumstances, octet 12 is set to zero (the required 'zero fill to an even number of octets') and bits 5-8 of octet 4 contain an 8. The number of data points in the field is implied by the grid identification given in the PDS and/or the GDS and BMS.

Spherical Harmonic Coefficients - Simple packing Octets 12-15 contain the real part of the (0.0) coefficient in the same floating point format as the reference value in octets 7-10. The imaginary part of the (0.0) coefficient, mathematically, is always equal zero. Octets 16 to the end contain the remaining coefficients packed up as binary data with the same sort of scaling, reference value, and the like, as with grid-point numbers.

Excluding the (0,0) coefficient, which is usually much larger than the others, from the packing operation means that the remaining coefficients can be packed to a given precision more efficiently (fewer bits per word) than would be the case otherwise. Grid-Point Data - Second Order or Complex Packing Before laying out where the various second order values, sub-parameters, counters, and what have you, go, it is appropriate to describe the second order packing method in an algorithmic manner. Referring back to the description of simple packing, the encoding method is the same up to part way through the fourth step, stopping just short of the actual packing of the scaled integers into the 'words' of either a pre-specified or calculated bit length. The basic outline of second order packing is to scan through the array of integers (one per grid point, or possibly less than that if the Bit Map Section has been employed to discard some of the null value points) and seek out sub-sections exhibiting relatively low variability within the sub-section. One then finds the (local) minimum value in that sub-section and subtracts it from the ('first order') integers in that sub-section, which leave a set of 'second order' integers. These numbers are then scanned to find the maximum value, which in turn is used to specify the minimum bit width for a 'word' necessary to contain the sub-section set of second order numbers. The term 'first order' in this context refers to the integer variables that result from subtracting the overall (global) minimum from the original variables and then doing all scaling and rounding; 'second order' refers to the variables that result from subtracting the local minimum from the sub-set of first order variables.

No further scaling is necessary or appropriate. The sub-section set of numbers are then packed into 'words' of the just determined bit length. The overall savings in space comes about because the second order values are, usually, smaller than their first order counterparts. They have, after all, had two minima subtracted from the original values, the overall minimum and the local minimum, where the first order values have had only the overall minimum subtracted out. There is no guarantee, however, that the second order packing will compress a given field to a greater degree than the first order packing. If the first order field of integers is highly variable, or generally close to zero, then there will be no gain in compression.

But if the field shows long runs of small variation, particularly if some of the runs are constant (zero variability), then the second order packing will contribute to the compression. The process then repeats and a whole collection of sub-sections are found, their local minima are subtracted, etc. One of the tricky parts of this process is defining just what is meant by a 'sub-section of low variability'. The WMO Manual is silent on this as it only describes how the sub-sections and their ancillary data are to be packed in the message. National Weather Service, the U.K. Meteorological Office, the European Centre for Medium-Range Weather Forecasts, and probably other groups have, independently, designed selection criteria and built them into GRIB encoders.

It is beyond the scope of this document to attempt to describe them in any detail. These groups have all expressed their willingness to share their GRIB encoders with any who ask for them. Before laying out where the second order values, etc., are placed in a message, we had best review just what information has to be saved.

Copyright (c) 2009, SMHI All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. Neither the name of the SMHI nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Features: this package is quite outdated but for netCDF it seems to provide higher-level functionalities than the built-in functions nc. of matlab, and for GRIB it is probably the only way. Installation: with help from a sysadmin, it took us a full day to install this on our central server (SUSE 64-bit). In an nutshell: 1) We had to install CDI 1.5.0, i.e. The.oldest. version available 2) We re-installed static libraries (lib.a) with option -fPIC (i.e.

Configure -with-pic) not only for CDI and netCDF but also for HDF4, HDF5 and GRIBAPI 3) We copied these lib.a into a subdirectory lib64 below the matlab-CDI directory. Note: we were able to keep the oringinal 'include' subdirectory 4) We edited cdimx.c to #include and replace 3 calls to non-standard functions (line 424: Warning - printf; lines 673,683: mxErrMsgIdAndTxt - mexPrintf ) 5) In compile.m we listed explicitly.all. necessary libraries i.e. After each -lnetcdf we added -lhdf5hl -lhdf5 -lmfhdf -ldf -lgribapi -ljpeg -lsz -lz -ldl I do not think that all 5 steps will be necessary for everyone but that's how we ended with a running installation. Hello everyone, I was able run the file 'compile.m' successfully.

However when I call the following function c = cdivarlist(filename,); I get the following error: cdivarlist: No such file or directory Although I'm pretty sure the file name and path is correct. I identified the error coming from the file cdimx.c at the following line streamID = streamOpenRead(szInputFilename); So basically 'streamOpenRead' cannot open my file although the path and the name are correct. I tried with and without the file extension (.grb). Also, no capabilities to read the contents of the file (e.g.

Private.) are actually required. Does anybody know why it does not work? This package didn't compile in Matlab R2009b and R2010a with following error: compile COMPILING cdivarlist. Cdimx.c: In function ‘getLevel’: cdimx.c:431: warning: incompatible implicit declaration of built-in function ‘modf’ cdimx.o: In function `readmeta': cdimx.c:(.text+0x1457): undefined reference to `mxErrMsgIdAndTxt' cdimx.c:(.text+0x14e3): undefined reference to `mxErrMsgIdAndTxt' collect2: ld returned 1 exit status mex: link of ' 'cdivarlist.mexa64' failed.??? Error using mex at 221 Unable to complete successfully.

Money Converter By Year

Error in compile at 15 mex cdivarlist.c cdimx.c -Iinclude -Llib64 -lcdi -lnetcdf It cleanly compiled on R2008b, though. Hello Klaus Wyser, 1) I have a probleme of compilation: run 'compile' COMPILING cdivarlist.

Cdimx.c: In function 'getLevel': cdimx.c:431: warning: incompatible implicit declaration of built-in function 'modf' /usr/bin/ld: cannot find -lcdi collect2: ld returned 1 exit status mex: link of 'cdivarlist.mexglx' failed. 2)I've coped my own compile 'libcdi.a',and 'libnetcdf.a' under the directory 'lib64'. 3)I have the cdireadall.mexw32 cdireadfield.mexw32 cdireadfull.mexw32 cdireadmeta.mexw32 cdivarlist.mexw32.

But my machine is i686. So i think i must have the mex file in mexw64??

Thanks avance!

Cartoon character maker software. Oct 12, 2014 - Hello! The title sorta says it all in my opinion, I would just like to know if there are any good 3D character creation programs for a beginner (which. Maya = is a Paid modelling software program Carrera 8.5 is a paid for, modelling software. MAKEHUMAN IS.the free and open source software to create realistic 3d humans for: Illustrations; Animations; Games; Zbrush/Mudbox sculpting. THE MOST LIBERAL LICENSE IN THE WORLD!! Content created with MakeHuman is licensed under the CC0 license, giving artists unprecedented freedom for using their.