I think I have three relevant (or close-to-relevant) thoughts here.
(1) It would be Really Nice if examples were included with these
suggestions. Specifically: useful code in some domain, with
accompanying plausible tacit code. This sort of thing helps keep
coding sane... (Specifically, it helps us avoid turing tarpits and
their associated open ended costs.)
(2) I do not understand what your [.. and ].. would produce,
individually. How would you model them?
(3) Inspecting your P.P.S. proposal, I think when you say "constant
conjunction" you mean "an adverb which produces a conjunction which
replaces one of its arguments with the adverb's argument". In other
words, which might be modelled explicitly like this:
LCONS=: {{)a
0!:0'u=. {{)c',LF,'( ',(5!:6<'u'),')v}}'
u
}}
RCONS=: {{)a
0!:0'u=. {{)c',LF,'u( ',(5!:6<'u'),')}}'
u
}}
Does this match your thinking?
Thanks,
--
Raul
On Tue, Sep 28, 2021 at 11:51 PM Elijah Stone <[email protected]> wrote:
>
> A tacit modifier cannot currently produce a fork as an arbitrary function
> of its operands. (This is not the same thing as _implementing_ fork
> tacitly. The modifier is still only a verb-producing adverb or
> conjunction, but the resulting verb is a fork.)
>
> AAV is closest thing currently, but its right tine is fixed, and the left
> two cannot combine their operands with each other; so it must be nested
> and combined with other trains; an exercise in verbosity and obfuscation.
>
> Let me be more concrete. Given C0 C1 C2, I would like to be able to write
> tacitly {{ (u C0 v) (u C1 v) (u C2 v) }}. (And the analogous adverbial
> form, though that is obviously less important.)
>
> In a 20-year-old thread referenced by Henry, Roger Hui says that forks and
> atops are fundamental. But this is not quite right. f g h can be reduced
> to [ (f g ]) h. Fork augments its root's left and right arguments
> _separately_, which suggests a way out: fork is actually a combination of
> two conjunctions (call them left fork and right fork). If they are
> written [.. and ].., then f g h is simply shorthand for f ].. g [.. h.
> Then my above conjunction becomes simple, pretty, and obvious:
>
> C0 ].. C1 [.. C2
>
> I think it generalises well. Hook is simply [. [.. (@]).
> Compose is ]. ].. [. [.. ].--a bit noisy, but clear enough.
>
> (Of course, it's not all sunshine and roses. For consistency with the
> mistakes of @, &, and &., ].. and [.. should take on the relevant parts
> of the augmenting verb's rank, with ]..: and [..: as infinitely-ranked
> counterparts. But perhaps we can skip that this time? :)
>
> -E
>
> P.S. I will also note an incidental argument in favour of conjunctive
> hooks. If h is the 'hook' conjunction then, as V0 V1 is shorthand
> for V0 h V1, so is C0 C1 shorthand for C0 h C1. This remains
> relevant even if h is redefined to be saner.
>
> P.P.S. Also nice would be a higher-order constant function. A constant
> verb can be written as m"_; and a constant adverb as (a[.) or
> (].a). A constant conjunction must be a[.junk or junk].a, where
> junk is a useless conjunction or adverb.
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm