Raul wrote:
> Or, for something written [on gerunds] by Ken Iverson rather than Roger
> Stokes:
> http://www.jsoftware.com/help/dictionary/d610.htm
AFAICT, there are two open questions about gerunds in this thread:
1. Are gerunds necessarily vectors?
The material referenced doesn't address this; the only relevant passage is:
"The tie applies to two verbs to produce a gerund."
which no more constrains "gerund" than "the append (,) applies to two nouns to
produce a list" constrains "noun". All products of ` are gerunds, but that
doesn't mean all gerunds are products of ` .
2. Can gerunds carry representations of non-verbs?
Again, the material isn't prescriptive; it (explicitly) discusses gerunds in
the context of English, not J:
> In English, a gerund is a noun that carries the force of a verb
... but the implication is much stronger here. And certainly most material
that touches on gerunds assumes they represent only verbs. So, (2) is a harder
case to make, and I could be convinced to agree that in J, gerunds a noun which
carry the force of (only) verbs.
But (a) I enjoy tacit adverbial programming, which often involves arrays of
atomic representations of non-verbs, if I can't call those "gerunds", then I
might have to come up with a new word, or even vocabulary. And (b):
atomic_rep =: 1 : 'if. noun = nc un=.{.;:''u'' do. un else. {.u`''
end.'
VERB_AR =: ; atomic_rep
CONJ_AR =: ':' atomic_rep
3 VERB_AR`[email protected] 'hi there'
+-+--------+
|3|hi there|
+-+--------+
3 VERB_AR`[email protected] 'hi there'
3 : 'hi there'
2 ^^:([`('"' atomic_rep)`]) 0 1 2
2 4 16
So I'd prefer to agree that gerund means "array of atomic representations".
-Dan
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Raul Miller
Sent: Saturday, February 18, 2012 2:07 PM
To: Programming forum
Subject: Re: [Jprogramming] Verb display in function tables
Or, for something written by Ken Iverson rather than Roger Stokes:
http://www.jsoftware.com/help/dictionary/d610.htm
--
Raul
On Sat, Feb 18, 2012 at 2:04 PM, Raul Miller <[email protected]> wrote:
> Here's an example of a definition for gerund:
>
> http://www.jsoftware.com/docs/help701/learning/14.htm
>
> You might argue that the definition is informal -- like most of J --
> but I do not think it's fair to say that they are not defined
> anywhere.
>
> --
> Raul
>
> On Sat, Feb 18, 2012 at 1:10 PM, Dan Bron <[email protected]> wrote:
>> I'm not sure gerunds are defined anywhere.
>>
>> But if they were, the phrasing might be "arrays of atomic representations",
>> where the "atomic representation" characteristic is the most salient, and
>> "array" has the normal meaning (and perhaps the usual question of whether a
>> scalar is an array?).
>>
>> We often (informally) think of gerunds as vectors, because we compose them
>> with ` whose product is defined to be vector, and consume them with e.g. @.
>> whose (left input) is most useful when vector. �But that's no reason to
>> define gerunds as vectors, any more than to define selections as vectors,
>> because we compose them with �, �, and consume them with e.g. { whose (left
>> input) is frequently vector. Or saying 'string' is a string but 's' is not.
>>
>> Of course, in some contexts, 's' is not considered a string. �So perhaps you
>> are suggesting that "gerunds are are arrays of atomic representations, where
>> the shape of the array has meaning"? �If so, �this is an interesting
>> digression, which I'm happy to discuss, but perhaps we should move it to a
>> different thread.
>>
>> The original question was not concerned with gerunds, and I doubt having the
>> atomic representation of �f@g �(vector or scalar) in the corner of the
>> result table would be satisfying. What was wanted was the string
>> representation (which is produced using 5!:5, which operates on scalars, so
>> shape doesn't have meaning to it, and neither does atomic representation).
>>
>> Anyway, when present the promise of J to newcomers, we need to take care not
>> obscure the pitfalls. �The literal Jenie (dJinni?) who delivers exactly what
>> was asked for is rarely the hero of folklore.
>>
>> -Dan
>>
>> PS: �If we wish to continue the digression, it might be better to start with
>> the links below, �better starting point would be wh
>>
>> �Here's a couple places where I've attempted to capture the meaning of
>> "gerund"
>>
>> Sidebar in NuVoc definition of ` :
>> http://jsoftware.com/jwiki/Vocabulary/backtick#sidebar.3Agerunds
>>
>> As a necessary premise in the definition of a modifier utility:
>> www.jsoftware.com/jwiki/DanBron/Snippets/DOOG#definition
>>
>> Please excuse typos; composed on a handheld device.
>>
>> -----Original Message-----
>> From: Raul Miller <[email protected]>
>> Sender: [email protected]
>> Date: Sat, 18 Feb 2012 11:52:13
>> To: Programming forum<[email protected]>
>> Reply-To: Programming forum <[email protected]>
>> Subject: Re: [Jprogramming] Verb display in function tables
>>
>> Ok...
>>
>> ...except that gerunds are defined as vectors.
>>
>> Conceptually speaking, if it's a scalar, or a matrix, it's something
>> different. �It would still be gerund-like, in character (we can
>> trivially extract gerunds from it), but if we try using such things
>> with primitives that handle gerunds, we are getting into undocumented
>> territory.
>>
>> --
>> Raul
>>
>> On Sat, Feb 18, 2012 at 11:18 AM, Dan Bron <[email protected]> wrote:
>>> That makes sense.
>>>
>>> My personal impression was that the original vector-ness was an
>>> (unintentional) side-effect of the method used to remove the trailing atom
>>> (select-all-but-last as opposed to select-first).
>>>
>>> The proposed scalar should be a transparent replacement for the original
>>> vector, whose shape wasn't serving a specific purpose (normally, in J,
>>> shape carries meaning, and where it doesn't it is misleading: at best
>>> superfluous, but often pernicious).
>>>
>>> �-Dan
>>>
>>>
>>> Please excuse typos; composed on a handheld device.
>>>
>>> -----Original Message-----
>>> From: Raul Miller <[email protected]>
>>> Sender: [email protected]
>>> Date: Sat, 18 Feb 2012 10:41:56
>>> To: Programming forum<[email protected]>
>>> Reply-To: Programming forum <[email protected]>
>>> Subject: Re: [Jprogramming] Verb display in function tables
>>>
>>> I often do that myself, but in this case, the original phrase was also
>>> generating a 1 element vector, so I decided that a 1-element vector
>>> was an appropriate result.
>>>
>>> --
>>> Raul
>>>
>>> On Sat, Feb 18, 2012 at 9:48 AM, Dan Bron <[email protected]> wrote:
>>>> Because in many contexts, a scalar is more convenient than a 1-element
>>>> vector, I make a habit of tacking on a � {. �as in � {.u`'' �.
>>>>
>>>> -Dan
>>>>
>>>>
>>>> On Feb 18, 2012, at 9:32 AM, Raul Miller <[email protected]> wrote:
>>>>
>>>>> I would use u`''
>>>>>
>>>>> � avg 1 :'u`'''''
>>>>> +---+
>>>>> |avg|
>>>>> +---+
>>>>> � avg
>>>>> |value error: avg
>>>>>
>>>>> --
>>>>> Raul
>>>>>
>>>>>
>>>>> On Fri, Feb 17, 2012 at 1:57 PM, Edward Mokurai Cherlin
>>>>> <[email protected]> wrote:
>>>>>> I had thought that I would not be able to get a program to show the
>>>>>> definition of a function given its name, but I found a kludge for the
>>>>>> purpose using tie. Now I would like to know whether somebody has a
>>>>>> direct solution. My application for this capability is a defined
>>>>>> adverb for producing function tables.
>>>>>>
>>>>>> � t=.1 :(':';'2 2$(>1 0#u`u);y;(,.x);x u/ y')
>>>>>> � l +t l=.i.5
>>>>>> +-----------+
>>>>>> �+�0 1 2 3 4�
>>>>>> +-+---------�
>>>>>> �0�0 1 2 3 4�
>>>>>> �1�1 2 3 4 5�
>>>>>> �2�2 3 4 5 6�
>>>>>> �3�3 4 5 6 7�
>>>>>> �4�4 5 6 7 8�
>>>>>> +-----------+
>>>>>>
>>>>>> The question then is whether somebody knows a less ugly way to display
>>>>>> the value of u in executing this adverb than >1 0#u`u or >0{u`u .
>>>>>>
>>>>>> --
>>>>>> Edward Mokurai (??/???????????????/????????????? ?) Cherlin
>>>>>> Silent Thunder is my name, and Children are my nation.
>>>>>> The Cosmos is my dwelling place, the Truth my destination.
>>>>>> http://wiki.sugarlabs.org/go/Replacing_Textbooks
>>>>>> ----------------------------------------------------------------------
>>>>>> For information about J forums see http://www.jsoftware.com/forums.htm
>>>>> ----------------------------------------------------------------------
>>>>> For information about J forums see http://www.jsoftware.com/forums.htm
>>>> ----------------------------------------------------------------------
>>>> For information about J forums see http://www.jsoftware.com/forums.htm
>>> ----------------------------------------------------------------------
>>> For information about J forums see http://www.jsoftware.com/forums.htm
>>> ----------------------------------------------------------------------
>>> For information about J forums see http://www.jsoftware.com/forums.htm
>> ----------------------------------------------------------------------
>> For information about J forums see http://www.jsoftware.com/forums.htm
>> ----------------------------------------------------------------------
>> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm