Engineering Design NIDisk Betriebsanweisung Seite 32

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken
  • Seite
    / 34
  • Inhaltsverzeichnis
  • LESEZEICHEN
  • Bewertet. / 5. Basierend auf Kundenbewertungen
Seitenansicht 31
SIGNAL/RTS APPLICATION NOTES
8 Application Note 11
Issues in Data Storage and Exchange
This section provides background on data storage issues that affect data exchange between
software systems and hardware platforms. A basic understanding of these issues is important
to exchange data accurately and reliably.
Text vs. Binary format
Data files can be stored and exchanged in either text (ASCII) or binary format. Text format
is the most universal in that virtually all hardware platforms and software systems can read it,
however it imposes two limitations: 1) it requires considerably more storage (up to 10 times
more) for the same data and 2) numerical precision is limited to the data format chosen at the
time of writing (for example, F12.4 format limits precision to 4 decimal places). By contrast,
binary format is more space-efficient and numerical precision is determined by the data
storage format inside the computer, which is then maintained in the data file. For these
reasons, precision transfers of numerical data should usually be performed via binary files.
Integer vs. Floating Point format
Binary data in turn can be stored in either integer or floating point (real) format. Integer
format stores the (integer) data in direct binary form, e.g., 1001 for the number 9. It has
complete accuracy but a limited numerical range - e.g., a 16-bit integer can only represent
integers between -32768 and +32767. Floating point format refers to the coding of real
numbers, i.e., numbers which can assume non-integer values such as 1.234567. In this
format, a certain number of bits (the "mantissa") represent the numerical value without regard
for decimal point (e.g. 1234567 in the above), while the remaining bits (the "exponent")
indicate the position of the decimal point (i.e. 10 ** -6 in the above example). The number of
mantissa bits limits the precision of the format, while the number of exponent bits limits its
dynamic range (largest positive and negative number). IBM PC's use a standard 32-bit
floating point representation (IEEE 754) which has 1 sign bit, a 24-bit mantissa (1 bit is
implicit), and an 8-bit exponent. This provides a mantissa resolution of 2 ** 24 = 10 ** 7, or
7 decimal places, and an exponent range of 2 ** 8 = 128 (i.e., the binary "decimal point" can
be moved up to 128 binary places in either direction). Converting to powers of ten, the
dynamic range is then 2 **
±128 = 10 ** ±37.
The two numerical formats serve quite different purposes. Raw acquisition data is normally
maintained in the original integer format delivered by the digitizer, to avoid introducing even
minor "noise" by converting the integers to the less precise floating point format. Conversely,
the results of calculations are almost universally stored in floating point format, since their
precision and range vary widely.
Seitenansicht 31
1 2 ... 27 28 29 30 31 32 33 34

Kommentare zu diesen Handbüchern

Keine Kommentare