group-theory-0.1.0.0: The theory of groups
Copyright(c) 2020 Emily Pillmore
LicenseBSD-style
MaintainerEmily Pillmore <emilypi@cohomolo.gy>, Reed Mullanix <reedmullanix@gmail.com>
Stabilitystable
Portabilitynon-portable
Safe HaskellSafe
LanguageHaskell2010

Data.Group.Cyclic

Description

This module contains definitions for CyclicGroup along with the relevant combinators.

Synopsis

Cyclic groups

class Group g => CyclicGroup g where Source #

A CyclicGroup is a Group that is generated by a single element. This element is called a generator of the group. There can be many generators for a group, e.g., any representative of an equivalence class of prime numbers of the integers modulo n, but to make things easy, we ask for only one generator.

Methods

generator :: g Source #

Instances

Instances details
CyclicGroup () Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: () Source #

CyclicGroup a => CyclicGroup (Identity a) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup a => CyclicGroup (Dual a) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: Dual a Source #

CyclicGroup a => CyclicGroup (Endo a) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: Endo a Source #

CyclicGroup (Sum Int) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Int8) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Int16) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Int32) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Int64) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Integer) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Rational) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Word) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Word8) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Word16) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Word32) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup (Sum Word64) Source # 
Instance details

Defined in Data.Group.Cyclic

CyclicGroup a => CyclicGroup (Down a) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: Down a Source #

(CyclicGroup a, CyclicGroup b) => CyclicGroup (a, b) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: (a, b) Source #

CyclicGroup a => CyclicGroup (Proxy a) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: Proxy a Source #

(CyclicGroup a, CyclicGroup b, CyclicGroup c) => CyclicGroup (a, b, c) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: (a, b, c) Source #

CyclicGroup a => CyclicGroup (Const a b) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: Const a b Source #

(CyclicGroup a, CyclicGroup b, CyclicGroup c, CyclicGroup d) => CyclicGroup (a, b, c, d) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: (a, b, c, d) Source #

(CyclicGroup a, CyclicGroup b, CyclicGroup c, CyclicGroup d, CyclicGroup e) => CyclicGroup (a, b, c, d, e) Source # 
Instance details

Defined in Data.Group.Cyclic

Methods

generator :: (a, b, c, d, e) Source #

Combinators

generate :: (Eq a, CyclicGroup a) => [a] Source #

Lazily generate all elements of a CyclicGroup from its generator.

Note: fuses.

classify :: (Eq a, CyclicGroup a) => (a -> Bool) -> [a] Source #

Classify elements of a CyclicGroup.

Apply a classifying function a -> Bool to the elements of a CyclicGroup as generated by its designated generator.

Examples:

>>> classify (< (3 :: Sum Word8))
[Sum {getSum = 1},Sum {getSum = 2}]