In mathematics, the Wythoff array is an infinite matrix of integers derived from the Fibonacci sequence and named after Dutch mathematician Willem Abraham Wythoff. It was first defined by Morrison (1980) using Wythoff pairs, the coordinates of winning positions in Wythoff's game; it can also be defined using Fibonacci numbers and Zeckendorf's theorem, or directly from the golden ratio and the recurrence relation defining the Fibonacci numbers. Every positive integer occurs exactly once in the array, and every integer sequence defined by the Fibonacci recurrence can be derived by shifting a row of the array.
The Wythoff array has the values
Inspired by a similar array previously defined by Stolarsky (1977), Morrison (1980) defined the Wythoff array as follows. Let denote the golden ratio; then the
th winning position in Wythoff's game is given by the pair of positive integers
, where the numbers on the left and right sides of the pair define two complementary Beatty sequences that together include each positive integer exactly once. Morrison defines the first two numbers in row
of the array to be the Wythoff pair given by the equation
, and where the remaining numbers in each row are determined by the Fibonacci recurrence relation. That is, if
denotes the entry in row
and column
of the array, then
An array is a systematic arrangement of similar objects, usually in rows and columns.
Specifically, it may refer to:
A telescope array, also called astronomical interferometer, such as the:
In computer science, an array type is a data type that is meant to describe a collection of elements (values or variables), each selected by one or more indices (identifying keys) that can be computed at run time by the program. Such a collection is usually called an array variable, array value, or simply array. By analogy with the mathematical concepts of vector and matrix, array types with one and two indices are often called vector type and matrix type, respectively.
Language support for array types may include certain built-in array data types, some syntactic constructions (array type constructors) that the programmer may use to define such types and declare array variables, and special notation for indexing array elements. For example, in the Pascal programming language, the declaration type MyTable = array [1..4,1..2] of integer
, defines a new array data type called MyTable
. The declaration var A: MyTable
then defines a variable A
of that type, which is an aggregate of eight elements, each being an integer variable identified by two indices. In the Pascal program, those elements are denoted A[1,1]
, A[1,2]
, A[2,1]
,… A[4,2]
. Special array types are often defined by the language's standard libraries.
In computing, sequence containers refer to a group of container class templates in the standard library of the C++ programming language that implement storage of data elements. Being templates, they can be used to store arbitrary elements, such as integers or custom classes. One common property of all sequential containers is that the elements can be accessed sequentially. Like all other standard library components, they reside in namespace std.
The following containers are defined in the current revision of the C++ standard: array
, vector
, list
, forward_list
, deque
. Each of these containers implements different algorithms for data storage, which means that they have different speed guarantees for different operations:
array
implements a compile-time non-resizeable array. vector
implements an array with fast random access and an ability to automatically resize when appending elements. deque
implements a double-ended queue with comparatively fast random access. list
implements a doubly linked list.