bug-apl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-apl] Supporting negative ranks for ⍤ operator


From: Elias Mårtenson
Subject: Re: [Bug-apl] Supporting negative ranks for ⍤ operator
Date: Fri, 6 May 2016 21:32:17 +0800

In GNU APL, the following two expressions yield the same result:

      (+/⍤1) 3 4⍴⍳100
┏→━━━━━━━┓
┃10 26 42┃
┗━━━━━━━━┛

And:

      (+/⍤¯1) 3 4⍴⍳100
┏→━━━━━━━┓
┃10 26 42┃
┗━━━━━━━━┛

I would expect the latter to yield the following (which is what I believe Dyalog does):

┏→━━━━━━━━━━┓
┃15 18 21 24┃
┗━━━━━━━━━━━┛

Regards,
Elias

On 6 May 2016 at 21:22, Jay Foad <address@hidden> wrote:
On 6 May 2016 at 13:52, Juergen Sauermann <address@hidden> wrote:
> Except maybe for the Dyalog ¯1 case (primarily because I don't know what
> "major cells" are).

Dyalog treats ¯1 the same as the ISO standard (and therefore also GNU
APL). "Major cell" is explained on page 14 of:
http://docs.dyalog.com/14.1/Dyalog%20APL%20Programmer's%20Guide.pdf

Jay.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]