<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Intrepid Blog &#187; floating points</title>
	<atom:link href="http://blog.affien.com/archives/tag/floating-points/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.affien.com</link>
	<description>A few thoughts</description>
	<lastBuildDate>Mon, 23 Jan 2012 08:47:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Variable sized floating points</title>
		<link>http://blog.affien.com/archives/2005/01/22/variable-sized-floating-points/</link>
		<comments>http://blog.affien.com/archives/2005/01/22/variable-sized-floating-points/#comments</comments>
		<pubDate>Sat, 22 Jan 2005 10:13:50 +0000</pubDate>
		<dc:creator>Bas Westerbaan</dc:creator>
				<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[floating points]]></category>
		<category><![CDATA[variable size]]></category>

		<guid isPermaLink="false">http://blog.w-nz.com/archives/2005/01/22/variable-sized-floating-points/</guid>
		<description><![CDATA[A lot of selfrespecting programming languages have got  [...]]]></description>
			<content:encoded><![CDATA[<p>A lot of selfrespecting programming languages have got Integer classes which theoraticly can have an unlimited size by using a dynamic array underneath it.<br />
Python got it, and lots of others too.<br />
But still, they haven&#8217;t got a variable sized floating point, which I find odd for it shouldn&#8217;t be a big problem to create:</p>
<ul>
<li>Wrap one existing variable sized Integer</li>
<li>Add an integer which points to the place where the point will be</li>
<li>Add operator overrides to get it working</li>
<li>Add an integer which specifies how much numbers after the dot there will be</li>
</ul>
<p>The later one is quite important to have got. We wouldn&#8217;t want <code>1 /3</code> causing an infinite loop.</p>
<p>You even could do it a second way:</p>
<ul>
<li>Wrap <strong>two</strong> existing variable sized Integers.</li>
<li>Add overriden operators to get it working</li>
</ul>
<p>These 2 integers would represent a fraction: <code>a / b</code>.</p>
<p>By storing the fraction in stead of the result you are actually very precise, although some numbers cannot be represented in this way, but can be approached.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.affien.com/archives/2005/01/22/variable-sized-floating-points/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

