Wolfram ResearchProductsPurchasingServices & ResourcesAbout UsOur Sites
Mathematica Technical FAQs Services & Resources / Mathematica / Kernels & Programming
-----
 /
Symbols
*Mathematica
*Network Mathematica
*webMathematica
*gridMathematica
*Personal Grid Edition
*Wolfram Workbench
*Wolfram Education Group
*Application Packages
*Mathematica for Students
*Mathematica CalcCenter
*Publicon
*A New Kind of Science Explorer
*Mathematical Explorer
*Mathematica Teacher's Edition
*Calculus WIZ
*Mathematica Player
*Ask about this page
*Print this page
*Email this page
*Give us feedback
*
Sign up for our newsletter:

Partition


Usage Message:

Mathematica 4.0
Partition[list, n] partitions list into non-overlapping sublists of length n. Partition[list, n, d] generates sublists with offset d. Partition[list, {n1, n2, ... }] partitions a nested list into blocks of size n1 x n2 x ... . Partition[list, {n1, n2, ... }, {d1, d2, ... }] uses offset di at level i in list. Partition[list, n, d, {kL, kR}] specifies that the first element of list should appear at position kL in the first sublist, and the last element of list should appear at or after position kR in the last sublist. If additional elements are needed, Partition fills them in by treating list as cyclic. Partition[list, n, d, {kL, kR}, x] pads if necessary by repeating the element x. Partition[list, n, d, {kL, kR}, {x1, x2, ... }] pads if necessary by cyclically repeating the elements xi. Partition[list, n, d, {kL, kR}, {}] uses no padding, and so can yield sublists of different lengths. Partition[list, nlist, dlist, {klistL, klistR}, padlist] specifies alignments and padding in a nested list.

Mathematica 3.0
Partition[list, n] partitions list into non-overlapping sublists of length n. Partition[list, n, d] generates sublists with offset d. Partition[list, {n1, n2, ... }, {d1, d2, ... }] partitions successive levels in list into length ni sublists with offsets di.

Attributes[Partition] = {Protected}


Notes:


Additional Online Documentation:

Mathematica 3.0
http://documents.wolfram.com/v3/RefGuide/Partition.html

Mathematica 4.0
http://documents.wolfram.com/v4/RefGuide/Partition.html




 © 2008 Wolfram Research, Inc.  Terms of Use  Privacy Policy