Mnemonics: Difference between revisions

Jump to navigation Jump to search
1,462 bytes added ,  23:17, 26 April 2022
(9 intermediate revisions by 3 users not shown)
Line 1: Line 1:
__FORCETOC__
__FORCETOC__
'''Mnemonics''' can assist with remembering the meaning of APL [[glyph]]s where on they keyboard they are found for [[typing glyphs|typing them]]. Both of these skills are essential for an effective APL programmer. This article provides such aide-mémoires.
'''Mnemonics''' can assist with [[learning resources|learning]] the meaning of APL [[glyph]]s and where on they keyboard they are found for [[typing glyphs|typing them]]. Both of these skills are essential for an effective APL programmer. This article provides such aide-mémoires.
== Pairing glyphs with their meaning ==
== Pairing glyphs with their meaning ==


Line 38: Line 38:
<source lang=apl inline>⍺</source> and <source lang=apl inline>⍵</source> are the leftmost and rightmost letters of the [[wikipedia:Greek alphabet|Greek alphabet]]. They therefore denote the left and right arguments of [[dfn]]s, respectively.
<source lang=apl inline>⍺</source> and <source lang=apl inline>⍵</source> are the leftmost and rightmost letters of the [[wikipedia:Greek alphabet|Greek alphabet]]. They therefore denote the left and right arguments of [[dfn]]s, respectively.


<source lang=apl inline>∊</source> is the Greek letter [[Epsilon]] which corresponds to the letter **E** for [[Enlist]] and [[Element of]].
<source lang=apl inline>∊</source> is the Greek letter [[Epsilon]] which corresponds to the letter ''E'' for [[Enlist]] and [[Element of]].


<source lang=apl inline>⍴</source> is the Greek letter [[Rho]] which corresponds to the letter **R** for [[Reshape]].
<source lang=apl inline>⍴</source> is the Greek letter [[Rho]] which corresponds to the letter ''R'' for [[Reshape]].


<source lang=apl inline>~</source> is [[Not]] when monadic, but its dyadic form, [[Without]], can also be remembered as ''but not''.
<source lang=apl inline>~</source> is [[Not]] when monadic, but its dyadic form, [[Without]], can also be remembered as ''but not''.
Line 48: Line 48:
<source lang=apl inline>↑</source> and <source lang=apl inline>↓</source> ([[Mix]] and [[Split]]) increase and decrease rank (if possible) when used monadically.
<source lang=apl inline>↑</source> and <source lang=apl inline>↓</source> ([[Mix]] and [[Split]]) increase and decrease rank (if possible) when used monadically.


<source lang=apl inline>↓</source> [drop]]s elements, and so it points down, the direction in which things are dropped. Take uses <source lang=apl inline>↑</source> by analogy.
<source lang=apl inline>↓</source> [[drop]]s elements, and so it points down, the direction in which things are dropped. Take uses <source lang=apl inline>↑</source> by analogy.


<source lang=apl inline>⍳</source> is the Greek letter [[Iota]] which corresponds to the letter **I** for [[Index generator]] and [[Index of]].
<source lang=apl inline>⍳</source> is the Greek letter [[Iota]] which corresponds to the letter ''I'' for [[Index generator]] and [[Index of]].


<source lang=apl inline>⍸</source> is also the Greek letter [[Iota]] which corresponds to the letter **I** for [[Indices]] and [[Interval Index]].
<source lang=apl inline>⍸</source> is also the Greek letter [[Iota]] which corresponds to the letter ''I'' for [[Indices]] and [[Interval Index]].


<source lang=apl inline>○</source> is a circle for [[Circular]] functions and the ratio between the circumference and the diameter of a circle, [[Pi times|Pi]].
<source lang=apl inline>○</source> is a circle for [[Circular]] functions and the ratio between the circumference and the diameter of a circle, [[Pi times|Pi]].


<source lang=apl inline>⍥</source> and <source lang=apl inline>⍤</source> ([[Over]] and [[Atop]]) both apply the left operand after the right operand. However, <source lang=apl inline>⍥</source> has a larger "circle of influence" in that it applies the its right operand twice (once on each argument) while <source lang=apl inline>⍤</source> only applies it once (between the arguments).
<source lang=apl inline>⍥</source> and <source lang=apl inline>⍤</source> ([[Over]] and [[Atop]]) both apply the left operand after the right operand. However, <source lang=apl inline>⍥</source> has a larger "circle of influence" in that it applies its right operand twice (once on each argument) while <source lang=apl inline>⍤</source> only applies it once (between the arguments).


<source lang=apl inline>*</source> and <source lang=apl inline>⍣</source> repeatedly apply multiplication and a function, respectively. The star symbolises [[power (function)]]/[[power (operator)]].
<source lang=apl inline>*</source> and <source lang=apl inline>⍣</source> repeatedly apply multiplication and a function, respectively. The star symbolises [[power (function)]]/[[power (operator)]].
Line 75: Line 75:
<source lang=apl inline>⌈</source> and <source lang=apl inline>⌊</source> can also be seen as indicators on a vertical number line, pointing at the [[maximum]] and [[minimum]], respectively.
<source lang=apl inline>⌈</source> and <source lang=apl inline>⌊</source> can also be seen as indicators on a vertical number line, pointing at the [[maximum]] and [[minimum]], respectively.


