Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #12878

Re: Floating point multiplication in python

From Dennis Lee Bieber <wlfraed@ix.netcom.com>
Subject Re: Floating point multiplication in python
Date 2011-09-06 23:35 -0700
Organization > Bestiaria Support Staff <
References <mailman.790.1315289581.27778.python-list@python.org> <j44rre$e4c$1@r03.glglgl.eu> <2204592.egLE2XKegd@PointedEars.de> <4e66f843$0$29969$c3e8da3$5496439d@news.astraweb.com>
Newsgroups comp.lang.python
Message-ID <mailman.822.1315377360.27778.python-list@python.org> (permalink)

Show all headers | View raw


On Wed, 07 Sep 2011 14:51:13 +1000, Steven D'Aprano
<steve+comp.lang.python@pearwood.info> declaimed the following in
gmane.comp.python.general:


> What you probably mean to say is that binary hardware usually implements
> multiplication via repeated addition.
> 
> http://en.wikipedia.org/wiki/Binary_multiplier
>
	Technically, as shown by that article, binary multiplication is not
what is commonly thought of "repeated addition" (the method used on old
adding machines wherein one hit "+" /n/ times [though one normally
entered a "0" for each place: rather than hit "+" 20 time for 123 * 20,
on would hit 123, 0 "+", enter a 0 {giving 1230}, then hitting 2 "+"]).

	In binary most of the subparts are the results of left shifts
(factors of 2); so "repeated" doesn't really apply... Multiple shift/add
OTOH...
-- 
	Wulfraed                 Dennis Lee Bieber         AF6VN
        wlfraed@ix.netcom.com    HTTP://wlfraed.home.netcom.com/

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Floating point multiplication in python xyz <xyzhtml@163.com> - 2011-09-06 13:57 +0800
  Re: Floating point multiplication in python Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-09-06 17:11 +1000
  Re: Floating point multiplication in python Thomas Rachel <nutznetz-0c1b6768-bfa9-48d5-a470-7603bd3aa915@spamschutz.glglgl.de> - 2011-09-06 12:14 +0200
    Re: Floating point multiplication in python Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2011-09-06 18:07 +0200
      Re: Floating point multiplication in python Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-09-07 14:51 +1000
        Re: Floating point multiplication in python Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2011-09-06 23:35 -0700
        Re: Floating point multiplication in python Gelonida N <gelonida@gmail.com> - 2011-09-07 10:57 +0200
        Re: Floating point multiplication in python Terry Reedy <tjreedy@udel.edu> - 2011-09-07 05:37 -0400

csiph-web