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 D5BFF183D8 for ; Thu, 31 Dec 2015 17:11:13 +0000 (UTC) Received: (qmail 49103 invoked by uid 500); 31 Dec 2015 17:11:13 -0000 Delivered-To: apmail-commons-dev-archive@commons.apache.org Received: (qmail 48947 invoked by uid 500); 31 Dec 2015 17:11: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 48935 invoked by uid 99); 31 Dec 2015 17:11:12 -0000 Received: from Unknown (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 31 Dec 2015 17:11:12 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 4D1751A0410 for ; Thu, 31 Dec 2015 17:11:12 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.02 X-Spam-Level: X-Spam-Status: No, score=-0.02 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (1024-bit key) header.d=scarlet.be Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id 4Ha0cyVI6KNg for ; Thu, 31 Dec 2015 17:11:05 +0000 (UTC) Received: from sif.is.scarlet.be (sif.is.scarlet.be [193.74.71.28]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTPS id 29A302050E for ; Thu, 31 Dec 2015 17:11:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=scarlet.be; s=scarlet; t=1451581856; bh=2Hvj21X1O0RWrUaJWdtlksb/jyyBxD+s3gP0QOUL9tI=; h=MIME-Version:Content-Type:Content-Transfer-Encoding:Date:From:To: Subject:In-Reply-To:References:Message-ID; b=ECu827XU3WkMJq3H+xd1KppuDRaF6367h/hufYqY3ttUU/+t0JCCEeHsHhZsqMWC8 aUunhRBkXuwEHXGe2Fy/j/tVKvzi5GSoJ5HG7a2lQa3/ZTeTcqnH6DBqsXePiPNTsU rxbeWVrppQORUCQz9Ch0prRjMQjqcwXLjQ763wOY= Received: from webmail.scarlet.be (meigs.is.scarlet.be [193.74.71.216]) by sif.is.scarlet.be (8.14.9/8.14.9) with ESMTP id tBVHAthI014226 for ; Thu, 31 Dec 2015 18:10:56 +0100 X-Scarlet: d=1451581856 c=193.74.71.216 Received: from ip-83-134-180-8.dsl.scarlet.be ([83.134.180.8]) via ip-83-134-180-8.dsl.scarlet.be ([83.134.180.8]) by webmail.scarlet.be with HTTP (HTTP/1.1 POST); Thu, 31 Dec 2015 18:10:54 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Date: Thu, 31 Dec 2015 18:10:54 +0100 From: Gilles To: Subject: Re: [math] RealMatrixFormat.parse() In-Reply-To: <5684A224.9060203@gmail.com> References: <5684A224.9060203@gmail.com> Message-ID: <613a9ec28dd49b4c493fc39b24962a09@scarlet.be> X-Sender: gilles@harfang.homelinux.org User-Agent: Scarlet Webmail X-DCC-scarlet.be-Metrics: sif; whitelist X-Virus-Scanned: clamav-milter 0.98.1-exp at sif X-Virus-Status: Clean On Wed, 30 Dec 2015 21:33:56 -0600, Ole Ersoy wrote: > Hi, > > In RealMatrixFormat.parse() MatrixUtils makes the decision on what > type of RealMatrix instance to return. Ideally, this is correct as the actual type is an "implementation detail". > Flexibility is gained if it > just returns double[][] letting the caller decide what type of > RealMatrix instance to create. That could become a problem e.g. for sparse matrices where the persistent format and the instance type could be optimized for space, but a "double[][]" cannot be. > It's also better for modularity, as is > reduces RealMatrixFormat imports (The MatrixUtils supports Field > matrices as well, and I'm attempting to separate real and field > matrices into two difference modules). For modularity, IO should not be in the same module as the core algorithms. > Also just curious if Array2DRowRealMatrix is worth keeping? It seems > like the performance of BlockRealMatrix might be just as good or > better regardless of matrix size ... although my testing is limited. I recall having performed a benchmark years ago and IIRC, the "BlockRealMatrix" started to be more only for very large matrix size (although I don't remember which). Regards, Gilles --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org For additional commands, e-mail: dev-help@commons.apache.org