[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Removing broadcasting from Octave
From: |
John W. Eaton |
Subject: |
Re: Removing broadcasting from Octave |
Date: |
Thu, 15 Dec 2011 10:56:45 -0500 |
On 15-Dec-2011, Judd Storrs wrote:
| If you sat down to describe this to anyone you would never use the
| word "broadcast". It's quite a boring and confusing phrase for an
| exciting feature.
I have no problem with the term. It sure beats bsxfun.
| "Broadcast" to me (and probably anyone) conjures a sense of
| communication or signaling not duplication. It's a really unexpected
| use. I can't imagine telling anyone about this feature and using the
| word "broadcast" without also having to redefine their understanding
| of the word "broadcast". This should be a key feature to lord over
| Matlab users, but this phrasing is just suicide.
That seems a bit dramatic.
How about the following as a NEWS file entry?
Many of Octave's binary operators (.*, .^, +, -, ...) now perform
automatic broadcasting for array operations that allows you to use
operator notation instead of calling bsxfun or expanding arrays (and
unnecessarily wasting memory) with repmat or similar idioms. For
example, to scale the columns of a matrix by the elements of a row
vector, you may now write
r .* M
In this expression, the number of elements of r must match the
number of columns of M. The following operators are affected:
plus ldivide rem eq gt xor
minus power mod ne ge
times max atan2 lt and
rdivide min hypot le or
+ .* &
- ./ |
.+ .\
.- .^
+= .*= &=
-= ./= |=
.+= .\=
.-= .^=
See the new "Broadcasting Operations" chapter in the manual for more
details.
I don't think there's any need to mention numpy in the news entry.
Now we just need the new chapter for the manual that describes this
new feature in more detail.
jwe
- Re: Removing broadcasting from Octave, (continued)
- Re: Removing broadcasting from Octave, fork, 2011/12/14
- Re: Removing broadcasting from Octave, John W. Eaton, 2011/12/15
- Re: Removing broadcasting from Octave, Juan Pablo Carbajal, 2011/12/15
- Re: Removing broadcasting from Octave, Jordi Gutiérrez Hermoso, 2011/12/15
- Re: Removing broadcasting from Octave, Søren Hauberg, 2011/12/15
- Re: Removing broadcasting from Octave, Jordi Gutiérrez Hermoso, 2011/12/15
- Re: Removing broadcasting from Octave, Judd Storrs, 2011/12/15
- Re: Removing broadcasting from Octave,
John W. Eaton <=
- Re: Removing broadcasting from Octave, Michael Creel, 2011/12/15
- Re: Removing broadcasting from Octave, fork, 2011/12/15
- Re: Removing broadcasting from Octave, Jordi Gutiérrez Hermoso, 2011/12/15
- Re: Removing broadcasting from Octave, Michael D Godfrey, 2011/12/15
- Re: Removing broadcasting from Octave, Przemek Klosowski, 2011/12/15
- Re: Removing broadcasting from Octave, fork, 2011/12/15
- Re: Removing broadcasting from Octave, John W. Eaton, 2011/12/15
- Re: Removing broadcasting from Octave, Judd Storrs, 2011/12/15
- Re: Removing broadcasting from Octave, John W. Eaton, 2011/12/14
Re: Removing broadcasting from Octave, Przemek Klosowski, 2011/12/14