Glyph reference

Each glyph has a name, which links to its definitions and examples. A function glyph also has a name for its monad, which takes one argument, and for its dyad, which takes two. Operators take functions or arrays and derive functions. Notes flag unusual differences from Dyalog APL. Each function's page gives its ranks. Given an argument of higher rank, the function is applied to each cell of that rank, as Rank does.

Typing glyphs

The keyboard map shows the Option and Option-Shift bindings, with dead keys outlined in orange.

Hold Alt, which is Option on a Mac, and press the key in the Key column. The keys are for a US keyboard layout. ≤ is Alt-< and ≥ is Alt->, each with Shift held. When the column shows a second key, press it with or without Alt held. For example, Alt-o c means Alt-o, then c. You can type a shifted second key without Shift. For example, Alt-q ; types ⍠, the same as Alt-q :. When an Alt key takes a second key, press Space or an unlisted key instead to type the Alt key's glyph. For example, Alt-o then Space gives ○. Backspace or Escape cancels the sequence.

Superscripts start with Alt-6. Type Alt-6, -, then Space for bare inverse ⁻; Alt-6 then -1 gives signed ⁻¹. The second key is a digit, - then a digit, t for ᵀ, u for ᵘ, s for ˢ, or b for ᵇ. Subscripts start with Alt-5. The second key is a digit, - then a digit, or x, j, e or r for the number suffixes ₓ, ⱼ, ₑ and ᵣ. A glyph with no entry in the Key column, such as +, is on an ordinary ASCII key. The arrow glyphs ←, ↓, ↑ and ↦ are on Alt-h, Alt-j, Alt-k and Alt-l. Alt-[ types nothing, because terminals send it as the start of a control sequence. Type ∆ with Alt-7, and ⍙ with Alt-Minus then 7.

In the REPL, type a backtick followed by one of the names in these tables, then press Tab to enter the glyph, as named entry describes. In Python, each function's name has _ in place of - and a trailing _ on Python keywords, as in index_of and and_. Each operator is a property of a function, under the operator's name, as in f.reduce.

Functions

GlyphKeyMonadDyadNote
+ plusconjugateaddCharacter offsets as BQN
- minusnegatesubtractCharacter difference as BQN
× timesAlt-msignmultiply
÷ obelusAlt-ureciprocaldivideExact rationals as J
⌊ downstileAlt-dfloorminimum⌊/⍬ is ∞
⌈ upstileAlt-sceilingmaximum⌈/⍬ is ¯∞
| stilemagnituderesidue
* starexponentialexponent
⊛ circle-starAlt-o 8natural-loglogarithm
○ circleAlt-ociscircularPi-times is π. Codes 0 to 8, inverted by k○⁻
π piAlt-ppi-timespi-ratio
√ radicalAlt-3sqrtrootAs BQN's √
! exclamationfactorialbinomial
⍭ stile-tildeAlt-Backslashprimeprime-modeLike J's p:, with different codes
⨸ circle-divideAlt-o ufactorsfactor-specAs J's q:
⌻ quad-jotAlt-q trootspolyvalAs J's p., but coefficients come from ⌻⁻
¿ inverted-questionAlt-/rolldealDyalog's ?
∨ veeAlt-9real-imagorMonad as J's +.
∧ wedgeAlt-0polarandMonad as J's *.
⊼ wedge-barAlt-Minus 0squarenandDyad as Dyalog's ⍲. Monad as J's *:
⊽ vee-barAlt-Minus 9doublenorDyad as Dyalog's ⍱. Monad as J's +:
~ tildenotwithoutMajor cells, as BQN
= equalsclassifyequalMonad as J
≠ not-equalsAlt-Shift-=unique-masknot-equal
< less-thansort-uplessMonad sorts major cells
≤ less-than-or-equalAlt-<decrementless-equalMonad as J's <:
> greater-thansort-downgreaterMonad sorts major cells
≥ greater-than-or-equalAlt->incrementgreater-equalMonad as J's >:
≡ equal-underbarAlt-=depthmatchUnsigned depth, as APL2/BQN
≢ equal-underbar-slashAlt-?tallynot-match
ρ rhoAlt-rshapereshapeRank-0 reshape encloses
, commaravelcatenate
⍪ comma-barAlt-Minus ,tablecatenate-first
⌽ circle-stileAlt-2reverserotate
⍉ circle-backslashAlt-o Backslashtransposereorder-axes
↑ up-arrowAlt-kfirsttakeMonad takes first major cell
↓ down-arrowAlt-jsplitdrop
↕ up-down-arrowAlt-KpairswindowsMonad is 2↕; dyad as BQN's ↕, plus movement/padding
⊂ left-shoeAlt-zenclosepartitioned-encloseEncloses atoms; partitions first axis
⊆ left-shoe-underbarAlt-Minus znestpartitionPartitions first axis
⊃ right-shoeAlt-xmixpickMonad as Dyalog ⎕ML≥2; pick cells or keys
⌷ squadAlt-q BackslashmaterialiseindexNegative indices; : keeps one axis, ∞ the rest; ¯∞ inserts one
ι iotaAlt-iindicesindex-ofAxis selectors; negative lengths count down
↦ right-arrow-from-barAlt-lrangetoCounts up or down from 1, ¯1 or X to Y; not Dyalog's branch
: colonunkeykeyedAxis keys
⍸ iota-underbarAlt-Minus iwhereinterval-indexDyad as BQN's ⍋
∊ epsilonAlt-eenlistmemberMajor cells, as BQN
∪ down-shoeAlt-vuniqueunionMajor cells, as BQN
∩ up-shoeAlt-cduplicatesintersectionMajor cells, as BQN
⍷ epsilon-underbarAlt-Minus egroupsfindMonad as Dyalog's {⊂⍵}⌸
⍋ delta-stileAlt-Backslash 7grade-upgrade-up-by
⍒ del-stileAlt-Backslash ggrade-downgrade-down-by
# hashrunsreplicateDyad as Dyalog's ⌿; monad run-length encodes, and #⁻ decodes
⊤ down-tackAlt-nbinary-encodeencodeDigits on last axis, as J
⊥ up-tackAlt-bbinary-decodedecodeDigits on last axis, as J
⌹ dominoAlt-q umatrix-inversematrix-divide
⊣ left-tackAlt-;same-leftleft
⊢ right-tackAlt-'sameright
⍎ hydrantAlt-o bexecuteexecute-inX has keys on its first axis, whereas Dyalog takes a namespace
⍕ thornAlt-o nformatformat-spec

Monadic operators

A monadic operator takes one operand, on its left, as in +/. The Monad and Dyad columns give the names of the derived function's monadic and dyadic forms. When both forms do the same thing, one name in the Monad column covers them. In the notes, f and g are functions, and a, n and r are arrays or numbers.

GlyphKeyMonadDyadNote
/ slashreducef/, along the last axis. A left argument is a seed, as BQN’s ´
⌿ slash-barAlt-Minus /reduce-firstf⌿, along the first axis. Seed as /
\\ backslashscanf\, along the last axis. A left argument is a seed. Accumulates LTR as BQN
⍀ backslash-barAlt-Minus Backslashscan-firstf⍀, along the first axis. Seed as \\. Accumulates LTR as BQN
¨ diaeresisAlt-1eachf¨
ᵇ superscript-bAlt-6 bbitwisefᵇ applies a Boolean function to integer bits
ᵘ superscript-uAlt-6 uunaryX fᵘ Y is f Y
⁻ superscript-minusAlt-_inversef⁻ undoes f. A superscript digit immediately after the minus instead makes a negative Rank
⍨ tilde-diaeresisAlt-1 Backtickselfcommutef⍨. a⍨ is a constant function
⊗ circle-timesAlt-o mouter-productg⊗, as BQN's ⌜
⌸ quad-equalAlt-q =keyf⌸
⇄ right-left-arrowsAlt-4optimizef⇄ searches for the point where f is least, or with "solve":$t, where its residuals are zero. A left argument holds options
∂ partialAlt-fderivativef∂ gives the Jacobian. The dyad differentiates α f ω with respect to ω

Dyadic operators

A dyadic operator takes an operand on each side, as in f⍤1. The columns are as for monadic operators.

GlyphKeyMonadDyadNote
↣ right-tail-arrowAlt-.beforef↣g. a↣f binds a left argument. As BQN's ⊸
↢ left-tail-arrowAlt-,afterf↢g. f↢a binds a right argument. As BQN's ⟜
⍤ jot-diaeresisAlt-1 trankf⍤r, f⍤g. Rank 0 preserves atom/scalar distinction
∘ jotAlt-tatopf∘g, as BQN's ∘
⍠ quad-colonAlt-q ;axisf⍠A, f⍠g apply f along named or numbered axes
⍥ circle-diaeresisAlt-1 ooverf⍥g
. dotdeterminantinner-productf.g. The monad is J's determinant form, u .v. Also array fields and indexing
⍣ star-diaeresisAlt-1 8powerf⍣n iterates or inverts, f⍣g computes counts once, f⍣∞ finds a fixed point; f⍣gˢ stops at g, f⍣[g] keeps every state until g. List counts give history, as J/BQN
⊘ circle-slashAlt-o /valencesf⊘g calls f with one argument and g with two, as BQN's ⊘
⍚ diamond-underbarAlt-Minus Backtickagendaselector⍚cases calls the function that the selector picks, as BQN's ◶, or one for each cell
@ atunderf@g, f@a, f@[p] apply f under a selection, positions, mask or transform. As BQN's ⌾, not Dyalog's @
⌺ quad-diamondAlt-q Backtickstencilf⌺a, f⌺g

Syntax and literals

GlyphKeyNameNote
← left-arrowAlt-hassignIncludes modified and selective assignment
(…) parenthesesGrouping. With ◇, a vector of rows: (4◇4 5) is [[4] [4 5]]
[…] bracketsVectors and arrays: [a b c], [a;b c], [1 2◇3 4]. One item makes a one-item vector: [x] is ,⊂x
{…} bracesDefined function or operator. ; separates its bodies
α alpha, ω omegaAlt-a, Alt-wleft-argument, right-argument
⍶ alpha-underbar, ⍹ omega-underbarAlt-Minus a, Alt-Minus wleft-operand, right-operand
∇ del, ⍢ del-diaeresisAlt-g, Alt-1 grecursion, operator-recursionA dfn's own function or operator
? questionpredicateInside dfns
:: error-guardError guard inside dfns
◇ diamondAlt-BacktickseparatorSeparates statements, rows inside brackets, and rows of a vector inside parentheses
⁝ tricolonAlt-:token-separatorSeparates tokens without ending the run or continuing a literal strand
⍝ lampAlt-o ccomment
⎕← quadAlt-qioExplicit output. Read alone, the next line of input
• bulletAlt-ysystemSystem function prefix
⍬ zildeAlt-Shift-0emptyEmpty numeric vector
'…' "…" quoteCharacter and string literals
¯ overbarAlt-MinusnegativeNegative literal sign
∞ infinityAlt-8Real infinity
$t $f $n constantsTrue, false and NaN
$e caught errorThe error that an error guard's handler caught
² ⁻ ᵀ ˢ superscriptAlt-6x² is x*2; on a function, f¹ is f⍤1, f⁰ ¹ is f⍤[0 1], and f⁻¹ is rank ¯1. Bare f⁻ is inverse; mᵀ is ⍉m; xˢ is a scalar holding x (subject or function)
₁ ₋₁ subscriptAlt-5Array positions: v₁ is 1⌷v, v₋₁ is the last major cell, m₁ ₂ is m.[1 2], and v₁←5 assigns to that cell. Function axes: +/₀ is +/⍠0, and +/₁ ₂ is +/⍠[1 2]

Numbers covers numeric notation, such as ₓ, r, j and e.

System names

System names start with •. System functions lists them.

Language-wide differences from Dyalog APL