From 3f2943af2a60afca1235f6b41fde8ea8abf1ae72 Mon Sep 17 00:00:00 2001 From: Marshall Lochbaum Date: Sun, 28 Feb 2021 21:59:14 -0500 Subject: =?UTF-8?q?Split=20up=20cases=20of=20J=20/=20since=20=CB=9D=20only?= =?UTF-8?q?=20matches=20the=20monadic=20one?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- doc/fromJ.md | 15 +++++++++------ docs/doc/fromJ.html | 20 +++++++++++++++----- 2 files changed, 24 insertions(+), 11 deletions(-) diff --git a/doc/fromJ.md b/doc/fromJ.md index e549533a..99d75821 100644 --- a/doc/fromJ.md +++ b/doc/fromJ.md @@ -78,7 +78,7 @@ Most of BQN's combinators have J equivalents. The J equivalent `"_` for `˙` ass |:---:|:----:|:---:|:----:|:----:|:-----:|:---:|:----:|:----:| | J | `"_` | `~` | `@:` | `&:` | `&.:` | `:` | `@.` | `::` | -For other modifiers the correspondence is looser. Here `⌜` shows the dyadic case and `´` the monadic case only. +For other modifiers the correspondence is looser. Here `⌜` shows the dyadic case and `´` `˝` the monadic case only. | BQN | `¨` | `⌜` | `´` | `˝` | `` ` `` | `˘` | `⎉` | `⚇` | `⍟` | `⁼` | |:---:|:-----:|:------:|:------:|:---:|:-------:|:-----:|:---:|:----:|:----:|:------:| @@ -101,9 +101,9 @@ Some other primitives are essentially the same in J and BQN, but with different |:---:|:---:|:---:|:---:|:----:|:----:|:----:|:----:|:---:|:---:|:-----:|:-----:| | BQN | `×` | `÷` | `⋆` | `⋆⁼` | `√` | `⌊` | `⌈` | `⊣` | `⊢` | `⌽` | `⍉` | -| J | `~` | `@:` | `&:` | `&.:` | `:` | `/` | `"` | `L:` | `^:` | -|:---:|:---:|:----:|:----:|:-----:|:---:|:---:|:---:|:----:|:----:| -| BQN | `˜` | `∘` | `○` | `⌾` | `⊘` | `˝` | `⎉` | `⚇` | `⍟` | +| J | `~` | `@:` | `&:` | `&.:` | `:` | `"` | `L:` | `^:` | +|:---:|:---:|:----:|:----:|:-----:|:---:|:---:|:----:|:----:| +| BQN | `˜` | `∘` | `○` | `⌾` | `⊘` | `⎉` | `⚇` | `⍟` | The tables below give approximate implementations of J primitives. J has a whole lot of complicated primitives that no one uses (some of which are officially deprecated), so not everything is translated here. Operations that only apply to complex numbers are omitted because no BQN implementation currently supports them. @@ -150,10 +150,13 @@ Some J modifier expressions are translated below. BQN doesn't keep track of the | J | BQN |----------------|----- | `&.>` | `¨` +| `F/ y` | `F˝ y` +| `x F&.>/ y` | `x F⌜ y` +| `x F/ y` | `x F⎉r‿∞ y` where `r` is `F`'s left rank | ``F`G`H@.C`` | `C◶⟨F,G,H⟩` | `x y} z` | `x⌾(y⊸⊏) z` -| `x F/ .G y` | `x F˝∘G⎉1‿∞ y` -| `F:.G` | `{𝕊: 𝕨F𝕩; 𝕊⁼: 𝕨G𝕩}` +| `x F/ . G y` | `x F˝∘G⎉1‿∞ y` +| `F :. G` | `{𝕊: 𝕨F𝕩; 𝕊⁼: 𝕨G𝕩}` | `<;._1` | ``((1-˜¬×+`)=⟜⊏⊘⊣)⊔⊢`` | `x {.!.f y` | `y » x⥊f` | `x \|.!.f y` | `x ⥊⟜f⊸« y`, or `(-x) ⥊⟜f⊸» y` if `𝕩<0` diff --git a/docs/doc/fromJ.html b/docs/doc/fromJ.html index a74ef8bf..02fc397c 100644 --- a/docs/doc/fromJ.html +++ b/docs/doc/fromJ.html @@ -296,7 +296,7 @@ -

For other modifiers the correspondence is looser. Here shows the dyadic case and ´ the monadic case only.

+

For other modifiers the correspondence is looser. Here shows the dyadic case and ´ ˝ the monadic case only.

@@ -394,7 +394,6 @@ - @@ -408,7 +407,6 @@ - @@ -616,6 +614,18 @@ + + + + + + + + + + + + @@ -624,11 +634,11 @@ - + - + -- cgit v1.2.3
&: &.: :/ " L: ^: ˝ ¨
F/ yF˝ y
x F&.>/ yx F y
x F/ yx Fr y where r is F's left rank
F`G`H@.C CF,G,H
x(y) z
x F/ .G yx F/ . G y x F˝G1 y
F:.GF :. G {𝕊: 𝕨F𝕩; 𝕊: 𝕨G𝕩}