Wanted: Efficient Algorithm to Square an Integer Number

03062019, 03:54 PM
(This post was last modified: 03062019 03:54 PM by Martin Hepperle.)
Post: #1




Wanted: Efficient Algorithm to Square an Integer Number
Hi,
some programming languages (like (Turbo Pascal) offer special functions to square an integer number. These are said to be faster than multiplying the number by itself. Where can I find algorithms like this? I searched the internet for a while and I am aware of Donald Knuth's books, but I did not find a suitable algorithm. Some time ago I had a document describing many clever tricks for working with numbers in various digital representations (8 ... 64 bit integers, IEEE floating point). Many involved magic numbers and overflows etc.. It contained algorithms like inverting all bits in a number and similar. But I cannot find it anymore. Any ideas, hints, links? Thank you, Martin 

« Next Oldest  Next Newest »

Messages In This Thread 
Wanted: Efficient Algorithm to Square an Integer Number  Martin Hepperle  03062019 03:54 PM
RE: Wanted: Efficient Algorithm to Square an Integer Number  ijabbott  03062019, 08:10 PM
RE: Wanted: Efficient Algorithm to Square an Integer Number  Martin Hepperle  03072019, 02:52 PM
RE: Wanted: Efficient Algorithm to Square an Integer Number  David Hayden  03062019, 08:16 PM
RE: Wanted: Efficient Algorithm to Square an Integer Number  Thomas Okken  03062019, 11:24 PM
RE: Wanted: Efficient Algorithm to Square an Integer Number  Jim Horn  03082019, 12:26 AM
RE: Wanted: Efficient Algorithm to Square an Integer Number  Gerson W. Barbosa  03062019, 11:47 PM
RE: Wanted: Efficient Algorithm to Square an Integer Number  Druzyek  03072019, 12:10 AM

User(s) browsing this thread: 1 Guest(s)