Is there a common symbol for concatenating two (finite) sequences?

$\begingroup$

Say we have two finite sequences $X = (x_0,...,x_n)$ and $Y = (y_0,...,y_n)$. Is there a more or less common notation for the concatenation of these sequences, like $\sum (X,Y) = (x_0,...,x_n,y_0,...,y_n)$?

$\endgroup$ 8

8 Answers

$\begingroup$

The comments suggest the following notations for the concatenation of $X$ and $Y$:

  • $X^\frown Y$ (given by X^\frown Y);
  • $XY$ (given by XY);
  • $X \cdot Y$ (given by X \cdot Y);
  • $X \mathbin\Vert Y$ (given by X \mathbin\Vert Y);

of which the first seems not to be in use for other concepts, making it especially suitable.

$\endgroup$ 5 $\begingroup$

The same question on Tex SE.

From there, and more:

  • $X \oplus Y$ (given by X \oplus Y);
  • $(X,Y)$ (given by (X,Y));

I would avoid $X \times Y$, $XY$ or $X \cdot Y$ to not confuse it with any sort of multiplication / product.

And I would also not use $X \otimes Y$ because it is usually the tensor product. (See also here.)

Some relevant Wikipedia pages with common notations:

$\endgroup$ 3 $\begingroup$

$\newcommand\mdoubleplus{\mathbin{+\mkern-10mu+}}$ In haskell the $ \mdoubleplus $ operator is used for concatenating lists.

You can define it in latex using the command

\newcommand\mdoubleplus{\mathbin{+\mkern-10mu+}}
$\endgroup$ 5 $\begingroup$

Computer science often uses the ⧺ (U+29FA) symbol for concatenation.

This is \doubleplus in the LaTeX package unicode-math (which requires a modern engine that supports Unicode), as well as the legacy packages stix and stix2. Or, in the modern toolchain, you can use the Unicode symbol in your source.

$\endgroup$ $\begingroup$

If $x$ and $y$ are finite sequences, you could denote their concatenation by $xy$. Let me explain. There's at least two ways of formalizing the statement "$x$ and $y$ are finite sequences in $X$"

  • $x$ and $y$ are functions of type $[\:\!n) \rightarrow X$, where $[\:\!n)$ is a shorthand for the set $\{0,\ldots,n-1\}$.

  • $x$ and $y$ are elements of $X^*$, where $X^*$ is the monoid freely generated by $X$.

If you're interested in concatenating these things, then you should probably take the second perspective, in which case the concatenation of $x$ and $y$ is simply their product in the monoid $X^*$, which is denoted $xy$.

$\endgroup$ $\begingroup$

In formal specifications, one way to concatenate two sequences is using the Haskell concatenation symbol as indicated in one of the comments above. In a $\mathrm\TeX$ editor one can type the following: X +\!\!\!+ Y. The result appears like this, $X+\!\!\!+Y$.

$\endgroup$ 1 $\begingroup$

Starting with your defined sequences $X = (x_0, \ldots, x_n)$ and $Y=(y_0,\ldots,y_n)$, you can use the commonly accepted tuple/ordered pair notation:\begin{align} (X,Y) &= \left( \left(x_0,\ldots,x_n\right), \left(y_0,\ldots,y_n\right) \right) \\ &= \left(x_0,\ldots,x_n,y_0,\ldots,y_n\right) \end{align}

$\endgroup$ 3 $\begingroup$

First of all, the $\frown$ (like the $\smile$) are used in algebraic topology for the cap (cup) product, so there is another use for this symbol. I haven't seen $\uplus$ suggested and I have searched extensively to find an existing use without success. It seems especially suited because sequences are in fact index-ordered sets which can contain duplicate elements. Concatenation is the union of such sets which preserves the order of concatenation and allows duplicates.

$\endgroup$

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like