article on J concepts 
Author Message
 article on J concepts

The following represent corrections to the article on J concepts I sent
out to the
newsgroup a few weeks ago.  If you have saved the article, please insert
these as
corrections, or wait until the final article is archived in a suitable
APL archive, or
published appropriately.

These corrections represent the outcome of review by others, and
incorporate material from papers in proceedings of APL95.  Any errors
are my own.
Feel free to message me with comments and/or corrections, if any.

---- RL

VERBS
Verbs are "functions".
A verb takes one or two arguments (nouns), and returns one result (a
noun).
A verb used "monadically" takes one argument on the right.
A verb used "dyadically" takes one argument on the left and one on the
right.
A verb may be used both monadically and dyadically.  This is called
"ambivalence".
Note: Primitive ambivalent verbs often have unrelated meanings in the
monadic and
dyadic cases.

RANK
Nouns may be viewed as sets of cells.  Cells have rank.
Verbs (primitive or defined) have (intrinsic) rank.
Every verb applies to cells of its arguments.  The cell may be the
entire noun.  The rank
of the verb determines the rank of these cells.
The "rank" conjunction and a rank specifier "x" may be used with any
verb to derive a
new verb with "intrinsic" rank x.  The new verb applies the original
verb (with its
intrinsic rank) to every cell of rank "x".  (Note: This process should
NOT be viewed as
changing the rank of the original verb.)

ADVERBS
Adverbs are in the class of "operators".
Adverbs are "function modifiers".
An adverb ALWAYS takes one argument on its left (a noun or a verb), and
returns one
result (a noun, verb, adverb, or conjunction).
Note: For the primitive adverbs of J, the most common argument is a
verb, and the most
common result is a verb.

CONJUNCTIONS
Conjunctions are in the class of "operators".
Conjunctions are typically used to modify functions, create new
functions, combine
functions ("function composition"), etc.
A conjunction is ALWAYS dyadic (arguments are either nouns or verbs) and
returns
one result (a noun, verb, adverb, or conjunction).
Note: For the primitive conjunctions of J, the most common result is a
verb.

GERUNDS
A gerund is a character noun that may used as a verb.
Verbs taking character arguments can manipulate gerund arguments (as
nouns).
There is also a set of primitives that take gerunds as arguments to
produce verbs (e.g.
the "agenda" conjunction).

PARSING
Parsing involves the rules for evaluating expressions. (An expression is
simply more
than one "operation" specified in a line).
The parsing rules are precisely defined by the stack and "parse table"
of Section E, and
the "train table" of Section F of the J Dictionary.
The precisely stated parsing rules may be paraphrased and conceptualized
informally in
various ways, among them the following:
(1) Always execute expressions within parentheses first.  This simple
rule explains
"mysteries" such as why 2 (+ % -) 10 is evaluated as an expression with
a "fork train"
whereas 2 + % - 10 is not; and why ('ab';'de') =. 1 2 is evaluated as
"indirect
assignment".
(2) Operators - Operators (adverbs and conjunctions) are executed before
verbs.
(3) Operators - The left argument is the longest operator sequence.  The
right argument
is the noun or verb to the right.
(4) Verbs - No hierarchy of precedence among verbs.
(5) Verbs - The left argument is the noun immediately to the left, the
right argument is
the noun (or expression resulting in a noun) to the right.
(6) Verbs - A sequence of verbs ending with a noun may be READ from left
to right.
(7) A train is an "isolated sequence" and may be defined as a verb,
adverb, or
conjunction.

----- end of message



Sun, 18 Jan 1998 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. JS-EAI with *JS*-callback

2. js.exception 3279.js

3. Physical concepts lead to Abstract concepts

4. Physical concepts lead to Abstract concepts

5. Concept Languages (was:Re: Paper Available: Theorem Proving, Concept Languages)

6. Silly Articles (Articles or misplaced ones).

7. NB. gray.js: a J verb that generates a grayscale postscript image from a 2d array

8. lapackTest.js

9. profile.js

10. J script file profile.js

11. JS valueOf() in RB ?

12. JS for functional programming?

 

 
Powered by phpBB® Forum Software