Dyalog APL Vision
Jump to navigation
Jump to search
Dyalog APL Vision continues the role of Extended Dyalog APL, but tries to provide realistic extensions of Dyalog APL rather than simply extending the language as much as possible. It extends the domains of existing primitives and quad names and adds a few new ones.
Features
All scalar functions support leading axis agreement.
 All set functions support arguments of any rank.
⎕C
and monadic⎕UCS
are scalar functions. In addition, the following is included:
Name  Symbol  Type*  Extension  Examples 

CircleDiaeresis  ⍥

🔵  ✅ Depth when right operand is array. This is similar to Rank (⍤ ) but applies at nesting level.

f⍥0 applies f like a scalar function and f⍥1 applies to flat subarrays. f⍤1⍥1 applies to flat vectors.

DelDiaeresis  ⍢

🔺  Under (a.k.a. Dual). Like f⍥g but conceptually inverts the right operand when done. If g is a selection function, it puts the data back where it came from

⍢(2 3∘⊃) negates the 2nd element's 3rd element.

DelTilde  ⍫

🔺  Obverse; ⍺⍺ but with inverse ⍵⍵

×⍢(FFT⍫iFFT)

DollarSign  $

🔺  string enhancement ${1} :1⊃⍺ , ${expr} :⍎expr , \n :JSON

'Dyer' 'Bob'$'Hi, ${2} ${1}! $'Hi, ${first} ${last}! $'2×3=${2×3}'

DownArrow  ↓

🔵  dyad allows long ⍺

0 1↓'abc' gives 1 2⍴'bc'

DownTack  ⊤

⚠  ⊥⍣¯1 when left argument is scalar

2⊤123 gives 1 1 1 1 0 1 1

EpsilonUnderbar  ⍷

🔶  monad: Type (like ∊ with ⎕ML←0 )

⍷1'a'# gives 0' '# '

Equal  =

🔶  monad: Rank (≢⍴ )

=10 20 30 gives 1 '

GreaterOrEqual  ≥

🔵  monad: sort descending  ≥3 1 4 1 5 gives 5 4 3 1 1

GreaterThan  >

🔵  monad: Join  >2 2⍴⍪¨1 2 3 4 gives 2 2⍴1 2 3 4

JotUnderbar  ⍛

🔺  ✅ reverse composition X f⍛g Y is (f X) g Y and default argument

⌽⍛≡ checks for palindromes.a⍛↑b takes the last a from b .

LeftShoe  ⊂

🔵  dyad allows partitioning along multiple leading axes  (⊂1 1)⊂matrix separates out the first row and column.

LeftShoeUnderbar  ⊆

🔵  dyad allows partitioning along multiple leading axes  (⊂1 0 1 1)⊆4 4⍴⎕A splits off the first row and column, and removes the second.

LessOrEqual  ≤

🔵  monad: sort ascending  ≤3 1 4 1 5 gives 1 1 3 4 5

LessThan  <

🔵  monad: Major Cells  <2 2 2⍴⎕A gives (2 2⍴'ABCD')(2 2⍴'EFGH')

QuadEqual  ⌸

🔵  allow array operand to be vocabulary (then uses {⊂⍵} as internal operand)

≢¨'ACGT'⌸'ATTACA' gives 3 1 0 2

QuadDiamond  ⌺

🔶  autoextended ⍵⍵ , allows small ⍵ , optional edge spec(s) (0:Zero; 1:Repl; 2:Rev; 3:Mirror; 4:Wrap; :Twist) with masks as operand's ⍺

Life on a cylinder: 0 4 Life⌺3 3

QuestionMark  ?

🔵  dyadic allows ⍺ to be any shape (not just vector shape) and ⍵ is shape of array to select indices from

3 5?4 13 deals 3 hands of 5 cards from deck of 4 suits from A to K

Rho  ⍴

🔵  dyad: negatives reverse axis, 0.5 autosize rounding down, 1.5 autosize rounding up, 2.5 autosize with padding

Reshape into two columns: 0.5 2⍴data

RightShoeUnderbar  ⊇

🔺  monad: last (⊃⌽,⍵ )✅ dyad: select ( ⌷⍨∘⊃⍨⍤0 99 )

3 1 2⊇'abc' gives 'cab'

Root  √

🔺  (Square) Root  √25 gives 5 3√27 gives 3

UpArrow  ↑

🔵  allows long ⍺

2 3↑4 5 gives 2 3⍴4 5 0 0 0 0

Vel  ∨

🔶  monad: demote (,[⍳2] )

∨2 3 4⍴⎕A gives 6 4⍴⎕A

Wedge  ∧

🔶  monad: promote (⍵⍴⍨1,⍴⍵ )

'ABC'⍪⍥∧'DEF' gives 2 3⍴⎕A

Event Message  ⎕EM

🔵  Selfinverse ⎕EM

⎕EM'RANK ERROR' 'WS FULL' gives 4 1

Name Get  ⎕NG

🔺  Name Get  ref⎕NG'Bea' 'Abe'

Name Set  ⎕NS

🔵  Accepts ref left arg. Name Set: The list of values to copy into the new/target namespace can have 2element namevalue vectors, setting the name to the given value  ref←⎕NS('Abe' 10)('Bea' 12) ref⎕NS⊂'Carl' 8

Name Value  ⎕NV

🔺  Names and Values  `ref⎕NV 2 9 
Signal Event  ⎕SIGNAL

🔵  Allows ⎕DMX style ref argument

⎕SIGNAL ⎕DMX

* 🔺 new feature 🔶 added valence 🔵 expanded domain ⚠ breaking change ✅ scheduled for 20.0
APL dialects [edit]  

Maintained  APL+Win ∙ APL2 ∙ APL64 ∙ APL\iv ∙ Aplette ∙ April ∙ Codfns ∙ Dyalog APL ∙ Dyalog APL Vision ∙ dzaima/APL ∙ GNU APL ∙ Kap ∙ NARS2000 ∙ Pometo 
Historical  A Programming Language ∙ A+ (A) ∙ APL# ∙ APL\360 ∙ APL/700 ∙ APL\1130 ∙ APL\3000 ∙ APL.68000 ∙ APL*PLUS ∙ APL.jl ∙ APL.SV ∙ APLX ∙ Extended Dyalog APL ∙ Iverson notation ∙ IVSYS/7090 ∙ NARS ∙ ngn/apl ∙ openAPL ∙ Operators and Functions ∙ PAT ∙ Rowan ∙ SAX ∙ SHARP APL ∙ Rationalized APL ∙ VisualAPL (APLNext) ∙ VS APL ∙ York APL 
Derivatives  AHPL ∙ BQN ∙ CoSy ∙ ELI ∙ Glee ∙ I ∙ Ivy ∙ J ∙ Jelly ∙ Jellyfish ∙ K (Goal, Klong, Q) ∙ KamilaLisp ∙ Lang5 ∙ Lil ∙ Nial ∙ RAD ∙ Uiua 
Overviews  Comparison of APL dialects ∙ Timeline of array languages ∙ Timeline of influential array languages ∙ Family tree of array languages 