Collection - (Tuple|Vector|Row)

1 - About

A tuple is:

  • a finite list of elements (fields) - It can only contain a specific number of elements.
  • ordered by position
  • that may have different types.
  • and still be completely typesafe.

You can see tuple:

Example with a tuple assignement.

(x,y,z) = (2,4,'Nico')

would result in the following tuple:

<math> \begin{array}{rrr} 0 & \mapsto & x & \mapsto & 2\\ 1 & \mapsto & y & \mapsto & 4\\ 2 & \mapsto & z & \mapsto & Nico\\ \end{array} </math>

A Tuple has a schema defining each field

The term tuple comes from the set theory.

In set theory, an (ordered) n-tuple is a sequence (or ordered list) of n elements, where n is a non-negative integer.

Tuples are often used to describe other mathematical objects, such as vector

In a relational database, a tuple is called a row.

3 - Size

Size Name Signature
1 Unit A
2 Pair A, B
3 Triplet A, B, C
4 Quartet A, B, C, D
5 Quintet A, B, C, D, E
6 Sextet A, B, C, D, E, F
7 Septet A, B, C, D, E, F, G
8 Octet A, B, C, D, E, F, G, H
9 Ennead A, B, C, D, E, F, G, H, I
10 Decade A, B, C, D, E, F, G, H, I, J

See also Function - Arity

4 - Implementation

5 - Documentation / Reference

Data Science
Data Analysis
Data Science
Linear Algebra Mathematics

Powered by ComboStrap