bug-apl
[Top][All Lists]
Advanced

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

Re: [Bug-apl] an other inner product ,., bug


From: Juergen Sauermann
Subject: Re: [Bug-apl] an other inner product ,., bug
Date: Mon, 21 May 2018 15:33:29 +0200
User-agent: Mozilla/5.0 (X11; Linux i686; rv:52.0) Gecko/20100101 Thunderbird/52.3.0

Hi Jay,

I believe that when they wrote the ISO standard they were still used to the old APL, where
f and g had to be scalar functions and then f/A g B of two vectors would anyhow be a scalar,
and therefore they simply forgot to enclose the result of
f/A g B.

/// Jürgen


On 05/21/2018 12:27 PM, Jay Foad wrote:
If you followed this part of the ISO standard verbatim then:

2 3 +.⍴ 4 5  ←→  +/2 3 ⍴ 4 5  ←→  13 14

GNU APL and APL2 actually return ⊂13 14 which seems more sensible. I am not sure why ISO has (or needs) that special case. It seems wrong to me.

Jay.

On 18 May 2018 at 16:03, Juergen Sauermann <address@hidden> wrote:
The ISO standard follows suit, except that it has a special case for A and B being vectors:

"If A and B are both vectors, return f/A g B."   (ISO standard, page 121 with A=A1 and B=B1).

GNU APL follows the ISO standard

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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