On Sat, Apr 9, 2011 at 1:16 PM, Boyko Bantchev <[email protected]> wrote: > In the thread on /\ I wrote that, in my opinion, the Dictionary is > unclear as to what u/y returns when 1=#y. Several people responded > that, as u must apply between items of y, when there is only one > item -- so there is no `between' -- the result is that item. > > Surely, this is how we all understand and use /, but my point is that > we do so by plausible guessing. The said interpretation is intuitive, > and of course the J implementation confirms it, but it is still > guessing; it does not follow formally from the Dictionary text.
I am lost here: What other formal interpretations are plausible? > Similarly, how do we know that u/y applies u from right to left along > the list? As the Insert article of the Dictionary says nothing > explicitly, it is again plausible guessing. J verbs execute right to left? > Further on, compared to Haskell's folds or other similar functions, > the definition (or behaviour) of u/y seems anomalous in two ways. > First, u has actual relevance for 1<#y and 0=#y but not for 1=#y, > which is in between. Second, for 1=#y, u is *really* irrelevant, > to the effect that, e.g., +/'z' -- a meaningless expression -- > has a definite value, 'z', and consequently so do +/\'z' and +/\.'z'. It's not meaningless, it's an identity. And it's an identity only for the zero rank case. -- Raul ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
