On Thu, Apr 12, 2012 at 1:12 PM, Paul Jackson <plj...@gmail.com> wrote: > Thanks for the links. Toc191734495 describes much of what I've seen. It > also explains how modifiers which ignore x and y arguments preceeded > current derived verbs. However, based on my tests, the information there > is not sufficient to avoid the value error I initially reported. > > 1) It isn't just the presence of x or y which creates derived verbs. > Derived adverbs must contain > (u OR m) AND (x OR y). > For derived conjunctions, I assume the first list is > (u OR m OR v OR n), > but I haven't done a complete analysis.
Yes, and no. The rules for names for adverbs are the same as the rules for conjunctions. That said, the above is not necessary for "derived adverbs" or "derived conjunctions" instead, it's about evaluation the explicit definition of the adverb or conjunction to be delayed until verb evaluation time. Here's an example of a derived adverb: prod=: 1 :0 (+/ .*&m)@ ) (i.2 2) prod +/ .*&(i.2 2)@ %. (i.2 2) prod +/ .*&(i.2 2)@%. %. (i.2 2) prod i. 2 2 1 0 0 1 > 2) The presence of x only counts in the dyadic form. If a > reference of x is present in the monadic form, it is > one of the following. > If this modifier is immediate, another copy of u > for historical reasons. > If this is a derived modifier, a reference to the global x. Here's a counter example: M=:1 :0 : x +/ .* m +/ .* y ) (i. 2 2) M (i.2 2) (1 : (':'; ' x +/ .* m +/ .* y')) (i. 2 2) (i. 2 2) M i. 2 2 6 11 22 39 Here's a different kind of counter example: 'hi!' 1 :'m return. x' 'hi!' (1 : 'm return. x') 'hi!' 1 :'m return. x' 9 hi! > 3) The immediate versions of Adverbs only use the > monadic definition, and > immediate Conjunctions prefer the dyadic definition. I am not sure what an immediate version is. But there are multiple contexts for "monadic" and "dyadic" here. One context is the explicit definition of the adverb (monadic) or conjunction (dyadic). Another context is about which definition of the resulting verb is being used (if there is a resulting verb). But it sounds like you are getting close to understanding how this actually works. With a few more questions and examples, we can probably get you there. That said, here's an attempt at giving it to you all at once: NV A -> NVAC NV C NV -> NVAC N: noun V: verb A: adverb C: conjunction An adverb takes a noun or verb and produces a noun, a verb, an adverb or a conjunction. This happens at "parse time". A conjunction takes a noun or verb and another noun or verb and produces a noun, a verb, an adverb or a conjunction. This happens at "parse time". In an explicit definition, the definition can be used at "parse time" OR at "execution time". By default, the explicit definition is used at "parse time". However, if the definition contains the name x or the name y AND if it contains the name m, the name n, the name u or the name v, then the definition is not used until execution time. (If the explicit definition of an adverb or conjunction is deferred to "execution time", that means that the "parse time" operation is Currying of that explicit definition. https://en.wikipedia.org/wiki/Currying) An example of a conjunction which can produce a noun, a verb, an adverb or a conjunction is : NOUN=: 0 :'' ADVERB=: 1 :'' CONJUNCTION=: 2 :'' VERB=: 3 :'' NB. or a few other options That said, note a : defined adverb, conjunction or verb with an empty explicit body has an empty domain. -- Raul ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm