I remember the “curly less than” (or equal) as a notation for partial ordering, 
like that of the complex numbers or vectors.
But such an ordering cannot be used for grading, as grading needs a complete 
ordering.
And since grading uses the lexicographical and type ordering (as you showed in 
your last example), we could easily define comparison on characters and boxes by

< ←→ ≼          for characters
< ←→ ≼&>                for boxes

It wouldn’t even hurt existing programs.


R.E. Boss

p.s. I would have preferred all primitives to have infinity rank anyhow, but 
that is another discussion


> -----Oorspronkelijk bericht-----
> Van: Programming <programming-boun...@forums.jsoftware.com>
> Namens Roger Hui
> Verzonden: zaterdag 2 maart 2019 04:47
> Aan: programm...@jsoftware.com
> Onderwerp: Re: [Jprogramming] Comparing comparisons
>
> For the ordering used in sorting, what you want is the symbol denoted by ≺
> "curly less than" U+227A or ≼ "curly less than equal" U+227C in conventional
> mathematical notation, with infinite dyadic ranks.  It's not enough to make <
> or <: work on characters because those functions have 0 dyadic rank.
>
> ≼ ←→  0 1 -: /:@,
>
>    f=: 0 1 -: /:@,&<
>    'foo' f 'upon'
> 1
>    'syzygy' f 'chthonic'
> 0
>    'pi' f 3.14159
> 0
>
>
>
> On Fri, Mar 1, 2019 at 5:10 PM Jimmy Gauvin 
> <jimmy.gau...@gmail.com<mailto:jimmy.gau...@gmail.com>>
> wrote:
>
> > Hi,
> >
> > 'c' < 'b' doesn't work in APL either but 'c'='d' works in J and in APL.
> >
> >
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to