Allin et al,
95/95 votes from russian students for "Addition is addition" (matrix +
scalar is allowed, order does not matter)
Best,
Boris Demeshev,
teaching assistant
26.09.2011 11:41, Sven Schreiber пишет:
Am 09/26/2011 06:48 AM, schrieb Berend Hasselman:
> On 26-09-2011, at 03:09, Allin Cottrell wrote:
>
>> On Sun, 25 Sep 2011, Summers, Peter wrote:
>>
>>> Allin et al,
>>>
>>> <quote>
>>> Proper addition is of course commutative, but the "extended
>>> addition" that I'm talking about here maybe is not. I tend to think
>>> of the left-hand operand as the "posit", so to speak, and the
>>> right-hand operand as the increment (or decrement, in the case of
>>> subtraction). And I reckon I can attach a good sense to the case
>>> where an m x n matrix is the posit and the increment or decrement is
>>> a scalar (applied to all elements of the posit). But I feel queasy
>>> about the case where the posit is a scalar value and the
>>> increment/decrement is an m x n matrix. This seems a step too far.
>>>
>>> This may become moot if we decide to tighten up and insist on the
>>> dot operators, but I thought I'd just mention it.
>>> </quote>
>>>
>>> My first thought is that if the manual says (mxn) + scalar is
>>> allowed, then the order shouldn't matter. Addition is addition.
I strongly agree here; introducing some notion of pre- or post-addition
is certainly creative, but not helpful here IMHO.
Apart from that, given that matrix plus scalar is a case of
"broadcasting" (a term borrowed from numerical Python) as documented in
the gretl user guide also for more general cases, and given that gretl
in general uses ".+" as an operator to indicate the programmer's wish to
do that, I tend to agree with Allin to require the use of ".+" also for
the matrix plus scalar case.
Certainly not for 1.9.6, but a good case for 2.0 IMHO.
cheers,
sven
_______________________________________________
Gretl-devel mailing list
Gretl-devel(a)lists.wfu.edu
http://lists.wfu.edu/mailman/listinfo/gretl-devel