Total array ordering: Difference between revisions

Jump to navigation Jump to search
160 bytes added ,  10:45, 11 September 2022
m
Text replacement - "</source>" to "</syntaxhighlight>"
(We don't know if this is the reason NARS2000 excludes them.)
m (Text replacement - "</source>" to "</syntaxhighlight>")
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
:'''''TAO''' links here. For the chat room, see The [[APL Orchard]].''
In APL, a '''total array ordering''', or '''TAO''', is an [[ordering]] on all arrays which is used primarily by [[Grade]] and [[Interval Index]], but optionally also by the [[comparison function]]s. Traditionally ordering is defined only for [[simple]] arrays of the same [[shape]] and [[type]], so ''TAO'' refers to the extension to [[Nested array|nested]] or [[box]]ed arrays of arbitrary [[rank]], shape, and type.
In APL, a '''total array ordering''', or '''TAO''', is an [[ordering]] on all arrays which is used primarily by [[Grade]] and [[Interval Index]], but optionally also by the [[comparison function]]s. Traditionally ordering is defined only for [[simple]] arrays of the same [[shape]] and [[type]], so ''TAO'' refers to the extension to [[Nested array|nested]] or [[box]]ed arrays of arbitrary [[rank]], shape, and type.


Line 7: Line 9:
Some dialects do not implement a true ''total'' order because they support arrays without defining an order for them.
Some dialects do not implement a true ''total'' order because they support arrays without defining an order for them.


Dyalog APL excludes [[simple scalar]]s other than nulls, [[number]]s or [[character]]s (namely [[namespace]]s, [[object]]s, and [[object representation]]s), because ordering those was considered "contentious but of little incremental benefit."<ref name=bfh>[[Adám Brudzewsky|Brudzewsky, A.]], [[Jay Foad|J. Foad]], and R. Hui. [https://www.jsoftware.com/papers/TAOaxioms.htm TAO Axioms]. 2018-02-02.</ref> [[Roger Hui]] has argued that these scalars are not truly arrays, and are not in the scope of a total array ordering. However, the [[dfns workspace]] includes an APL model which is truly total, though it differs from the native implementation in ordering characters before numbers instead of the opposite.<ref>[[Dfns workspace]]. [http://dfns.dyalog.com/n_le.htm <source lang=apl inline>le</source>] ― Total array ordering (TAO) comparison.</ref>
Dyalog APL excludes [[simple scalar]]s other than nulls, [[number]]s or [[character]]s (namely [[namespace]]s, [[object]]s, and [[object representation]]s), because ordering those was considered "contentious but of little incremental benefit."<ref name=bfh>[[Adám Brudzewsky|Brudzewsky, A.]], [[Jay Foad|J. Foad]], and R. Hui. [https://www.jsoftware.com/papers/TAOaxioms.htm TAO Axioms]. 2018-02-02.</ref> [[Roger Hui]] has argued that these scalars are not truly arrays, and are not in the scope of a total array ordering. However, the [[dfns workspace]] includes an APL model which is truly total, though it differs from the native implementation in ordering characters before numbers instead of the opposite.<ref>[[Dfns workspace]]. [http://dfns.dyalog.com/n_le.htm <syntaxhighlight lang=apl inline>le</syntaxhighlight>] ― Total array ordering (TAO) comparison.</ref>


NARS2000's  excludes [[complex number]]s (including quaternions and octonions) from the ordering. It should be noted that these numbers do not belong to any [[wikipedia:ordered field|ordered field]]: any ordering that remains the same after adding a constant could not be compatible with multiplication in the sense that the product of any two numbers greater than zero is greater than zero.<ref name=bfh/>
NARS2000's  excludes [[complex number]]s (including quaternions and octonions) from the ordering. It should be noted that these numbers do not belong to any [[wikipedia:ordered field|ordered field]]: any ordering that remains the same after adding a constant could not be compatible with multiplication in the sense that the product of any two numbers greater than zero is greater than zero.<ref name=bfh/>
Line 15: Line 17:
* [https://code.jsoftware.com/wiki/Vocabulary/slashco#Details J]
* [https://code.jsoftware.com/wiki/Vocabulary/slashco#Details J]
* [https://www.gnu.org/software/apl/apl.html#Section-3_002e4 GNU APL]
* [https://www.gnu.org/software/apl/apl.html#Section-3_002e4 GNU APL]
* [https://mlochbaum.github.io/BQN/doc/order.html#array-ordering BQN]


== References ==
== References ==

Navigation menu