Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'from:addr:yahoo.co.uk': 0.04; 'subject:Python': 0.06; 'c++,': 0.07; 'perl,': 0.07; 'subject:Questions': 0.07; 'alain': 0.09; 'lawrence': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'tismer': 0.09; 'python': 0.11; 'mostly': 0.14; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'wrappers': 0.16; 'language': 0.16; 'wrote:': 0.18; 'library': 0.18; 'module': 0.19; 'programming': 0.22; 'header:User-Agent:1': 0.23; 'math': 0.24; 'question': 0.24; 'compiled': 0.26; 'second': 0.26; 'header:X -Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; '(like': 0.30; 'writes:': 0.31; 'probably': 0.32; 'url:python': 0.33; 'test': 0.35; 'but': 0.35; 'url:org': 0.36; 'christian': 0.38; 'url:library': 0.38; 'to:addr:python-list': 0.38; 'anything': 0.39; 'does': 0.39; 'to:addr:python.org': 0.39; 'enough': 0.39; 'received:org': 0.40; 'consists': 0.60; 'url:3': 0.61; 'world.': 0.61; 'simple': 0.61; 'such': 0.63; 'relatively': 0.65; 'subject:. ': 0.67; 'calculations': 0.84; 'received:2': 0.84; 'trig': 0.84; 'subject:2013': 0.95 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Mark Lawrence Subject: Re: Basic Python Questions - Oct. 31, 2013 Date: Thu, 31 Oct 2013 14:15:40 +0000 References: <877gctd1fn.fsf@dpt-info.u-strasbg.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: host-2-98-197-64.as13285.net User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 In-Reply-To: <877gctd1fn.fsf@dpt-info.u-strasbg.fr> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 27 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1383228964 news.xs4all.nl 16001 [2001:888:2000:d::a6]:53436 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:58175 On 31/10/2013 13:17, Alain Ketterlin wrote: > "E.D.G." writes: > >> The calculation speed question just involves relatively simple >> math such as multiplications and divisions and trig calculations such >> as sin and tan etc. > > These are not "simple" computations. > > Any compiled language (Fortran, C, C++, typically) will probably go much > faster than any interpreted/bytecode-based language (like python or > perl, anything that does not use a jit). > From http://docs.python.org/3/library/math.html "CPython implementation detail: The math module consists mostly of thin wrappers around the platform C math library functions." There's only one way I know of to find if it's actually fast enough and that's test it. -- Python is the second best programming language in the world. But the best has yet to be invented. Christian Tismer Mark Lawrence