Re: [eigen] inconsistent cwise() support |

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]

*To*: eigen@xxxxxxxxxxxxxxxxxxx*Subject*: Re: [eigen] inconsistent cwise() support*From*: Gael Guennebaud <gael.guennebaud@xxxxxxxxx>*Date*: Wed, 18 Nov 2009 16:06:07 +0100*Dkim-signature*: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=lb3RxaYIjspEptk2Q0MmDPTW/c5xseLK16NC79wQC14=; b=rfR+bgGykMyWOVF4DTfrt29jUlV41on1qfAO2dRZgCrQdUcrRKAVXpiNNr0GO5yXcm MM2NnAx0aUjT0BgZ0VmX0PGxtFWcpDjt/fYLPPWfSpN7S+qz1e05ROkgg6JFXAgBlsrd zOjG1MQZ2SOCMol2AZNsV4eTLdchq+y66O8RE=*Domainkey-signature*: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=ieABUBsB/uNCB/G3uSAYDf6bw+Ahwy/jQiDAbUyj1AKxPHnvTKn6J06M3yV50I4DMS EPLEh+fSXWyKH0efxOJQ2+9kAh5yM52KY2hK8ycxdpasDuaQXftLY3D0Zmj4YkDRgsq3 nZpqlOW4tzavnfS6laM1K94gDKoK3l+yeR1C4=

On Wed, Nov 18, 2009 at 4:00 PM, Benoit Jacob <jacob.benoit.1@xxxxxxxxx> wrote:

oops sorry.

Ok, good then I'm doing these changes in the ET-refactoring fork. I need to do them before going further. I will also move Cwise and other deprecated stuff to a new Eigen2Support module in that fork.

gael

(rewriting to make sure we agree, since you wrote 2x arrayAbs())> On Wed, Nov 18, 2009 at 3:50 PM, Benoit Jacob <jacob.benoit.1@xxxxxxxxx>

> wrote:

>>

>> >> > Yes that's what I was going to reply: I like Jitse's proposal too but

>> >> > we really don't have to provide .cwiseEverything(), only the most

>> >> > common functions,

>> >> > matrix.cwiseProduct(matrix2)

>> >> > matrix.cwiseSum(scalar)

>> >> > matrix.cwiseAbs()

>> >> > matrix.cwiseAbs2()

>> >>

>> >> Also I wonder. If matrix.cwiseAbs() is a synonym for

>> >> matrix.array().abs(), perhaps we should call that matrix.arrayAbs()?

>> >>

>> >> In other words, s/cwise/array/g ? To have only 1 terminology

>> >> everywhere.

>> >>

>> >

>> > Well, the first question is whether we still want a .array() method or

>> > not?

>>

>> Oh, I hadn't understood that was the question.

>> Do you really think that we can do without? First it would require us

>> to add a ton of cwise...() functions that will not often be used

>> (what's the use for cwiseCos() when we have a true Array class?), and

>> even then, we still wouldn't have all the power that .array()

>> provides, e.g. think of user-defined functions taking an Array...

>>

>

> ok, so at the end we would have my proposal + a couple of shortcuts covering

> the basic needs of linear algebra. Remark that m.cwiseAbs() / m.arrayAbs()

> returns a matrix _expression_ while m.arrayAbs() returns an array. So perhaps

> it is better to keep cwise for the shortcuts.

oops sorry.

So:

m.cwiseAbs() returns a matrix xpr

m.array().abs() returns an array xpr

So i agree with you, let's keep cwise and not have any method named arrayAbs().

Ok, good then I'm doing these changes in the ET-refactoring fork. I need to do them before going further. I will also move Cwise and other deprecated stuff to a new Eigen2Support module in that fork.

gael

Benoit

>

> gael.

>

>>

>> Benoit

>>

>>

>

>

>

>

**Follow-Ups**:**Re: [eigen] inconsistent cwise() support***From:*Benoit Jacob

**References**:**[eigen] inconsistent cwise() support***From:*Hauke Heibel

**Re: [eigen] inconsistent cwise() support***From:*Gael Guennebaud

**Re: [eigen] inconsistent cwise() support***From:*Jitse Niesen

**Re: [eigen] inconsistent cwise() support***From:*Gael Guennebaud

**Re: [eigen] inconsistent cwise() support***From:*Benoit Jacob

**Re: [eigen] inconsistent cwise() support***From:*Benoit Jacob

**Re: [eigen] inconsistent cwise() support***From:*Gael Guennebaud

**Re: [eigen] inconsistent cwise() support***From:*Benoit Jacob

**Re: [eigen] inconsistent cwise() support***From:*Gael Guennebaud

**Re: [eigen] inconsistent cwise() support***From:*Benoit Jacob

**Messages sorted by:**[ date | thread ]- Prev by Date:
**Re: [eigen] inconsistent cwise() support** - Next by Date:
**Re: [eigen] inconsistent cwise() support** - Previous by thread:
**Re: [eigen] inconsistent cwise() support** - Next by thread:
**Re: [eigen] inconsistent cwise() support**

Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |