Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

An algorithm for the square-root


  • Please log in to reply
2 replies to this topic

#1 Mario Vernari

Mario Vernari

    Advanced Member

  • Members
  • PipPipPip
  • 1768 posts
  • LocationVenezia, Italia

Posted 26 March 2011 - 04:14 PM

Anyone needs an algorithm to calculate the square-root of a float value, now has a solution.
I have posted an article with C# source and some infos.
http://highfieldtale...he-square-root/
Cheers
Biggest fault of Netduino? It runs by electricity.

#2 Corey Kosak

Corey Kosak

    Advanced Member

  • Members
  • PipPipPip
  • 276 posts
  • LocationHoboken, NJ

Posted 03 April 2011 - 09:41 PM

Anyone needs an algorithm to calculate the square-root of a float value, now has a solution.
I have posted an article with C# source and some infos.
http://highfieldtale...he-square-root/
Cheers

I find myself wondering (not really seriously) if your application and the Netduino would benefit from the fast inverse square root algorithm (aka the Quake III Hack). If so, maybe we could make it available as a firmware mod :D

#3 Mario Vernari

Mario Vernari

    Advanced Member

  • Members
  • PipPipPip
  • 1768 posts
  • LocationVenezia, Italia

Posted 04 April 2011 - 03:33 AM

I read there was an algorithm based on the IEEE representation of the float, but I wasn't able to convert the C# float to an integer. That is another serious leak of the available framework. My article was a pure C# solution offered to substitute the (only) one present in Grommet. Of sure will be replaced with something better in case of native libraries. Thanks anyway. Cheers
Biggest fault of Netduino? It runs by electricity.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.