Shop OBEX P1 Docs P2 Docs Learn Events
VERY long division — Parallax Forums

VERY long division

AImanAIman Posts: 531
edited 2006-11-20 20:07 in BASIC Stamp
How can I change the number of decimals the BS2 will calculate out?

The largest variable can hold several thousand characters, so can it go out a long ways?

Can it go to·1000 points out?

If not how far?

Comments

  • Tracy AllenTracy Allen Posts: 6,662
    edited 2006-11-18 02:37
    I'm not quite sure what you mean. If you want to kick out the decimal digits from an algorithm, the Stamp can just keep on going. For example to calculate 1/3 = 0.333333333333333333333333333333333... as long as you want.

    But if you need to hold a number in memory, the Stamp is quite limited on memory resources. What are you trying to do?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tracy Allen
    www.emesystems.com
  • AImanAIman Posts: 531
    edited 2006-11-19 04:43
    I am wanting to divide out numbers on my GPS module as far as I can. My father in law has done some work on items of this nature and indicated that the farther out the numbers get carried the better. Since GPS can only update once a second anyway, I want to get the numbers to x and / espically / by upto 1,000 places. Perhaps more.
  • tj60647tj60647 Posts: 18
    edited 2006-11-20 02:20
    While it is still not entirely clear what you are trying to do, it seems that you desire to have a very high resolution measurement.

    A greater limitation than the capacity of the basic stamp to do this kind of division is the capacity of the sensor to provide high resolution data.

    So, if you are using the Parallax GPS module and it is providing a 'word' of data, it isn't really useful to resolve data to a division greater than a 'word' can hold.· There is a limit to the accuracy of a GPS unit as well.

    I could use a wooden ruler to measure a length to 1/32nd of an inch.· But this does not mean I can expect to know half the distance to 1/1000th of an inch.·
  • AImanAIman Posts: 531
    edited 2006-11-20 20:07
    Much more to the division then just a GPS, although the data crunched wil be feed to the GPS and a few other things.
Sign In or Register to comment.