🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: de.comp.lang.c++
Article #1281

Re: float

#1281
From: Tom Wellige
Date: Sun, 14 Jan 1996 20:43
34 lines
2007 bytes
st000217 wrote on 14.01.96 about
"float":

> kann mir jemand erklaeren, wie ein float-Zahl binaer dargestellt wird?

Hallo Mark.

Ich bin mir nicht 100% sicher, aber ich leite mir sowas immer aus einer 
einfachen Ueberlegung heraus her:

Eine float-Zahl ist 4 Byte gross und umfasst den Zahlenbereich
3.4E-38 bis 3.4E38 . Da Manitsse und Exponent getrennt sind, ueberlege ich 
mir zuerst, wieviel Bits benoetigt werden, um den Exponenten darzustellen.
Da 77 verschiedene Zahlen moeglich sind, werden 7 Bits fuer den 
Exponenten benoetigt. Danach bleiben noch 25 Bits fuer die Mantisse uebrig.

           +----------------------------+--------+
           |   25 Bits                  | 7 Bits |
           +----------------------------+--------+
              Mantisse                    Exponent
              
Man moege mich korrigieren, wenn ich mich irren sollte.
              

  See you, Tom.
--
 +--------------------------+---------------------------------------------+
 | Tom Wellige              | BBS DISTEL (Dieburg, Germany)               |
 | Haller Weg 64            |    PICARD@distel.robin.de                   |
 | 33617 Bielefeld, GERMANY | Dublin Institute of Technology (Ireland)    |
 | +49 521 152474           |    TWELLIGE@dit.ie                          |
 | ** PGP key on request ** |    http://147.252.133.152/people/twellige/  |
 +--------------------------+---------------------------------------------+
## CrossPoint v3.1 R ##
Technical Details
Message-ID: <60q6EeC6bxB@picard.distel.robin.de>
Path: arc1-ca.pugleaf.net!PICARD.DISTEL.RoBIN.de!picard
References: <4dbfci$1dap@rs18.hrz.th-darmstadt.de>

Show Full Headers
Complete Article Headers
X-Mailer: CrossPoint v3.1 R/C6598
Message-ID: <60q6EeC6bxB@picard.distel.robin.de>
Organization: Tom Wellige
References: <4dbfci$1dap@rs18.hrz.th-darmstadt.de>
X-Gateway: ZCONNECT UU distel.robin.de [DUUCP vom 01.07.1994]
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
From: picard@distel.robin.de (Tom Wellige)
Subject: Re: float
Date: 14 Jan 1996 21:43:00 +0100
Path: arc1-ca.pugleaf.net!PICARD.DISTEL.RoBIN.de!picard
Newsgroups: de.comp.lang.c++
Distribution: world