Rank: Difference between revisions

Jump to navigation Jump to search
56 bytes added ,  08:00, 9 July 2020
Miraheze>Adám Brudzewsky
No edit summary
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
:''This page is about array rank, a number associated with every array. For numbers associated with a function specifying its argument rank, see [[function rank]]. For the operator that applies a function at a given rank, see [[Rank operator]].''
:''This page is about array rank, a number associated with every array. For numbers associated with a function specifying its argument rank, see [[function rank]]. For the operator that applies a function at a given rank, see [[Rank (operator)]].''


In the APL [[array model]], the '''rank''' of an array is the number of dimensions or [[Axis|axes]] in its structure, or the length of its [[shape]]. The traditional expression for the rank of an array <source lang=apl inline>A</source> is <source lang=apl inline>⍴⍴A</source>. Because this expression results in a one-element [[vector]] rather than a [[scalar]], it is idiomatic in languages with a [[Tally]] function to write <source lang=apl inline>≢⍴A</source> instead.
In the APL [[array model]], the '''rank''' of an array is the number of dimensions or [[Axis|axes]] in its structure, or the length of its [[shape]]. The traditional expression for the rank of an array <source lang=apl inline>A</source> is <source lang=apl inline>⍴⍴A</source>. Because this expression results in a one-element [[vector]] rather than a [[scalar]], it is idiomatic in languages with a [[Tally]] function to write <source lang=apl inline>≢⍴A</source> instead.
Line 18: Line 18:
== External Links ==
== External Links ==


[[wikipedia:Rank_(computer_programming)|Wikipedia]]
* [[wikipedia:Rank (computer programming)|Rank (computer programming)]]
{{APL features}}
{{APL features}}[[Category:Array characteristics]]

Navigation menu