Return-Path: X-Original-To: apmail-commons-dev-archive@www.apache.org Delivered-To: apmail-commons-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 565C59957 for ; Wed, 5 Oct 2011 18:04:14 +0000 (UTC) Received: (qmail 96828 invoked by uid 500); 5 Oct 2011 18:04:13 -0000 Delivered-To: apmail-commons-dev-archive@commons.apache.org Received: (qmail 96751 invoked by uid 500); 5 Oct 2011 18:04:13 -0000 Mailing-List: contact dev-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Commons Developers List" Delivered-To: mailing list dev@commons.apache.org Received: (qmail 96743 invoked by uid 99); 5 Oct 2011 18:04:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Oct 2011 18:04:13 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of ted.dunning@gmail.com designates 209.85.216.43 as permitted sender) Received: from [209.85.216.43] (HELO mail-qw0-f43.google.com) (209.85.216.43) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Oct 2011 18:04:05 +0000 Received: by qabg14 with SMTP id g14so2112612qab.30 for ; Wed, 05 Oct 2011 11:03:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=t+k7y90hsc8jYefySGBU82gwGYf0Fcez2NiziWJbrfQ=; b=Junygkdvw2pMRzYk+k7RiL8gC5np+/sDC0tfFyID8ZrgTe6CjtArSxENYK7KnYo99L 0NX4y+l2Q3bmf4dMbhR/mkpYg4WoADLT0N490Nxwz8OUunHLBBtjU5xla3l2aZdLOYRr dYoZja3J3bCzx0fjWv+xQHK7krI4ikeCaN/ho= Received: by 10.224.212.65 with SMTP id gr1mr2254065qab.260.1317837825058; Wed, 05 Oct 2011 11:03:45 -0700 (PDT) MIME-Version: 1.0 Received: by 10.224.89.76 with HTTP; Wed, 5 Oct 2011 11:03:24 -0700 (PDT) In-Reply-To: <4E8C9946.3040404@free.fr> References: <20111005101645.GC17388@dusk.harfang.homelinux.org> <20111005143919.GE17388@dusk.harfang.homelinux.org> <20111005160256.GF17388@dusk.harfang.homelinux.org> <4E8C9946.3040404@free.fr> From: Ted Dunning Date: Wed, 5 Oct 2011 11:03:24 -0700 Message-ID: Subject: Re: [MATH] Re: Pivoting QR Decomposition: Take Two! To: Commons Developers List Content-Type: multipart/alternative; boundary=20cf30050d7c6f29c204ae910748 X-Virus-Checked: Checked by ClamAV on apache.org --20cf30050d7c6f29c204ae910748 Content-Type: text/plain; charset=UTF-8 Sounds like it would be nice to have both implementations in the same class with a "usePivoting(boolean)" method to select which is used. I would recommend pivoting as the default since it gives fewer surprises and more diagnostic information to the naive user. Except for the extra indexing costs, a pivoting implementation should be about twice as costly as a non-pivoting implementation. If you don't do the pivoting by indirection, this could be significantly more due to copying. I haven't had instances where I would have much cared, but it would be nice to have the option for extra speed if I needed it. On Wed, Oct 5, 2011 at 10:52 AM, Luc Maisonobe wrote: > 4. Implement the best algorithm as "QRDecomposition" in ("linear"), and >> remove duplicate code ("LevenbergMarquardt" will call the >> implementation >> in "linear"; if replacing the LM currently internal version makes some >> test fail, we should worry and look for the bug either in LM or in the >> new QR or in the tests). >> > > I'm not sure one implementation only is always feasible. The one I put in > Levenberg-Marquardt is perhaps more suited to some cases because of > pivoting, but I'm quite sure it is not as efficient as the classical one > which is really fast (I always used it as an example in conferences to show > that Java can be as fast as fortran in some application, because it is as > fast as lapack with ATLAS blas on matrices up to about 1000 rows and > columns). --20cf30050d7c6f29c204ae910748--