Die Präsentation wird geladen. Bitte warten

Die Präsentation wird geladen. Bitte warten

Datentypen Genauigkeiten

Ähnliche Präsentationen


Präsentation zum Thema: "Datentypen Genauigkeiten"—  Präsentation transkript:

1 Datentypen Genauigkeiten
Timo Damm

2 Bits and Bytes Bit: Zwei Zustände [0;1] Nibble: 4 Bit
Byte: 8 Bit und damit 28=1024 Zustände Word: 16 Bit 1 kB = 103 Byte = 1000 Byte 1 MB = 106 Byte = Byte (Diskette 1,44 MB) 1 GB = 109 Byte (CD 0,8GB, DVD 4,7GB) … TB, PB, EB, ZB, YB

3 Zahlendarstellungen Quelle:

4 Elementare Datentypen
Ganze Zahlen (INT, INTEGER, BIGINT, SMALLINT, …) Bit, bei 32 Bit von ( ) Natürliche Zahlen (BYTE, UNSIGNED, WORD, …) Bit, bei 32 Bit von ( ) Festkommazahlen (DEC, DECIMAL, CURRENCY, …) wird per Stellenzahl gesetzt! Zeichen (CHAR, CHARACTER) abhängig vom jeweiligen Zeichensatz! Gleitkommazahlen (REAL, SINGLE, DOUBLE, EXTENDED, …) Quelle:

5 Integer Quelle:

6 Integer Quelle:

7 Gleitkommazahl f = s ∙ m ∙ 2e
Quelle:

8 Gleitkommazahl Quelle: http://de.wikipedia.org/wiki/Gleitkommazahl
Beispiel 24,7 dezimal nach IEEE 754, binary 32: 24 / 2 = 12 R 0 12 / 2 = 6 R 0 6 / 2 = 3 R 0 3 / 2 = 1 R 1 1 / 2 = 0 R 1 24dez = = 1,1000 *24 0,7 * 2 = 1,4 -> 1 0,4 * 2 = 0,8 -> 0 0,8 * 2 = 1,6 -> 1 0,6 * 2 = 1,2 -> 1 0,2 * 2 = 0,4 -> 0 0,7dez = 0, … 24,7dez = 11000, … Quelle:

9 Gleitkommazahl Quelle: http://de.wikipedia.org/wiki/Gleitkommazahl
Éxponent besitzt eine Verschiebung (Bias): +127 = 131dez 131 / 2 = 65 R 1 65 / 2 = 32 R 1 32 / 2 = 16 R 0 16 / 2 = 8 R 0 8 / 2 = 8 R 0 4 / 2 = 8 R 0 2 / 2 = 1 R 0 1 / 2 = 0 R dez = Quelle:

10 Dateiformat IGMAS alt 8 Vertices (Index,X,Z,Plane)
1 Layer boundaries C Layer boundary 1 (Dens. right, dens. left, Number of lines) 1 2 2 2 Vertical Planes (Y) 2 Densities

11 Dateiformat IGMAS gmdf
#gmdf_ascii unit Quader density 1.0 reference_density 0.0 section 1 point point coordinates Vertices   section 2 point 0. 1. point 1. 1. coordinates unit Quader vertices

12 Dateiformat IGMAS XML <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE geodata SYSTEM "geodata.dtd"> <!-- Created by IGMAS --> <geodata name="Synthetic Saltdome"> <projection name="unknown" units="km" /> <magnetic_field total_field="49441." units="nT" inclination=" 69." declination=" 1." /> <property name="Body" value="Permian"> <property name="Density" units="g/cm^3" value="-0.100" /> <property name="Susceptibility" units="SI" value=" " /> <property name="Koenigsberg ratio" units="SI" value="0.000" /> <color red="0.25" green="1.00" blue="0.12" /> </property> <property name="Body" value="Triassic"> </property> …

13 Dateiformat IGMAS XML … <geometry>
<cross_section x_start="0." y_start="-500." x_end="100." y_end="-500." name="First_section" /> <vertex id="1" x="-500." z="0." /> <vertex id="2" x="500." z="0." /> <vertex id="3" x="-500." z="-1.352" /> <vertex id="4" x=" " z=" " /> <vertex id="5" x=" " z=" " /> <vertex id="6" x=" " z=" " /> <vertex id="7" x=" " z=" " /> <vertex id="8" x=" " z=" " /> <vertex id="9" x=" " z=" " /> <vertex id="10" x=" " z=" " /> <vertex id="11" x=" " z=" " /> <vertex id="12" x="500." z=" " /> <vertex id="13" x="-500." z=" " /> ..

14 Dateiformat IGMAS XML … <entry type="triangle_set" id_list=" … </entry> </geometry> </geodata>

15 Dateiformat IGMAS DTD <?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XML Spy v2.5 NT > <!-- Entwurf einer Struktur fuer Geodaten - S. Schmidt, CAU Kiel. Last mod > <!-- Es fehlen noch Tetraeder, sonst sollte es vollstaendig sein. --> <!ELEMENT geodata ((geographic|projection), magnetic_field?, property*, (geometry|grid|bitmap)*)> <!ELEMENT geometry (cross_section?, vertex*, entry*)> <!ELEMENT vertex (property)*> <!ELEMENT entry (property*, vertex*)> <!ELEMENT geographic EMPTY> <!ELEMENT projection EMPTY> <!ELEMENT magnetic_field EMPTY> <!ELEMENT color EMPTY> <!ELEMENT cross_section EMPTY> <!ELEMENT grid (property)*> <!ELEMENT bitmap EMPTY> <!ELEMENT property ((property)*, color?)>

16 Dateiformat IGMAS DTD … <!ATTLIST vertex id CDATA #IMPLIED
x CDATA #REQUIRED y CDATA "0" z CDATA "0" modify (true | false) "true"> <!ATTLIST entry type (point_set | line | polygon | triangle_set) #REQUIRED scale CDATA "unknown" id_list CDATA #IMPLIED> <!ATTLIST cross_section x_start CDATA #REQUIRED y_start CDATA #REQUIRED x_end CDATA #REQUIRED y_end CDATA #REQUIRED offset CDATA #IMPLIED name CDATA #IMPLIED> <!ATTLIST grid order_123 (xyz|yxz|zxy|zyx|xzy|yzx) "xyz"

17 Dateiformat IGMAS DTD


Herunterladen ppt "Datentypen Genauigkeiten"

Ähnliche Präsentationen


Google-Anzeigen