[J-learn] For your spare time during the holidays (and after)
Arthur Anger
Anger at MIT.EDU
Tue Dec 21 01:02:43 EST 2010
Friends--
While I was considering the possibility of teaching a course on J in January, I
began writing a more organized introduction than I had used in my first
presentation. Since my current local prospects have not said they would
attend, I have not advertised a course at this time. Not to let these notes
languish totally unread until next year, I am passing them on to those who have
expressed some interest in the past.
I spend much of my time attempting various projects in J. I find its syntax and
array structures mathematically beautiful, its array processing concise and
convenient, its functional orientation intelligent and flexibly applicable, and
its interactive implementation quite productive. Native J statements tend to
bristle with periods, colons, and parentheses, and use various brackets in
non-bracketing ways, so I recommend frequent resort to English equivalents to
the special-character operation names. The real challenge to learning the
language is to train your thoughts about data collections to emphasize
whole-array processes, more than element-by-element steps. Several times I
have puzzled long over strange results or non-results because I overlooked an
array's extra axis or a potentially empty result, or imprecisely specified
which sub-arrays were to be combined.
Best wishes for whatever you do in this holiday season! If and when you choose
to delve into this endeavor, I remain willing to attempt to answer any inquiry
you may have about it.
--Art Anger
-----------------
Introductory notes for J programming language
Before exploring any numerical operations, we look first at how
collections of values in J are entered, stored, rearranged, and selected.
How you name, group, and structure the data you work with can strongly
influence how you approach your computations and, thus, how correctly
and how efficiently the computer will handle them.
J provides various means of building data into structures, examining or
modifying portions of them, and restructuring, combining, or splitting
them as needs change. It is in part a toolkit for playing or working
with "building blocks". Some of the power of these tools comes from
the integration of logical and relational decisions with arithmetical
steps when selecting structural components or even the operations to
be performed on them.
all J values are arrays--arrangements of "scalar" values as atoms
(themselves), lists, rectangular lattices (tables), hyper-rectangles, etc.
rank of an array is the number of independent index/selector axes.
htu=. 0 100 200 +Table 0 10 20 +Table 0 1 2
htu=. 0 100 200 +/ 0 10 20 +/ 0 1 2
htu
0 1 2
10 11 12
20 21 22
100 101 102
110 111 112
120 121 122
200 201 202
210 211 212
220 221 222
Table adverb modifies Add verb, in two occurrences.
"English" equivalents for built-in "ASCII" names may be used after you:
Open browser tab or window to: http://www.jsoftware.com/jwiki/ArtAnger/
Click on: get, for: Aliases.ijs
Click on: Download
Find the downloaded script and move it to your J user directory
Perform in execution window: load '~user/Aliases.ijs'
ShapeOf htu
$ htu
3 3 3
ShapeOf ShapeOf htu
$ $ htu
3
ShapeOf shows 3 layers (along axis 0--"hundreds") of 3 rows (axis 1--"tens")
of 3 columns (axis 2--"units").
.
.
.
(Full text is in the attachment.)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Aliases.ijs
Type: application/octet-stream
Size: 17959 bytes
Desc: not available
Url : http://mailman.mit.edu/pipermail/j-learn/attachments/20101221/f4c213f0/attachment.obj
More information about the J-Learn
mailing list