lol-0.7.0.0: A library for lattice cryptography.

Copyright(c) Eric Crockett 2011-2017
Chris Peikert 2011-2017
LicenseGPL-3
Maintainerecrockett0@email.com
Stabilityexperimental
PortabilityPOSIX \( \def\Z{\mathbb{Z}} \)
Safe HaskellNone
LanguageHaskell2010

Crypto.Lol.Types.ZmStar

Description

A collection of helper functions for working with \(\Z_m^*\).

Synopsis

Documentation

order :: forall m. Reflects m Int => Int -> Int Source #

The multiplicative order of \(p\) (the argument) modulo \(m\). Requires \(\gcd(p,m)=1\).

partitionCosets :: forall m m'. m `Divides` m' => Int -> [[Int]] Source #

Given \(p\), returns a partition of the cosets of \(\Z_{m'}^* / <p>\) (specified by representatives), where the cosets in each component are in bijective correspondence with the cosets of \(\Z_m^* / <p>\) under the natural ((bmod m)) homomorphism.