Yes, or you might have an expression like 3 2 0 p. x which relies on the 
definition of  x+0  without explicitly stating it, or without the author of the 
expression even knowing it (see Ambrus' comments later in this thread).

In other words, you need identities to make algebra reliable.  In other words, 
edge cases are the bane of formalisms (and one of the joys of J is that so very 
often it handles them elegantly and transparently.  This feature is mostly 
derived from the thoughtful and sometimes seemingly prophetic definitions of 
its words).  In other words, the more guarantees J makes, the less I have to 
worry (including worrying about whether I should be worrying, as you & Roger 
are doing).

Anyway, if you're looking for an analog to x+y , then think about modifiers 
like  "f  (or 1 :'u"f' or whatever) which one would like to "work" without 
worrying about the value of the argument (even if sometimes it's exactly f).  
Yes, abstractions over verbs are rarer than abstractions over nouns (and J's 
grammar encourages this, viz Lisp), but they are not insignificant, and I 
personally make great use of them [1].

Bear in mind, I am not arguing for or against Ambrus' proposal (which I still 
haven't had time to study).  I am only pointing out 'who needs f"f ?' is not an 
argument against it and is invidious logic.

It is obvious that f -: f"f should be a tautology ("f is the same as f with the 
rank of f"); we can choose to sacrifice this self-consistency for some benefit, 
but we should do so consciously and for good reasons (not because we can't 
think of uses for self-consistency).

-Dan


[1] We all know modifiers are one of J's strengths - we have +/  */ and ^/ 
where math has big-sigma, big-pi and big-nada respectively.



Please excuse typos; composed on a handheld device.

-----Original Message-----
From: Raul Miller <[email protected]>
Sender: [email protected]
Date: Wed, 10 Nov 2010 12:57:58 
To: Programming forum<[email protected]>
Reply-To: Programming forum <[email protected]>
Subject: Re: [Jprogramming] Atop u...@v with v of negative monadic rank

On Wed, Nov 10, 2010 at 10:29 AM, Dan Bron <[email protected]> wrote:
> Why would you ever say x+0 or y*1 ?

I am not sure that I do?

But I might say x+y where y was 1 0 1.

-- 
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to