<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Datatype problem in project euler in LabVIEW</title>
    <link>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/906638#M408557</link>
    <description>&lt;P&gt;Today I had nothing to do, so I participated in Project Euler &lt;A href="http://projecteuler.net/" target="_blank"&gt;http://projecteuler.net&lt;/A&gt;&amp;nbsp;with Labview. I'm at question 10 now. The question itself isn't much of a challenge, but the problem I'm having is that the datatypes are to small for the value I would like to put in there. The value first goes up, then changes from + to - and then goes back to zero. This all happens while I'm just adding up to the value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I guess there is a sollution to this problem but I don't seem to find it. Is there someone who can and will help me please?&lt;/P&gt;</description>
    <pubDate>Wed, 13 May 2009 13:51:31 GMT</pubDate>
    <dc:creator>frostie</dc:creator>
    <dc:date>2009-05-13T13:51:31Z</dc:date>
    <item>
      <title>Datatype problem in project euler</title>
      <link>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/906638#M408557</link>
      <description>&lt;P&gt;Today I had nothing to do, so I participated in Project Euler &lt;A href="http://projecteuler.net/" target="_blank"&gt;http://projecteuler.net&lt;/A&gt;&amp;nbsp;with Labview. I'm at question 10 now. The question itself isn't much of a challenge, but the problem I'm having is that the datatypes are to small for the value I would like to put in there. The value first goes up, then changes from + to - and then goes back to zero. This all happens while I'm just adding up to the value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I guess there is a sollution to this problem but I don't seem to find it. Is there someone who can and will help me please?&lt;/P&gt;</description>
      <pubDate>Wed, 13 May 2009 13:51:31 GMT</pubDate>
      <guid>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/906638#M408557</guid>
      <dc:creator>frostie</dc:creator>
      <dc:date>2009-05-13T13:51:31Z</dc:date>
    </item>
    <item>
      <title>Re: Datatype problem in project euler</title>
      <link>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907190#M408784</link>
      <description>What datatypes are you trying to use?&amp;nbsp; Are they integer or floating point?&amp;nbsp; How many bytes?</description>
      <pubDate>Thu, 14 May 2009 03:32:42 GMT</pubDate>
      <guid>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907190#M408784</guid>
      <dc:creator>RavensFan</dc:creator>
      <dc:date>2009-05-14T03:32:42Z</dc:date>
    </item>
    <item>
      <title>Re: Datatype problem in project euler</title>
      <link>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907362#M408857</link>
      <description>&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Calculate the full value of 2^1000. Even if I use the 64bit datatype I come in (very) short.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you very much for your response!&lt;/P&gt;</description>
      <pubDate>Thu, 14 May 2009 09:31:31 GMT</pubDate>
      <guid>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907362#M408857</guid>
      <dc:creator>frostie</dc:creator>
      <dc:date>2009-05-14T09:31:31Z</dc:date>
    </item>
    <item>
      <title>Re: Datatype problem in project euler</title>
      <link>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907402#M408873</link>
      <description>&lt;P&gt;by the way, I am using integers because the result has to be accurate. In the end I need the&amp;nbsp;sum of all numbers of the result.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(example: 456789 becomes 4+5+6+7+8+9 = 39 and the 39 is what I need)&lt;/P&gt;</description>
      <pubDate>Thu, 14 May 2009 11:07:33 GMT</pubDate>
      <guid>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907402#M408873</guid>
      <dc:creator>frostie</dc:creator>
      <dc:date>2009-05-14T11:07:33Z</dc:date>
    </item>
    <item>
      <title>Re: Datatype problem in project euler</title>
      <link>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907763#M409002</link>
      <description>&lt;P&gt;Well, the link you gave said problem 10 was "Find the sum of all the primes below two million", a little different problem than 2^1000.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In order represent 2^1000 at full resolution, you would need a 1000 bit number!&amp;nbsp; Of course a U64 won't be able to hold it.&amp;nbsp; A double will hold it and it comes to about 1.07...e301, so 301 decimal digits.&amp;nbsp; But a double won't store the full resolution.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In order to do what you want, you will have to set up your own math functions using 125+ bytes.&amp;nbsp; You will have to do the multiplication and do all of your own carries.&amp;nbsp; That why they made it a problem, to challenge you to figure out the algorhitm to do it.&amp;nbsp; Otherwise going 2^1000 in any programming language is a trivial exercise.&lt;/P&gt;</description>
      <pubDate>Thu, 14 May 2009 17:33:33 GMT</pubDate>
      <guid>https://forums.ni.com/t5/LabVIEW/Datatype-problem-in-project-euler/m-p/907763#M409002</guid>
      <dc:creator>RavensFan</dc:creator>
      <dc:date>2009-05-14T17:33:33Z</dc:date>
    </item>
  </channel>
</rss>

