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 B359897A6 for ; Wed, 5 Oct 2011 14:39:54 +0000 (UTC) Received: (qmail 80978 invoked by uid 500); 5 Oct 2011 14:39:54 -0000 Delivered-To: apmail-commons-dev-archive@commons.apache.org Received: (qmail 80897 invoked by uid 500); 5 Oct 2011 14:39:54 -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 80889 invoked by uid 99); 5 Oct 2011 14:39:54 -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 14:39:54 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [193.74.71.28] (HELO sif.is.scarlet.be) (193.74.71.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Oct 2011 14:39:46 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=scarlet.be; s=scarlet; t=1317825565; bh=Z+Iw8idtSUs2C8xP/tLGHrK7rh9679JyeuCLKbyXCwM=; h=Date:From:To:Subject:Message-ID:References:MIME-Version: Content-Type:In-Reply-To; b=EgJw70ejcv7+lasxr79kluiUMlLAqRafC84P4R8XROPPBnKbzWO8FrxPFG+m3Tc/G Q8K7vjgUapiV06ooGsOU9+dI/6YuPE3sRwr+FY0HDkBeyr9ueVwLcPMgIyTt6bjNiG /XyXr5mcwaLptecfEwL+Hogzw0VgZuIfnDdf+oO4= Received: from mail.harfang.homelinux.org (ip-213-49-235-47.dsl.scarlet.be [213.49.235.47]) by sif.is.scarlet.be (8.14.5/8.14.5) with ESMTP id p95EdNZh021090 for ; Wed, 5 Oct 2011 16:39:24 +0200 X-Scarlet: d=1317825564 c=213.49.235.47 Received: from localhost (mail.harfang.homelinux.org [192.168.20.11]) by mail.harfang.homelinux.org (Postfix) with ESMTP id E0B7361D22 for ; Wed, 5 Oct 2011 16:39:23 +0200 (CEST) Received: from mail.harfang.homelinux.org ([192.168.20.11]) by localhost (mail.harfang.homelinux.org [192.168.20.11]) (amavisd-new, port 10024) with ESMTP id HDgeirpMcIij for ; Wed, 5 Oct 2011 16:39:20 +0200 (CEST) Received: from dusk.harfang.homelinux.org (mail.harfang.homelinux.org [192.168.20.11]) by mail.harfang.homelinux.org (Postfix) with ESMTP id DB79F617AD for ; Wed, 5 Oct 2011 16:39:20 +0200 (CEST) Received: from eran by dusk.harfang.homelinux.org with local (Exim 4.76) (envelope-from ) id 1RBScy-0004Em-L3 for dev@commons.apache.org; Wed, 05 Oct 2011 16:39:20 +0200 Date: Wed, 5 Oct 2011 16:39:19 +0200 From: Gilles Sadowski To: dev@commons.apache.org Subject: Re: [MATH] Re: Pivoting QR Decomposition: Take Two! Message-ID: <20111005143919.GE17388@dusk.harfang.homelinux.org> Mail-Followup-To: dev@commons.apache.org References: <20111005101645.GC17388@dusk.harfang.homelinux.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: Tiny Tux X-PGP-Key-Fingerprint: 53B9 972E C2E6 B93C BEAD 7092 09E6 AF46 51D0 5641 User-Agent: Mutt/1.5.21 (2010-09-15) X-DCC-scarlet.be-Metrics: sif 20001; Body=1 Fuz1=1 Fuz2=1 X-Virus-Scanned: clamav-milter 0.97.1-exp at sif X-Virus-Status: Clean X-Virus-Checked: Checked by ClamAV on apache.org On Wed, Oct 05, 2011 at 08:46:55AM -0500, Greg Sterijevski wrote: > Hi Gilles, > > The class passes all current tests for QRDecomposition. Are you suggesting I > rip out the QRDecomposition from OLSMultipleRegression...etc and then make > sure there are no test failures? Or are you suggestion a new set of tests? None of the above, I guess (IIUC). I'm just saying that if "QR decomposition" is a well defined concept, it should be implemented in the class "QRDecomposition" in package "linear", and classes that need the functionality should "import" it from there. I.e. there should not be duplicate code (which from what I read in this thread, seems to exist in "OLSMultipleRegression" and "LevenbergMarquardtOptimizer"). Gilles > > -Greg > > On Wed, Oct 5, 2011 at 5:16 AM, Gilles Sadowski < > gilles@harfang.homelinux.org> wrote: > > > Hi. > > > > > > A while back I was interested in being able to do pivoting qr > > > > decomposition. I noticed that Chris Nix submitted a patch, but he > > indicated > > > > that he had more work to do (testing and filling in functionality). In > > the > > > > discussion around this, Luc suggested that I look at the QR > > decomposition in > > > > Levenberg-Marquardt. I did just that a few days ago. The code was very > > clear > > > > and nicely written (kudos to Luc). So, I copied the routine and made a > > new > > > > PivotingQRDecomposition class. The class is intended as a "drop in > > > > replacement" for QRDecomposition. I also copied the QRSolverTest and > > > > QRDecompositionTest. With the exception of testUnderdetermined in the > > solver > > > > test and testAEqualQR in QRDecompositionTest, the tests are unchanged > > (and > > > > all pass!). With testUndertermined, the "zeroed" rows of the solution > > matrix > > > > are interspersed throughout the matrix (because of pivoting). So I > > change > > > > the test to count all the rows that have zero norms, and check that it > > is > > > > the correct number. In testAEqualQR, I added a multiplication by the > > > > permutation matrix. > > > > > > > > What is the best way to proceed? I don't want to trounce the additions > > that > > > > Chris made, but it looks like Chris has more sophisticated classes in > > mind. > > > > I don't see this proposed change competing with his. Does it make sense > > to > > > > bring back QRDecomposition interface (sorry Sebastien)? We can then > > keep > > > > both implementations until we are satisfied the pivoting one works. > > > > -1 > > Please do the required testing. Only the "current best" implementation > > should remain. > > > > > > Regards, > > Gilles > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org > > For additional commands, e-mail: dev-help@commons.apache.org > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org For additional commands, e-mail: dev-help@commons.apache.org