# acts: Semigroup actions and torsors.

[ algebra, bsd3, library, math ] [ Propose Tags ]

Acts and torsors model types which can be transformed under the action of another type.

A prototypical example is affine space, which has an action by translation: given any two points in affine space, there is a unique translation that brings one to the other.

This can be useful in a library keeping track of time: on top of needing to keep track of units, one also needs to distinguish between absolute time (time stamps) and relative time (time differences). The operations one expects in this situation are:

• Addition and subtraction of time differences: time differences form a (commutative) group.

• Translation of an absolute time by a time difference: there is an action of relative time on absolute time.

• Given two absolute times, one can obtain the time difference between them: absolute time is a torsor under relative time.

This library provides a convenient framework which helps to avoid mixing up these two different notions.

A fleshed out example is available at Acts.Examples.MusicalIntervals, which showcases the use of actions and torsors in the context of musical intervals and harmony. It also demonstrates common usage patterns of this library, such as how to automatically derive instances.

Versions [RSS] [faq] 0.1.0.0, 0.2.0.0, 0.3.0.0, 0.3.1.0 changelog.md acts, base (>=4.12 && <4.17), deepseq (>=1.4.4.0 && <1.5), finitary (>=1.2.0.0 && <2.2), finite-typelits (>=0.1.4.2 && <0.2), groups (>=0.4.0.0 && <0.5) [details] BSD-3-Clause Sam Derbyshire Sam Derbyshire Revision 3 made by sheaf at 2021-02-23T00:48:29Z Algebra, Math https://github.com/sheaf/acts https://github.com/sheaf/acts/issues head: git clone git://github.com/sheaf/acts.git by sheaf at 2020-02-23T01:34:27Z NixOS:0.3.1.0 990 total (2 in the last 30 days) (no votes yet) [estimated by Bayesian average] λ λ λ Docs uploaded by userBuild status unknown

## Modules

[Index] [Quick Jump]

## Manual Flags

NameDescriptionDefault
finitary

Use the finitary library to define actions on finite enumerations.

Disable to remove dependencies on finite-typelits and finitary.

Enabled
Automatic Flags
NameDescriptionDefault

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info