Simple scalar: Difference between revisions

From APL Wiki
Jump to navigation Jump to search
Miraheze>Marshall
mNo edit summary
(Link to Enclose)
 
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
In [[nested array theory]], a '''simple scalar''' is an array encoding data from one of the language's fundamental data types such as a [[number]] or [[character]]. A simple scalar is defined to be a [[scalar]] whose only [[element]] is itself. All nested APLs specify that simple scalars [[float]], that is, a scalar array containing only a simple scalar is identical to that simple scalar. Because of this property, all arrays which are both [[simple]] and [[scalar]] are simple scalars.
In [[nested array theory]], a '''simple scalar''' is an array encoding data from one of the language's fundamental data types such as a [[number]] or [[character]]. A simple scalar is defined to be a [[scalar]] whose only [[element]] is itself. All nested APLs specify that simple scalars [[float]], that is, a scalar array containing only a simple scalar (the [[Enclose]] of that scalar) is identical to that simple scalar. Because of this property, all arrays which are both [[simple]] and [[scalar]] are simple scalars.


Simple scalars are the only arrays with [[depth]] 0. An array consisting only of simple scalars therefore has depth 1; such arrays are called [[simple]].
Simple scalars are the only arrays with [[depth]] 0. An array consisting only of simple scalars therefore has depth 1; such arrays are called [[simple]].


{{APL programming language}}
{{APL features}}[[Category:Kinds of array]][[Category:Nested array model]]

Latest revision as of 21:29, 14 July 2020

In nested array theory, a simple scalar is an array encoding data from one of the language's fundamental data types such as a number or character. A simple scalar is defined to be a scalar whose only element is itself. All nested APLs specify that simple scalars float, that is, a scalar array containing only a simple scalar (the Enclose of that scalar) is identical to that simple scalar. Because of this property, all arrays which are both simple and scalar are simple scalars.

Simple scalars are the only arrays with depth 0. An array consisting only of simple scalars therefore has depth 1; such arrays are called simple.


APL features [edit]
Built-ins Primitives (functions, operators) ∙ Quad name
Array model ShapeRankDepthBoundIndex (Indexing) ∙ AxisRavelRavel orderElementScalarVectorMatrixSimple scalarSimple arrayNested arrayCellMajor cellSubarrayEmpty arrayPrototype
Data types Number (Boolean, Complex number) ∙ Character (String) ∙ BoxNamespaceFunction array
Concepts and paradigms Conformability (Scalar extension, Leading axis agreement) ∙ Scalar function (Pervasion) ∙ Identity elementComplex floorArray ordering (Total) ∙ Tacit programming (Function composition, Close composition) ∙ GlyphLeading axis theoryMajor cell searchFirst-class function
Errors LIMIT ERRORRANK ERRORSYNTAX ERRORDOMAIN ERRORLENGTH ERRORINDEX ERRORVALUE ERROREVOLUTION ERROR