Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Mathematics and Algorithms > Matrices and Linear Algebra > Constructing Matrices > Array >
Mathematica > Mathematics and Algorithms > Graphs & Networks > Graph Programming > Matrices and Linear Algebra > Constructing Matrices > Array >
Mathematica > Visualization and Graphics > Graphs & Networks > Graph Programming > Matrices and Linear Algebra > Constructing Matrices > Array >

Array

Array
generates a list of length n, with elements .
Array
generates an array of nested lists, with elements .
Array
generates a list using the index origins (default ).
Array
uses head h, rather than List, for each level of the array.
Generate a array:
Generate a array:
Use index origin instead of :
Start with indices and instead of :
In[1]:=
Click for copyable input
Out[1]=
In[2]:=
Click for copyable input
Out[2]=
 
Generate a array:
In[1]:=
Click for copyable input
Out[1]=
Generate a array:
In[2]:=
Click for copyable input
Out[2]=
 
Use index origin instead of :
In[1]:=
Click for copyable input
Out[1]=
Start with indices and instead of :
In[2]:=
Click for copyable input
Out[2]=
Use to pick up a sequence of indices:
Use Plus instead of List to combine elements:
matrix of 0s:
Totally antisymmetric tensor:
Lower-triangular matrix:
Matrix with generic symbolic entries:
Use it to see the effects of some linear algebra functions:
ConstantArray and Array are equivalent:
When c is a machine number, ConstantArray is much faster for large arrays:
Array can be generated using Table:
Set up the Table limit specifications:
Use Apply to splice them into a Table command:
The result is identical to the array generated using Array:
SparseArray gives a sparse representation of Array:
The results are Equal:
The objects are not identical, but the represented arrays are:
Array of powers:
Array of GCDs:
Array of arrays:
New in 1 | Last modified in 4
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF