pub struct FreeAlgebraImplBase<R, V, A = Global, C = KaratsubaAlgorithm>{ /* private fields */ }
Expand description
Implementation for rings that are generated by a single algebraic element over a base ring,
equivalently a quotient of a univariate polynomial ring R[X]/(f(X))
.
§Example
let base_ring = StaticRing::<i64>::RING;
// ring of integers in the 6th cyclotomic number field
let ring = FreeAlgebraImpl::new(base_ring, 2, [-1, 1]);
let root_of_unity = ring.canonical_gen();
assert_el_eq!(ring, ring.one(), ring.pow(root_of_unity, 6));
Implementations§
Source§impl<R, V, A, C> FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> FreeAlgebraImplBase<R, V, A, C>
Sourcepub fn set_convolution<C_new: ConvolutionAlgorithm<R::Type>>(
self,
new_convolution: C_new,
) -> FreeAlgebraImpl<R, V, A, C_new>
Available on crate feature unstable-enable
only.
pub fn set_convolution<C_new: ConvolutionAlgorithm<R::Type>>( self, new_convolution: C_new, ) -> FreeAlgebraImpl<R, V, A, C_new>
unstable-enable
only.§Availability
This API is marked as unstable and is only available when the unstable-enable
crate feature is enabled. This comes with no stability guarantees, and could be changed or removed at any time.
Sourcepub fn allocator(&self) -> &A
Available on crate feature unstable-enable
only.
pub fn allocator(&self) -> &A
unstable-enable
only.§Availability
This API is marked as unstable and is only available when the unstable-enable
crate feature is enabled. This comes with no stability guarantees, and could be changed or removed at any time.
Sourcepub fn gen_name(&self) -> &'static str
Available on crate feature unstable-enable
only.
pub fn gen_name(&self) -> &'static str
unstable-enable
only.§Availability
This API is marked as unstable and is only available when the unstable-enable
crate feature is enabled. This comes with no stability guarantees, and could be changed or removed at any time.
Sourcepub fn x_pow_rank(&self) -> &V
Available on crate feature unstable-enable
only.
pub fn x_pow_rank(&self) -> &V
unstable-enable
only.§Availability
This API is marked as unstable and is only available when the unstable-enable
crate feature is enabled. This comes with no stability guarantees, and could be changed or removed at any time.
Sourcepub fn convolution(&self) -> &C
Available on crate feature unstable-enable
only.
pub fn convolution(&self) -> &C
unstable-enable
only.§Availability
This API is marked as unstable and is only available when the unstable-enable
crate feature is enabled. This comes with no stability guarantees, and could be changed or removed at any time.
Trait Implementations§
Source§impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<AsFieldBase<AsFieldRingStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<AsFieldBase<AsFieldRingStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
Source§fn has_canonical_hom(
&self,
from: &AsFieldBase<AsFieldRingStore>,
) -> Option<Self::Homomorphism>
fn has_canonical_hom( &self, from: &AsFieldBase<AsFieldRingStore>, ) -> Option<Self::Homomorphism>
from -> self
, returns Some(data)
, where
data
is additional data that can be used to compute the action of the homomorphism
on ring elements. Otherwise, None
is returned.Source§fn map_in(
&self,
from: &AsFieldBase<AsFieldRingStore>,
el: FieldEl<AsFieldRingStore>,
hom: &Self::Homomorphism,
) -> <Self as RingBase>::Element
fn map_in( &self, from: &AsFieldBase<AsFieldRingStore>, el: FieldEl<AsFieldRingStore>, hom: &Self::Homomorphism, ) -> <Self as RingBase>::Element
Source§fn map_in_ref(
&self,
from: &S,
el: &S::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in_ref( &self, from: &S, el: &S::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn mul_assign_map_in(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in( &self, from: &S, lhs: &mut Self::Element, rhs: S::Element, hom: &Self::Homomorphism, )
rhs
, and multiplies the result to lhs
.Source§fn mul_assign_map_in_ref(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: &S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in_ref( &self, from: &S, lhs: &mut Self::Element, rhs: &S::Element, hom: &Self::Homomorphism, )
rhs
, taking it by reference, and multiplies the result to lhs
.Source§fn fma_map_in(
&self,
from: &S,
lhs: &Self::Element,
rhs: &S::Element,
summand: Self::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn fma_map_in( &self, from: &S, lhs: &Self::Element, rhs: &S::Element, summand: Self::Element, hom: &Self::Homomorphism, ) -> Self::Element
summand + lhs * rhs
, where rhs
is mapped into the ring via the homomorphism.Source§impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<AsLocalPIRBase<AsLocalPIRStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<AsLocalPIRBase<AsLocalPIRStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
Source§fn has_canonical_hom(
&self,
from: &AsLocalPIRBase<AsLocalPIRStore>,
) -> Option<Self::Homomorphism>
fn has_canonical_hom( &self, from: &AsLocalPIRBase<AsLocalPIRStore>, ) -> Option<Self::Homomorphism>
from -> self
, returns Some(data)
, where
data
is additional data that can be used to compute the action of the homomorphism
on ring elements. Otherwise, None
is returned.Source§fn map_in(
&self,
from: &AsLocalPIRBase<AsLocalPIRStore>,
el: LocalPIREl<AsLocalPIRStore>,
hom: &Self::Homomorphism,
) -> <Self as RingBase>::Element
fn map_in( &self, from: &AsLocalPIRBase<AsLocalPIRStore>, el: LocalPIREl<AsLocalPIRStore>, hom: &Self::Homomorphism, ) -> <Self as RingBase>::Element
Source§fn map_in_ref(
&self,
from: &S,
el: &S::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in_ref( &self, from: &S, el: &S::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn mul_assign_map_in(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in( &self, from: &S, lhs: &mut Self::Element, rhs: S::Element, hom: &Self::Homomorphism, )
rhs
, and multiplies the result to lhs
.Source§fn mul_assign_map_in_ref(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: &S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in_ref( &self, from: &S, lhs: &mut Self::Element, rhs: &S::Element, hom: &Self::Homomorphism, )
rhs
, taking it by reference, and multiplies the result to lhs
.Source§fn fma_map_in(
&self,
from: &S,
lhs: &Self::Element,
rhs: &S::Element,
summand: Self::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn fma_map_in( &self, from: &S, lhs: &Self::Element, rhs: &S::Element, summand: Self::Element, hom: &Self::Homomorphism, ) -> Self::Element
summand + lhs * rhs
, where rhs
is mapped into the ring via the homomorphism.Source§impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsFieldBase<AsFieldRingStore>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsFieldBase<AsFieldRingStore>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
Source§fn has_canonical_hom(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
) -> Option<Self::Homomorphism>
fn has_canonical_hom( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, ) -> Option<Self::Homomorphism>
from -> self
, returns Some(data)
, where
data
is additional data that can be used to compute the action of the homomorphism
on ring elements. Otherwise, None
is returned.Source§fn map_in(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
el: <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element,
hom: &Self::Homomorphism,
) -> <Self as RingBase>::Element
fn map_in( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, el: <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element, hom: &Self::Homomorphism, ) -> <Self as RingBase>::Element
Source§fn map_in_ref(
&self,
from: &S,
el: &S::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in_ref( &self, from: &S, el: &S::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn mul_assign_map_in(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in( &self, from: &S, lhs: &mut Self::Element, rhs: S::Element, hom: &Self::Homomorphism, )
rhs
, and multiplies the result to lhs
.Source§fn mul_assign_map_in_ref(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: &S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in_ref( &self, from: &S, lhs: &mut Self::Element, rhs: &S::Element, hom: &Self::Homomorphism, )
rhs
, taking it by reference, and multiplies the result to lhs
.Source§fn fma_map_in(
&self,
from: &S,
lhs: &Self::Element,
rhs: &S::Element,
summand: Self::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn fma_map_in( &self, from: &S, lhs: &Self::Element, rhs: &S::Element, summand: Self::Element, hom: &Self::Homomorphism, ) -> Self::Element
summand + lhs * rhs
, where rhs
is mapped into the ring via the homomorphism.Source§impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsLocalPIRBase<AsLocalPIRStore>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsLocalPIRBase<AsLocalPIRStore>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanHomFrom<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
type Homomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Homomorphism
Source§fn has_canonical_hom(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
) -> Option<Self::Homomorphism>
fn has_canonical_hom( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, ) -> Option<Self::Homomorphism>
from -> self
, returns Some(data)
, where
data
is additional data that can be used to compute the action of the homomorphism
on ring elements. Otherwise, None
is returned.Source§fn map_in(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
el: <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element,
hom: &Self::Homomorphism,
) -> <Self as RingBase>::Element
fn map_in( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, el: <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element, hom: &Self::Homomorphism, ) -> <Self as RingBase>::Element
Source§fn map_in_ref(
&self,
from: &S,
el: &S::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in_ref( &self, from: &S, el: &S::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn mul_assign_map_in(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in( &self, from: &S, lhs: &mut Self::Element, rhs: S::Element, hom: &Self::Homomorphism, )
rhs
, and multiplies the result to lhs
.Source§fn mul_assign_map_in_ref(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: &S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in_ref( &self, from: &S, lhs: &mut Self::Element, rhs: &S::Element, hom: &Self::Homomorphism, )
rhs
, taking it by reference, and multiplies the result to lhs
.Source§fn fma_map_in(
&self,
from: &S,
lhs: &Self::Element,
rhs: &S::Element,
summand: Self::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn fma_map_in( &self, from: &S, lhs: &Self::Element, rhs: &S::Element, summand: Self::Element, hom: &Self::Homomorphism, ) -> Self::Element
summand + lhs * rhs
, where rhs
is mapped into the ring via the homomorphism.Source§impl<R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
R1: RingStore,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
R2::Type: CanHomFrom<R1::Type>,
impl<R1, V1, A1, C1, R2, V2, A2, C2> CanHomFrom<FreeAlgebraImplBase<R1, V1, A1, C1>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
R1: RingStore,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
R2::Type: CanHomFrom<R1::Type>,
Source§type Homomorphism = <<R2 as RingStore>::Type as CanHomFrom<<R1 as RingStore>::Type>>::Homomorphism
type Homomorphism = <<R2 as RingStore>::Type as CanHomFrom<<R1 as RingStore>::Type>>::Homomorphism
Source§fn has_canonical_hom(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
) -> Option<Self::Homomorphism>
fn has_canonical_hom( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, ) -> Option<Self::Homomorphism>
from -> self
, returns Some(data)
, where
data
is additional data that can be used to compute the action of the homomorphism
on ring elements. Otherwise, None
is returned.Source§fn map_in(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
el: <FreeAlgebraImplBase<R1, V1, A1> as RingBase>::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, el: <FreeAlgebraImplBase<R1, V1, A1> as RingBase>::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn map_in_ref(
&self,
from: &S,
el: &S::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in_ref( &self, from: &S, el: &S::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn mul_assign_map_in(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in( &self, from: &S, lhs: &mut Self::Element, rhs: S::Element, hom: &Self::Homomorphism, )
rhs
, and multiplies the result to lhs
.Source§fn mul_assign_map_in_ref(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: &S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in_ref( &self, from: &S, lhs: &mut Self::Element, rhs: &S::Element, hom: &Self::Homomorphism, )
rhs
, taking it by reference, and multiplies the result to lhs
.Source§fn fma_map_in(
&self,
from: &S,
lhs: &Self::Element,
rhs: &S::Element,
summand: Self::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn fma_map_in( &self, from: &S, lhs: &Self::Element, rhs: &S::Element, summand: Self::Element, hom: &Self::Homomorphism, ) -> Self::Element
summand + lhs * rhs
, where rhs
is mapped into the ring via the homomorphism.Source§impl<Impl, R, A, V, C> CanHomFrom<GaloisFieldBase<Impl>> for FreeAlgebraImplBase<R, V, A, C>where
Impl: RingStore,
Impl::Type: Field + FreeAlgebra + FiniteRing,
<<Impl::Type as RingExtension>::BaseRing as RingStore>::Type: ZnRing + Field,
R: RingStore,
V: VectorView<El<R>>,
C: ConvolutionAlgorithm<R::Type>,
A: Allocator + Clone,
FreeAlgebraImplBase<R, V, A, C>: CanHomFrom<Impl::Type>,
For the rationale which blanket implementations I chose, see the GaloisFieldBase
.
impl<Impl, R, A, V, C> CanHomFrom<GaloisFieldBase<Impl>> for FreeAlgebraImplBase<R, V, A, C>where
Impl: RingStore,
Impl::Type: Field + FreeAlgebra + FiniteRing,
<<Impl::Type as RingExtension>::BaseRing as RingStore>::Type: ZnRing + Field,
R: RingStore,
V: VectorView<El<R>>,
C: ConvolutionAlgorithm<R::Type>,
A: Allocator + Clone,
FreeAlgebraImplBase<R, V, A, C>: CanHomFrom<Impl::Type>,
For the rationale which blanket implementations I chose, see the GaloisFieldBase
.
Source§type Homomorphism = <FreeAlgebraImplBase<R, V, A, C> as CanHomFrom<<Impl as RingStore>::Type>>::Homomorphism
type Homomorphism = <FreeAlgebraImplBase<R, V, A, C> as CanHomFrom<<Impl as RingStore>::Type>>::Homomorphism
Source§fn has_canonical_hom(
&self,
from: &GaloisFieldBase<Impl>,
) -> Option<Self::Homomorphism>
fn has_canonical_hom( &self, from: &GaloisFieldBase<Impl>, ) -> Option<Self::Homomorphism>
from -> self
, returns Some(data)
, where
data
is additional data that can be used to compute the action of the homomorphism
on ring elements. Otherwise, None
is returned.Source§fn map_in(
&self,
from: &GaloisFieldBase<Impl>,
el: <GaloisFieldBase<Impl> as RingBase>::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in( &self, from: &GaloisFieldBase<Impl>, el: <GaloisFieldBase<Impl> as RingBase>::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn map_in_ref(
&self,
from: &S,
el: &S::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn map_in_ref( &self, from: &S, el: &S::Element, hom: &Self::Homomorphism, ) -> Self::Element
Source§fn mul_assign_map_in(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in( &self, from: &S, lhs: &mut Self::Element, rhs: S::Element, hom: &Self::Homomorphism, )
rhs
, and multiplies the result to lhs
.Source§fn mul_assign_map_in_ref(
&self,
from: &S,
lhs: &mut Self::Element,
rhs: &S::Element,
hom: &Self::Homomorphism,
)
fn mul_assign_map_in_ref( &self, from: &S, lhs: &mut Self::Element, rhs: &S::Element, hom: &Self::Homomorphism, )
rhs
, taking it by reference, and multiplies the result to lhs
.Source§fn fma_map_in(
&self,
from: &S,
lhs: &Self::Element,
rhs: &S::Element,
summand: Self::Element,
hom: &Self::Homomorphism,
) -> Self::Element
fn fma_map_in( &self, from: &S, lhs: &Self::Element, rhs: &S::Element, summand: Self::Element, hom: &Self::Homomorphism, ) -> Self::Element
summand + lhs * rhs
, where rhs
is mapped into the ring via the homomorphism.Source§impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<AsFieldBase<AsFieldRingStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<AsFieldBase<AsFieldRingStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
Source§fn has_canonical_iso(
&self,
from: &AsFieldBase<AsFieldRingStore>,
) -> Option<Self::Isomorphism>
fn has_canonical_iso( &self, from: &AsFieldBase<AsFieldRingStore>, ) -> Option<Self::Isomorphism>
from -> self
, and this homomorphism
is an isomorphism, returns Some(data)
, where data
is additional data that
can be used to compute preimages under the homomorphism. Otherwise, None
is
returned.Source§fn map_out(
&self,
from: &AsFieldBase<AsFieldRingStore>,
el: <Self as RingBase>::Element,
hom: &Self::Isomorphism,
) -> FieldEl<AsFieldRingStore>
fn map_out( &self, from: &AsFieldBase<AsFieldRingStore>, el: <Self as RingBase>::Element, hom: &Self::Isomorphism, ) -> FieldEl<AsFieldRingStore>
el
under the canonical homomorphism from -> self
.Source§impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<AsLocalPIRBase<AsLocalPIRStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<AsLocalPIRBase<AsLocalPIRStore>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R1, V1, A1, C1>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
Source§fn has_canonical_iso(
&self,
from: &AsLocalPIRBase<AsLocalPIRStore>,
) -> Option<Self::Isomorphism>
fn has_canonical_iso( &self, from: &AsLocalPIRBase<AsLocalPIRStore>, ) -> Option<Self::Isomorphism>
from -> self
, and this homomorphism
is an isomorphism, returns Some(data)
, where data
is additional data that
can be used to compute preimages under the homomorphism. Otherwise, None
is
returned.Source§fn map_out(
&self,
from: &AsLocalPIRBase<AsLocalPIRStore>,
el: <Self as RingBase>::Element,
hom: &Self::Isomorphism,
) -> LocalPIREl<AsLocalPIRStore>
fn map_out( &self, from: &AsLocalPIRBase<AsLocalPIRStore>, el: <Self as RingBase>::Element, hom: &Self::Isomorphism, ) -> LocalPIREl<AsLocalPIRStore>
el
under the canonical homomorphism from -> self
.Source§impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsFieldBase<AsFieldRingStore>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsFieldRingStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsFieldBase<AsFieldRingStore>where
AsFieldRingStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
Source§fn has_canonical_iso(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
) -> Option<Self::Isomorphism>
fn has_canonical_iso( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, ) -> Option<Self::Isomorphism>
from -> self
, and this homomorphism
is an isomorphism, returns Some(data)
, where data
is additional data that
can be used to compute preimages under the homomorphism. Otherwise, None
is
returned.Source§fn map_out(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
el: <Self as RingBase>::Element,
iso: &Self::Isomorphism,
) -> <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element
fn map_out( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, el: <Self as RingBase>::Element, iso: &Self::Isomorphism, ) -> <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element
el
under the canonical homomorphism from -> self
.Source§impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsLocalPIRBase<AsLocalPIRStore>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
impl<AsLocalPIRStore, R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>> for AsLocalPIRBase<AsLocalPIRStore>where
AsLocalPIRStore: RingStore<Type = FreeAlgebraImplBase<R2, V2, A2, C2>>,
R1: RingStore,
R1::Type: LinSolveRing,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
R2::Type: LinSolveRing + CanIsoFromTo<R1::Type>,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
Source§type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
type Isomorphism = <FreeAlgebraImplBase<R2, V2, A2, C2> as CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>>>::Isomorphism
Source§fn has_canonical_iso(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
) -> Option<Self::Isomorphism>
fn has_canonical_iso( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, ) -> Option<Self::Isomorphism>
from -> self
, and this homomorphism
is an isomorphism, returns Some(data)
, where data
is additional data that
can be used to compute preimages under the homomorphism. Otherwise, None
is
returned.Source§fn map_out(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
el: <Self as RingBase>::Element,
iso: &Self::Isomorphism,
) -> <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element
fn map_out( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, el: <Self as RingBase>::Element, iso: &Self::Isomorphism, ) -> <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element
el
under the canonical homomorphism from -> self
.Source§impl<R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
R1: RingStore,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
R2::Type: CanIsoFromTo<R1::Type>,
impl<R1, V1, A1, C1, R2, V2, A2, C2> CanIsoFromTo<FreeAlgebraImplBase<R1, V1, A1, C1>> for FreeAlgebraImplBase<R2, V2, A2, C2>where
R1: RingStore,
V1: VectorView<El<R1>>,
A1: Allocator + Clone,
C1: ConvolutionAlgorithm<R1::Type>,
R2: RingStore,
V2: VectorView<El<R2>>,
A2: Allocator + Clone,
C2: ConvolutionAlgorithm<R2::Type>,
R2::Type: CanIsoFromTo<R1::Type>,
Source§type Isomorphism = <<R2 as RingStore>::Type as CanIsoFromTo<<R1 as RingStore>::Type>>::Isomorphism
type Isomorphism = <<R2 as RingStore>::Type as CanIsoFromTo<<R1 as RingStore>::Type>>::Isomorphism
Source§fn has_canonical_iso(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
) -> Option<Self::Isomorphism>
fn has_canonical_iso( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, ) -> Option<Self::Isomorphism>
from -> self
, and this homomorphism
is an isomorphism, returns Some(data)
, where data
is additional data that
can be used to compute preimages under the homomorphism. Otherwise, None
is
returned.Source§fn map_out(
&self,
from: &FreeAlgebraImplBase<R1, V1, A1, C1>,
el: <FreeAlgebraImplBase<R2, V2, A2> as RingBase>::Element,
iso: &Self::Isomorphism,
) -> <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element
fn map_out( &self, from: &FreeAlgebraImplBase<R1, V1, A1, C1>, el: <FreeAlgebraImplBase<R2, V2, A2> as RingBase>::Element, iso: &Self::Isomorphism, ) -> <FreeAlgebraImplBase<R1, V1, A1, C1> as RingBase>::Element
el
under the canonical homomorphism from -> self
.Source§impl<Impl, R, A, V, C> CanIsoFromTo<GaloisFieldBase<Impl>> for FreeAlgebraImplBase<R, V, A, C>where
Impl: RingStore,
Impl::Type: Field + FreeAlgebra + FiniteRing,
<<Impl::Type as RingExtension>::BaseRing as RingStore>::Type: ZnRing + Field,
R: RingStore,
V: VectorView<El<R>>,
C: ConvolutionAlgorithm<R::Type>,
A: Allocator + Clone,
FreeAlgebraImplBase<R, V, A, C>: CanIsoFromTo<Impl::Type>,
For the rationale which blanket implementations I chose, see the GaloisFieldBase
.
impl<Impl, R, A, V, C> CanIsoFromTo<GaloisFieldBase<Impl>> for FreeAlgebraImplBase<R, V, A, C>where
Impl: RingStore,
Impl::Type: Field + FreeAlgebra + FiniteRing,
<<Impl::Type as RingExtension>::BaseRing as RingStore>::Type: ZnRing + Field,
R: RingStore,
V: VectorView<El<R>>,
C: ConvolutionAlgorithm<R::Type>,
A: Allocator + Clone,
FreeAlgebraImplBase<R, V, A, C>: CanIsoFromTo<Impl::Type>,
For the rationale which blanket implementations I chose, see the GaloisFieldBase
.
Source§type Isomorphism = <FreeAlgebraImplBase<R, V, A, C> as CanIsoFromTo<<Impl as RingStore>::Type>>::Isomorphism
type Isomorphism = <FreeAlgebraImplBase<R, V, A, C> as CanIsoFromTo<<Impl as RingStore>::Type>>::Isomorphism
Source§fn has_canonical_iso(
&self,
from: &GaloisFieldBase<Impl>,
) -> Option<Self::Isomorphism>
fn has_canonical_iso( &self, from: &GaloisFieldBase<Impl>, ) -> Option<Self::Isomorphism>
from -> self
, and this homomorphism
is an isomorphism, returns Some(data)
, where data
is additional data that
can be used to compute preimages under the homomorphism. Otherwise, None
is
returned.Source§fn map_out(
&self,
from: &GaloisFieldBase<Impl>,
el: Self::Element,
iso: &Self::Isomorphism,
) -> <GaloisFieldBase<Impl> as RingBase>::Element
fn map_out( &self, from: &GaloisFieldBase<Impl>, el: Self::Element, iso: &Self::Isomorphism, ) -> <GaloisFieldBase<Impl> as RingBase>::Element
el
under the canonical homomorphism from -> self
.Source§impl<R, V, A, C> Clone for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore + Clone,
V: VectorView<El<R>> + Clone,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type> + Clone,
impl<R, V, A, C> Clone for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore + Clone,
V: VectorView<El<R>> + Clone,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type> + Clone,
Source§impl<R, V, A, C> Debug for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore + Debug,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
impl<R, V, A, C> Debug for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore + Debug,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
Source§impl<'de, R> Deserialize<'de> for FreeAlgebraImplBase<R, SparseMapVector<R>, Global, KaratsubaAlgorithm>
impl<'de, R> Deserialize<'de> for FreeAlgebraImplBase<R, SparseMapVector<R>, Global, KaratsubaAlgorithm>
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Source§impl<'de, R> Deserialize<'de> for FreeAlgebraImplBase<R, Vec<El<R>>, Global, KaratsubaAlgorithm>
impl<'de, R> Deserialize<'de> for FreeAlgebraImplBase<R, Vec<El<R>>, Global, KaratsubaAlgorithm>
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Source§impl<R, V, A, C> DivisibilityRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: LinSolveRing,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
It seems like a good idea to also implement DivisibilityRing::prepare_divisor()
and the prepared division functions here. However, currently the interface of
LinSolveRing
does not support this. I am not yet sure what is the best approach
here, but it seems unlikely that this can be done properly without a breaking release
impl<R, V, A, C> DivisibilityRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: LinSolveRing,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
It seems like a good idea to also implement DivisibilityRing::prepare_divisor()
and the prepared division functions here. However, currently the interface of
LinSolveRing
does not support this. I am not yet sure what is the best approach
here, but it seems unlikely that this can be done properly without a breaking release
- Either change
LinSolveRing
to support “factorizations” of matrices, or rather the equivalent to “prepared divisors” of matrices - Implement
DivisibilityRing::prepare_divisor()
only forR::Type: [
PrincipalIdealRing]
, which however requires specialization or a specialization workaround
TODO: Decide and implement on the next breaking release
Source§fn checked_left_div(
&self,
lhs: &Self::Element,
rhs: &Self::Element,
) -> Option<Self::Element>
fn checked_left_div( &self, lhs: &Self::Element, rhs: &Self::Element, ) -> Option<Self::Element>
x
such that rhs * x = lhs
, and
returns it if it exists. Read moreSource§fn balance_factor<'a, I>(&self, elements: I) -> Option<Self::Element>
fn balance_factor<'a, I>(&self, elements: I) -> Option<Self::Element>
Source§default fn invert(&self, el: &Self::Element) -> Option<Self::Element>
default fn invert(&self, el: &Self::Element) -> Option<Self::Element>
None
. Read moreSource§type PreparedDivisorData = ()
type PreparedDivisorData = ()
Source§fn divides_left(&self, lhs: &Self::Element, rhs: &Self::Element) -> bool
fn divides_left(&self, lhs: &Self::Element, rhs: &Self::Element) -> bool
x
such that rhs * x = lhs
.
If you need such an element, consider using DivisibilityRing::checked_left_div()
. Read moreSource§fn divides(&self, lhs: &Self::Element, rhs: &Self::Element) -> bool
fn divides(&self, lhs: &Self::Element, rhs: &Self::Element) -> bool
DivisibilityRing::divides_left()
, but requires a commutative ring.Source§fn checked_div(
&self,
lhs: &Self::Element,
rhs: &Self::Element,
) -> Option<Self::Element>
fn checked_div( &self, lhs: &Self::Element, rhs: &Self::Element, ) -> Option<Self::Element>
DivisibilityRing::checked_left_div()
, but requires a commutative ring.Source§fn is_unit(&self, x: &Self::Element) -> bool
fn is_unit(&self, x: &Self::Element) -> bool
Source§fn prepare_divisor(&self, _: &Self::Element) -> Self::PreparedDivisorData
fn prepare_divisor(&self, _: &Self::Element) -> Self::PreparedDivisorData
Source§fn checked_left_div_prepared(
&self,
lhs: &Self::Element,
rhs: &Self::Element,
_rhs_prep: &Self::PreparedDivisorData,
) -> Option<Self::Element>
fn checked_left_div_prepared( &self, lhs: &Self::Element, rhs: &Self::Element, _rhs_prep: &Self::PreparedDivisorData, ) -> Option<Self::Element>
DivisibilityRing::checked_left_div()
but for a prepared divisor. Read moreSource§fn divides_left_prepared(
&self,
lhs: &Self::Element,
rhs: &Self::Element,
_rhs_prep: &Self::PreparedDivisorData,
) -> bool
fn divides_left_prepared( &self, lhs: &Self::Element, rhs: &Self::Element, _rhs_prep: &Self::PreparedDivisorData, ) -> bool
DivisibilityRing::divides_left()
but for a prepared divisor. Read moreSource§fn is_unit_prepared(&self, x: &PreparedDivisor<Self>) -> bool
fn is_unit_prepared(&self, x: &PreparedDivisor<Self>) -> bool
DivisibilityRing::is_unit()
but for a prepared divisor. Read moreSource§impl<R, V, A, C> FiniteRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: FiniteRing,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
impl<R, V, A, C> FiniteRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: FiniteRing,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
Source§type ElementsIter<'a> = MultiProduct<<<R as RingStore>::Type as FiniteRing>::ElementsIter<'a>, WRTCanonicalBasisElementCreator<'a, R, V, A, C>, CloneRingEl<&'a R>, <FreeAlgebraImplBase<R, V, A, C> as RingBase>::Element>
where
Self: 'a
type ElementsIter<'a> = MultiProduct<<<R as RingStore>::Type as FiniteRing>::ElementsIter<'a>, WRTCanonicalBasisElementCreator<'a, R, V, A, C>, CloneRingEl<&'a R>, <FreeAlgebraImplBase<R, V, A, C> as RingBase>::Element> where Self: 'a
FiniteRing::elements()
, which should
iterate over all elements of the ring.Source§fn elements<'a>(&'a self) -> Self::ElementsIter<'a>
fn elements<'a>(&'a self) -> Self::ElementsIter<'a>
Source§fn size<I: IntegerRingStore + Copy>(&self, ZZ: I) -> Option<El<I>>where
I::Type: IntegerRing,
fn size<I: IntegerRingStore + Copy>(&self, ZZ: I) -> Option<El<I>>where
I::Type: IntegerRing,
Source§impl<R, V, A, C> FiniteRingSpecializable for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: FiniteRingSpecializable,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
impl<R, V, A, C> FiniteRingSpecializable for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: FiniteRingSpecializable,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
Source§fn specialize<O: FiniteRingOperation<Self>>(op: O) -> O::Output
fn specialize<O: FiniteRingOperation<Self>>(op: O) -> O::Output
unstable-enable
only.Source§fn is_finite_ring() -> bool
fn is_finite_ring() -> bool
unstable-enable
only.Source§impl<R, V, A, C> FreeAlgebra for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> FreeAlgebra for FreeAlgebraImplBase<R, V, A, C>
Source§type VectorRepresentation<'a> = CloneElFn<&'a [<<R as RingStore>::Type as RingBase>::Element], <<R as RingStore>::Type as RingBase>::Element, CloneRingEl<&'a R>>
where
Self: 'a
type VectorRepresentation<'a> = CloneElFn<&'a [<<R as RingStore>::Type as RingBase>::Element], <<R as RingStore>::Type as RingBase>::Element, CloneRingEl<&'a R>> where Self: 'a
FreeAlgebra::wrt_canonical_basis()
.Source§fn canonical_gen(&self) -> Self::Element
fn canonical_gen(&self) -> Self::Element
Source§fn wrt_canonical_basis<'a>(
&'a self,
el: &'a Self::Element,
) -> Self::VectorRepresentation<'a>
fn wrt_canonical_basis<'a>( &'a self, el: &'a Self::Element, ) -> Self::VectorRepresentation<'a>
x^i
where x
is the canonical generator given by FreeAlgebra::canonical_gen()
and i
goes from 0
to rank - 1
. Read moreSource§fn from_canonical_basis<W>(&self, vec: W) -> Self::Element
fn from_canonical_basis<W>(&self, vec: W) -> Self::Element
x^i
where x
is the canonical generator given by FreeAlgebra::canonical_gen()
and i
goes from 0
to rank - 1
. Read moreSource§fn from_canonical_basis_extended<V>(&self, vec: V) -> Self::Element
fn from_canonical_basis_extended<V>(&self, vec: V) -> Self::Element
FreeAlgebra::from_canonical_basis()
, this computes the sum sum_i vec[i] * x^i
where x
is the
canonical generator given by FreeAlgebra::canonical_gen()
. Unlike FreeAlgebra::from_canonical_basis()
,
vec
can return any number elements.Source§fn charpoly<P, H>(&self, el: &Self::Element, poly_ring: P, hom: H) -> El<P>where
P: RingStore,
P::Type: PolyRing,
<<P::Type as RingExtension>::BaseRing as RingStore>::Type: LinSolveRing,
H: Homomorphism<<Self::BaseRing as RingStore>::Type, <<P::Type as RingExtension>::BaseRing as RingStore>::Type>,
fn charpoly<P, H>(&self, el: &Self::Element, poly_ring: P, hom: H) -> El<P>where
P: RingStore,
P::Type: PolyRing,
<<P::Type as RingExtension>::BaseRing as RingStore>::Type: LinSolveRing,
H: Homomorphism<<Self::BaseRing as RingStore>::Type, <<P::Type as RingExtension>::BaseRing as RingStore>::Type>,
Source§fn minpoly<P, H>(&self, el: &Self::Element, poly_ring: P, hom: H) -> El<P>where
P: RingStore,
P::Type: PolyRing,
<<P::Type as RingExtension>::BaseRing as RingStore>::Type: LinSolveRing,
H: Homomorphism<<Self::BaseRing as RingStore>::Type, <<P::Type as RingExtension>::BaseRing as RingStore>::Type>,
fn minpoly<P, H>(&self, el: &Self::Element, poly_ring: P, hom: H) -> El<P>where
P: RingStore,
P::Type: PolyRing,
<<P::Type as RingExtension>::BaseRing as RingStore>::Type: LinSolveRing,
H: Homomorphism<<Self::BaseRing as RingStore>::Type, <<P::Type as RingExtension>::BaseRing as RingStore>::Type>,
Source§fn trace(&self, el: Self::Element) -> El<Self::BaseRing>
fn trace(&self, el: Self::Element) -> El<Self::BaseRing>
a
in this ring extension, which is defined as the
matrix trace of the multiplication-by-a
map. Read moreSource§impl<R, V, A, C> HashableElRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: HashableElRing,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
impl<R, V, A, C> HashableElRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
R::Type: HashableElRing,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
Source§impl<R, V, A_ring, C_ring> LinSolveRing for FreeAlgebraImplBase<R, V, A_ring, C_ring>where
R: RingStore,
R::Type: LinSolveRing,
V: VectorView<El<R>>,
A_ring: Allocator + Clone,
C_ring: ConvolutionAlgorithm<R::Type>,
impl<R, V, A_ring, C_ring> LinSolveRing for FreeAlgebraImplBase<R, V, A_ring, C_ring>where
R: RingStore,
R::Type: LinSolveRing,
V: VectorView<El<R>>,
A_ring: Allocator + Clone,
C_ring: ConvolutionAlgorithm<R::Type>,
Source§fn solve_right<V1, V2, V3, A>(
&self,
lhs: SubmatrixMut<'_, V1, Self::Element>,
rhs: SubmatrixMut<'_, V2, Self::Element>,
out: SubmatrixMut<'_, V3, Self::Element>,
allocator: A,
) -> SolveResultwhere
V1: AsPointerToSlice<Self::Element>,
V2: AsPointerToSlice<Self::Element>,
V3: AsPointerToSlice<Self::Element>,
A: Allocator,
fn solve_right<V1, V2, V3, A>(
&self,
lhs: SubmatrixMut<'_, V1, Self::Element>,
rhs: SubmatrixMut<'_, V2, Self::Element>,
out: SubmatrixMut<'_, V3, Self::Element>,
allocator: A,
) -> SolveResultwhere
V1: AsPointerToSlice<Self::Element>,
V2: AsPointerToSlice<Self::Element>,
V3: AsPointerToSlice<Self::Element>,
A: Allocator,
Source§impl<R, V, A, C> PartialEq for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> PartialEq for FreeAlgebraImplBase<R, V, A, C>
Source§impl<R, V, A, C> RingBase for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> RingBase for FreeAlgebraImplBase<R, V, A, C>
Source§type Element = FreeAlgebraImplEl<R, A>
type Element = FreeAlgebraImplEl<R, A>
fn clone_el(&self, val: &Self::Element) -> Self::Element
fn add_assign_ref(&self, lhs: &mut Self::Element, rhs: &Self::Element)
fn add_assign(&self, lhs: &mut Self::Element, rhs: Self::Element)
fn sub_assign_ref(&self, lhs: &mut Self::Element, rhs: &Self::Element)
fn negate_inplace(&self, lhs: &mut Self::Element)
fn mul_assign(&self, lhs: &mut Self::Element, rhs: Self::Element)
fn mul_assign_ref(&self, lhs: &mut Self::Element, rhs: &Self::Element)
Source§fn fma(
&self,
lhs: &Self::Element,
rhs: &Self::Element,
summand: Self::Element,
) -> Self::Element
fn fma( &self, lhs: &Self::Element, rhs: &Self::Element, summand: Self::Element, ) -> Self::Element
summand + lhs * rhs
.fn from_int(&self, value: i32) -> Self::Element
fn eq_el(&self, lhs: &Self::Element, rhs: &Self::Element) -> bool
fn is_zero(&self, value: &Self::Element) -> bool
fn is_one(&self, value: &Self::Element) -> bool
fn is_neg_one(&self, value: &Self::Element) -> bool
Source§fn is_commutative(&self) -> bool
fn is_commutative(&self) -> bool
a * b = b * a
for all elements a, b
.
Note that addition is assumed to be always commutative.Source§fn is_noetherian(&self) -> bool
fn is_noetherian(&self) -> bool
Source§fn is_approximate(&self) -> bool
fn is_approximate(&self) -> bool
f32
or
f64
, to represent real or complex numbers. Read moreSource§fn dbg_within<'a>(
&self,
value: &Self::Element,
out: &mut Formatter<'a>,
env: EnvBindingStrength,
) -> Result
fn dbg_within<'a>( &self, value: &Self::Element, out: &mut Formatter<'a>, env: EnvBindingStrength, ) -> Result
value
to out
, taking into account the possible context
to place parenthesis as needed. Read morefn mul_assign_int(&self, lhs: &mut Self::Element, rhs: i32)
Source§fn fma_int(
&self,
lhs: &Self::Element,
rhs: i32,
summand: Self::Element,
) -> Self::Element
fn fma_int( &self, lhs: &Self::Element, rhs: i32, summand: Self::Element, ) -> Self::Element
summand + lhs * rhs
.Source§fn characteristic<I: IntegerRingStore + Copy>(&self, ZZ: I) -> Option<El<I>>where
I::Type: IntegerRing,
fn characteristic<I: IntegerRingStore + Copy>(&self, ZZ: I) -> Option<El<I>>where
I::Type: IntegerRing,
ZZ
. Read morefn square(&self, value: &mut Self::Element)
fn zero(&self) -> Self::Element
fn one(&self) -> Self::Element
fn neg_one(&self) -> Self::Element
fn negate(&self, value: Self::Element) -> Self::Element
fn sub_assign(&self, lhs: &mut Self::Element, rhs: Self::Element)
fn mul_int(&self, lhs: Self::Element, rhs: i32) -> Self::Element
fn mul_int_ref(&self, lhs: &Self::Element, rhs: i32) -> Self::Element
Source§fn sub_self_assign(&self, lhs: &mut Self::Element, rhs: Self::Element)
fn sub_self_assign(&self, lhs: &mut Self::Element, rhs: Self::Element)
lhs := rhs - lhs
.Source§fn sub_self_assign_ref(&self, lhs: &mut Self::Element, rhs: &Self::Element)
fn sub_self_assign_ref(&self, lhs: &mut Self::Element, rhs: &Self::Element)
lhs := rhs - lhs
.fn add_ref(&self, lhs: &Self::Element, rhs: &Self::Element) -> Self::Element
fn add_ref_fst(&self, lhs: &Self::Element, rhs: Self::Element) -> Self::Element
fn add_ref_snd(&self, lhs: Self::Element, rhs: &Self::Element) -> Self::Element
fn add(&self, lhs: Self::Element, rhs: Self::Element) -> Self::Element
fn sub_ref(&self, lhs: &Self::Element, rhs: &Self::Element) -> Self::Element
fn sub_ref_fst(&self, lhs: &Self::Element, rhs: Self::Element) -> Self::Element
fn sub_ref_snd(&self, lhs: Self::Element, rhs: &Self::Element) -> Self::Element
fn sub(&self, lhs: Self::Element, rhs: Self::Element) -> Self::Element
fn mul_ref(&self, lhs: &Self::Element, rhs: &Self::Element) -> Self::Element
fn mul_ref_fst(&self, lhs: &Self::Element, rhs: Self::Element) -> Self::Element
fn mul_ref_snd(&self, lhs: Self::Element, rhs: &Self::Element) -> Self::Element
fn mul(&self, lhs: Self::Element, rhs: Self::Element) -> Self::Element
Source§fn pow_gen<R: RingStore>(
&self,
x: Self::Element,
power: &El<R>,
integers: R,
) -> Self::Elementwhere
R::Type: IntegerRing,
fn pow_gen<R: RingStore>(
&self,
x: Self::Element,
power: &El<R>,
integers: R,
) -> Self::Elementwhere
R::Type: IntegerRing,
x
to the power of an arbitrary, nonnegative integer given by
a custom integer ring implementation. Read moreSource§impl<R, V, A, C> RingExtension for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> RingExtension for FreeAlgebraImplBase<R, V, A, C>
Source§fn from(&self, x: El<Self::BaseRing>) -> Self::Element
fn from(&self, x: El<Self::BaseRing>) -> Self::Element
Source§fn mul_assign_base(&self, lhs: &mut Self::Element, rhs: &El<Self::BaseRing>)
fn mul_assign_base(&self, lhs: &mut Self::Element, rhs: &El<Self::BaseRing>)
lhs := lhs * rhs
, where rhs
is mapped into this
ring via RingExtension::from_ref()
. Note that this may be
faster than self.mul_assign(lhs, self.from_ref(rhs))
.fn fma_base( &self, lhs: &Self::Element, rhs: &El<Self::BaseRing>, summand: Self::Element, ) -> Self::Element
Source§fn from_ref(&self, x: &El<Self::BaseRing>) -> Self::Element
fn from_ref(&self, x: &El<Self::BaseRing>) -> Self::Element
Source§fn mul_assign_base_through_hom<S: ?Sized + RingBase, H: Homomorphism<S, <Self::BaseRing as RingStore>::Type>>(
&self,
lhs: &mut Self::Element,
rhs: &S::Element,
hom: H,
)
fn mul_assign_base_through_hom<S: ?Sized + RingBase, H: Homomorphism<S, <Self::BaseRing as RingStore>::Type>>( &self, lhs: &mut Self::Element, rhs: &S::Element, hom: H, )
lhs := lhs * rhs
, where rhs
is mapped into this ring
via the given homomorphism, followed by the inclusion (as specified by
RingExtension::from_ref()
). Read moreSource§impl<R, V, A, C> SerializableElementRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
R::Type: SerializableElementRing,
impl<R, V, A, C> SerializableElementRing for FreeAlgebraImplBase<R, V, A, C>where
R: RingStore,
V: VectorView<El<R>>,
A: Allocator + Clone,
C: ConvolutionAlgorithm<R::Type>,
R::Type: SerializableElementRing,
Source§fn deserialize<'de, D>(
&self,
deserializer: D,
) -> Result<Self::Element, D::Error>where
D: Deserializer<'de>,
fn deserialize<'de, D>(
&self,
deserializer: D,
) -> Result<Self::Element, D::Error>where
D: Deserializer<'de>,
unstable-enable
only.Source§impl<R, V> Serialize for FreeAlgebraImplBase<R, V, Global, KaratsubaAlgorithm>
impl<R, V> Serialize for FreeAlgebraImplBase<R, V, Global, KaratsubaAlgorithm>
impl<R, V, A, C> Copy for FreeAlgebraImplBase<R, V, A, C>
Auto Trait Implementations§
impl<R, V, A, C> Freeze for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> RefUnwindSafe for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> Send for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> Sync for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> Unpin for FreeAlgebraImplBase<R, V, A, C>
impl<R, V, A, C> UnwindSafe for FreeAlgebraImplBase<R, V, A, C>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<R> ComputeInnerProduct for R
impl<R> ComputeInnerProduct for R
Source§default fn inner_product_ref_fst<'a, I>(
&self,
els: I,
) -> <R as RingBase>::Element
default fn inner_product_ref_fst<'a, I>( &self, els: I, ) -> <R as RingBase>::Element
unstable-enable
only.sum_i lhs[i] * rhs[i]
.Source§default fn inner_product_ref<'a, I>(&self, els: I) -> <R as RingBase>::Element
default fn inner_product_ref<'a, I>(&self, els: I) -> <R as RingBase>::Element
unstable-enable
only.sum_i lhs[i] * rhs[i]
.Source§impl<R, S> CooleyTuckeyButterfly<S> for R
impl<R, S> CooleyTuckeyButterfly<S> for R
Source§default fn butterfly<V, H>(
&self,
hom: H,
values: &mut V,
twiddle: &<S as RingBase>::Element,
i1: usize,
i2: usize,
)
default fn butterfly<V, H>( &self, hom: H, values: &mut V, twiddle: &<S as RingBase>::Element, i1: usize, i2: usize, )
(values[i1], values[i2]) := (values[i1] + twiddle * values[i2], values[i1] - twiddle * values[i2])
. Read moreSource§default fn butterfly_new<H>(
hom: H,
x: &mut <R as RingBase>::Element,
y: &mut <R as RingBase>::Element,
twiddle: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
default fn butterfly_new<H>(
hom: H,
x: &mut <R as RingBase>::Element,
y: &mut <R as RingBase>::Element,
twiddle: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
(x, y) := (x + twiddle * y, x - twiddle * y)
. Read moreSource§default fn inv_butterfly<V, H>(
&self,
hom: H,
values: &mut V,
twiddle: &<S as RingBase>::Element,
i1: usize,
i2: usize,
)
default fn inv_butterfly<V, H>( &self, hom: H, values: &mut V, twiddle: &<S as RingBase>::Element, i1: usize, i2: usize, )
(values[i1], values[i2]) := (values[i1] + values[i2], (values[i1] - values[i2]) * twiddle)
Read moreSource§default fn inv_butterfly_new<H>(
hom: H,
x: &mut <R as RingBase>::Element,
y: &mut <R as RingBase>::Element,
twiddle: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
default fn inv_butterfly_new<H>(
hom: H,
x: &mut <R as RingBase>::Element,
y: &mut <R as RingBase>::Element,
twiddle: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
(x, y) := (x + y, (x - y) * twiddle)
Read moreSource§default fn prepare_for_fft(&self, _value: &mut <R as RingBase>::Element)
default fn prepare_for_fft(&self, _value: &mut <R as RingBase>::Element)
CooleyTuckeyButterfly::butterfly_new()
that the inputs are in this form.Source§default fn prepare_for_inv_fft(&self, _value: &mut <R as RingBase>::Element)
default fn prepare_for_inv_fft(&self, _value: &mut <R as RingBase>::Element)
CooleyTuckeyButterfly::inv_butterfly_new()
that the inputs are in this form.Source§impl<R, S> CooleyTukeyRadix3Butterfly<S> for R
impl<R, S> CooleyTukeyRadix3Butterfly<S> for R
Source§default fn prepare_for_fft(&self, _value: &mut <R as RingBase>::Element)
Available on crate feature unstable-enable
only.
default fn prepare_for_fft(&self, _value: &mut <R as RingBase>::Element)
unstable-enable
only.Possibly pre-processes elements before the FFT starts. Here you can bring ring element
into a certain form, and assume during CooleyTukeyRadix3Butterfly::butterfly()
that the inputs are in this form.
Source§default fn prepare_for_inv_fft(&self, _value: &mut <R as RingBase>::Element)
Available on crate feature unstable-enable
only.
default fn prepare_for_inv_fft(&self, _value: &mut <R as RingBase>::Element)
unstable-enable
only.Possibly pre-processes elements before the inverse FFT starts. Here you can bring ring element
into a certain form, and assume during CooleyTukeyRadix3Butterfly::inv_butterfly()
that the inputs are in this form.
Source§default fn butterfly<H>(
hom: H,
a: &mut <R as RingBase>::Element,
b: &mut <R as RingBase>::Element,
c: &mut <R as RingBase>::Element,
z: &<S as RingBase>::Element,
t: &<S as RingBase>::Element,
t_sqr_z_sqr: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
default fn butterfly<H>(
hom: H,
a: &mut <R as RingBase>::Element,
b: &mut <R as RingBase>::Element,
c: &mut <R as RingBase>::Element,
z: &<S as RingBase>::Element,
t: &<S as RingBase>::Element,
t_sqr_z_sqr: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
unstable-enable
only.(a, b, c) := (a + t b + t^2 c, a + t z b + t^2 z^2 c, a + t z^2 b + t^2 z c)
. Read moreSource§default fn inv_butterfly<H>(
hom: H,
a: &mut <R as RingBase>::Element,
b: &mut <R as RingBase>::Element,
c: &mut <R as RingBase>::Element,
z: &<S as RingBase>::Element,
t: &<S as RingBase>::Element,
t_sqr: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
default fn inv_butterfly<H>(
hom: H,
a: &mut <R as RingBase>::Element,
b: &mut <R as RingBase>::Element,
c: &mut <R as RingBase>::Element,
z: &<S as RingBase>::Element,
t: &<S as RingBase>::Element,
t_sqr: &<S as RingBase>::Element,
)where
H: Homomorphism<S, R>,
unstable-enable
only.(a, b, c) := (a + b + c, t (a + z^2 b + z c), t^2 (a + z b + z^2 c))
. Read moreSource§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<R> KaratsubaHint for R
impl<R> KaratsubaHint for R
Source§default fn karatsuba_threshold(&self) -> usize
default fn karatsuba_threshold(&self) -> usize
unstable-enable
only.KaratsubaAlgorithm
will use the Karatsuba algorithm. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R> StrassenHint for R
impl<R> StrassenHint for R
Source§default fn strassen_threshold(&self) -> usize
default fn strassen_threshold(&self) -> usize
unstable-enable
only.StrassenAlgorithm
will use the Strassen algorithm. Read more