Skip to content

Reverse ​

The word read backwards.

Reverse(Permutation)The word read backwards.
Typed signatures
TypePackageApplies
((T) -> T where T: string) & ((T) -> T where T: list) & ((indexed_collection<T>) -> list<T> where T: any)compute-enginealways
((binary_word) -> binary_word) & ((composition) -> composition) & ((parking_function) -> parking_function) & ((permutation) -> permutation) & ((set_composition) -> set_composition) & ((signed_permutation) -> signed_permutation)combinatoricsreplaces compute-enginealways

Domain: Combinatorial maps

Details
  • Takes a Permutation and returns a Permutation — a typed map, so a wrong carrier is a type error rather than a wrong answer.
  • Also takes a SignedPermutation, returning a SignedPermutation: The word read backwards, signs kept.
  • FindStat's Mp00161.
  • Also takes a SetComposition, returning a SetComposition: The blocks in the opposite order.
  • FindStat's Mp00288.
  • Also takes a IntegerComposition, returning a IntegerComposition: The parts read backwards.
  • Also takes a BinaryWord, returning a BinaryWord: The word read backwards.
  • Also takes a ParkingFunction, returning a ParkingFunction: The word read backwards.

Examples

Basic #

the one-line word 231231

live ↗
InReverse(Permutation⁡([2,3,1]))\mathrm{Reverse}({\operatorname{Permutation}}([2, 3, 1]))OutPermutation⁡([1,3,2]){\operatorname{Permutation}}([1, 3, 2])

the signed permutation 2 3ˉ 12\,\bar 3\,1

live ↗
InReverse(SignedPermutation⁡([2,−3,1]))\mathrm{Reverse}({\operatorname{SignedPermutation}}([2, -3, 1]))OutSignedPermutation⁡([1,−3,2]){\operatorname{SignedPermutation}}([1, -3, 2])

the set composition {2,4}∣{1}∣{3}\{2,4\} \mid \{1\} \mid \{3\}

live ↗
InReverse(SetComposition⁡([[2,4],[1],[3]]))\mathrm{Reverse}({\operatorname{SetComposition}}([[2, 4], [1], [3]]))OutSetComposition⁡([[3],[1],[2,4]]){\operatorname{SetComposition}}([[3], [1], [2, 4]])

the composition 2+1+32 + 1 + 3

live ↗
InReverse(IntegerComposition⁡([2,1,3]))\mathrm{Reverse}({\operatorname{IntegerComposition}}([2, 1, 3]))OutIntegerComposition⁡([3,1,2]){\operatorname{IntegerComposition}}([3, 1, 2])

the binary word 0110001100

live ↗
InReverse(BinaryWord⁡([0,1,1,0,0]))\mathrm{Reverse}({\operatorname{BinaryWord}}([0, 1, 1, 0, 0]))OutBinaryWord⁡([0,0,1,1,0]){\operatorname{BinaryWord}}([0, 0, 1, 1, 0])

the parking function 21132113

live ↗
InReverse(ParkingFunction⁡([2,1,1,3]))\mathrm{Reverse}({\operatorname{ParkingFunction}}([2, 1, 1, 3]))OutParkingFunction⁡([3,1,1,2]){\operatorname{ParkingFunction}}([3, 1, 1, 2])
About
Examples6
CrosswalkFindStat ×6Wolfram Language