<source lang=apl inline>∇</source> is an upside-down Greek [[Delta]], which corresponds to the letter **D** for [[Defined function]] or (own) definition (for recursion).
<source lang=apl inline>∇</source> is an upside-down Greek [[Delta]], which corresponds to the letter ''D'' for [[Defined function]] or (own) definition (for recursion).
 
<source lang=apl inline>⌸</source> ([[Key]]) applies a function for each collection of all elements that are [[equal]] (<source lang=apl inline>⌸</source>).


<source lang=apl inline>≡</source> can be see as a stack of layers. When used monadically, it finds the [[depth]] of an array.
<source lang=apl inline>≡</source> can be see as a stack of layers. When used monadically, it finds the [[depth]] of an array.


<source lang=apl inline>≢</source> looks like a [[tally]] mark.
<source lang=apl inline>≢</source> looks like a [[tally]] mark. It being sideways can be justified by it counting the length of the leading axis; the vertical axis of a matrix.


<source lang=apl inline>⊂</source> [[enclose]]s its argument in a layer of nesting, and [[Disclose]] uses <source lang=apl inline>⊃</source> by analogy. <source lang=apl inline>⊆</source> is exactly like <source lang=apl inline>⊂</source> except that it only does a [[conditional enclose]], namely only if the argument is [[simple]].
<source lang=apl inline>⊂</source> [[enclose]]s its argument in a layer of nesting, and [[Disclose]] uses <source lang=apl inline>⊃</source> by analogy. <source lang=apl inline>⊆</source> is exactly like <source lang=apl inline>⊂</source> except that it only does a [[conditional enclose]], namely only if the argument is [[simple]].
Line 85: Line 87:
<source lang=apl inline>⊂</source> and <source lang=apl inline>⊆</source> enclose at specific locations, per a specification, so their dyadic forms are [[Partitioned enclose]] and [[Partition]], respectively.
<source lang=apl inline>⊂</source> and <source lang=apl inline>⊆</source> enclose at specific locations, per a specification, so their dyadic forms are [[Partitioned enclose]] and [[Partition]], respectively.


<source lang=apl inline>∪</source> is a styled letter ''U'' for [[Unique]].
<source lang=apl inline>∪</source> is a styled letter ''U'' for [[Unique]] or [[Union]] if used dyadically.


<source lang=apl inline>⊥</source> looks like the [[base]] of a pillar. [[Antibase]] uses <source lang=apl inline>⊤</source> by analogy.
<source lang=apl inline>⊥</source> looks like the [[base]] of a pillar. [[Antibase]] uses <source lang=apl inline>⊤</source> by analogy.


<source lang=apl inline>⍝</source> looks like a [[filament lamp]] and provides enlightenment by indicating [[comment]]s.
[[File:Lamp bulb.png|thumb|The [[Lamp]] glyph <source lang=apl inline>⍝</source> looks like a a lamp bulb filament.]]
<source lang=apl inline>⍝</source> looks like a [[wikipedia:filament lamp|filament lamp]] and provides enlightenment by indicating [[comment]]s.


<source lang=apl inline>,</source> [[concatenate]]s arrays, much like the common punctuation symbol concatenates phrases. <source lang=apl inline>⍪</source> has an added styled row, indicating that for matrices, it concatenates additional rows.
<source lang=apl inline>,</source> [[concatenate]]s arrays, much like the common punctuation symbol concatenates phrases. <source lang=apl inline>⍪</source> has an added styled row, indicating that for matrices, it concatenates additional rows.
Line 108: Line 111:
<source lang=apl inline>¨</source> applies a function to each 1 of the argument elements, so it is on <kbd>APL</kbd>+<kbd>1</kbd>.<br>
<source lang=apl inline>¨</source> applies a function to each 1 of the argument elements, so it is on <kbd>APL</kbd>+<kbd>1</kbd>.<br>
<source lang=apl inline>⌶</source> looks like a [[wikipedia:Roman numerals|Roman numeral]] 1, so it also lives on the <kbd>1</kbd>.
<source lang=apl inline>⌶</source> looks like a [[wikipedia:Roman numerals|Roman numeral]] 1, so it also lives on the <kbd>1</kbd>.
<source lang=apl inline>¯</source>, <source lang=apl inline><</source>, <source lang=apl inline>≤</source>, <source lang=apl inline>=</source>, <source lang=apl inline>≥</source>, <source lang=apl inline>></source>, and <source lang=apl inline>≠</source> form a block. The number line 1–9 (because 0 on the far right) is split into two [[equal]] halves by <kbd>5</kbd> so that gives <source lang=apl inline>=</source>. <kbd>4</kbd> and <kbd>6</kbd> are slightly less and more, respectively, so they give <source lang=apl inline>≤</source> and <source lang=apl inline>≥</source>. <kbd>3</kbd> and <kbd>7</kbd> are much less and more, respectively, so they give <source lang=apl inline><</source> and <source lang=apl inline>></source>. Finally, <kbd>2</kbd> is so much less that it is negative, giving the negative sign <source lang=apl inline>¯</source>, and <kbd>8</kbd> is so much greater that it is completely [[not equal|unequal]], <source lang=apl inline>≠</source>.
{{APL development}}{{APL glyphs}}
{{APL development}}{{APL glyphs}}
[[Category:APL character set]]
[[Category:APL character set]]

Navigation menu