pub trait Group: 'static + Copy + Clone + Send + Sync {
    type Scalar: FieldExt;

    fn group_zero() -> Self;
    fn group_add(&mut self, rhs: &Self);
    fn group_sub(&mut self, rhs: &Self);
    fn group_scale(&mut self, by: &Self::Scalar);
}
Expand description

This represents an element of a group with basic operations that can be performed. This allows an FFT implementation (for example) to operate generically over either a field or elliptic curve group.

Required Associated Types

The group is assumed to be of prime order $p$. Scalar is the associated scalar field of size $p$.

Required Methods

Returns the additive identity of the group.

Adds rhs to this group element.

Subtracts rhs from this group element.

Scales this group element by a scalar.

Implementors