pub struct ModuleHomomorphism<R: Ring> { /* private fields */ }Expand description
An exact homomorphism between finite based free modules.
Matrices act on column coordinates and therefore have shape
target.rank() x source.rank(). Dense and sparse storage are private
representations of the same mathematical map.
Implementations§
Source§impl ModuleHomomorphism<IntegerRing>
impl ModuleHomomorphism<IntegerRing>
Sourcepub fn image(&self) -> Result<ImageSubmodule<IntegerRing>, ModuleError>
pub fn image(&self) -> Result<ImageSubmodule<IntegerRing>, ModuleError>
Canonical image lattice with map-bound completeness evidence.
Sourcepub fn kernel(&self) -> Result<KernelSubmodule<IntegerRing>, ModuleError>
pub fn kernel(&self) -> Result<KernelSubmodule<IntegerRing>, ModuleError>
Canonical complete kernel lattice with map-bound evidence.
Source§impl ModuleHomomorphism<ResidueRing>
impl ModuleHomomorphism<ResidueRing>
Sourcepub fn image(&self) -> Result<ImageSubmodule<ResidueRing>, ModuleError>
pub fn image(&self) -> Result<ImageSubmodule<ResidueRing>, ModuleError>
Canonical image submodule with map-bound completeness evidence.
Sourcepub fn kernel(&self) -> Result<KernelSubmodule<ResidueRing>, ModuleError>
pub fn kernel(&self) -> Result<KernelSubmodule<ResidueRing>, ModuleError>
Canonical complete kernel with evidence over a possibly composite modulus.
Source§impl<R: Ring> ModuleHomomorphism<R>
impl<R: Ring> ModuleHomomorphism<R>
Sourcepub fn from_matrix(
source: FreeModule<R>,
target: FreeModule<R>,
matrix: Matrix<R>,
) -> Result<Self, ModuleError>
pub fn from_matrix( source: FreeModule<R>, target: FreeModule<R>, matrix: Matrix<R>, ) -> Result<Self, ModuleError>
Construct a map from a dense matrix.
Sourcepub fn from_sparse_matrix(
source: FreeModule<R>,
target: FreeModule<R>,
matrix: SparseMatrix<R>,
) -> Result<Self, ModuleError>
pub fn from_sparse_matrix( source: FreeModule<R>, target: FreeModule<R>, matrix: SparseMatrix<R>, ) -> Result<Self, ModuleError>
Construct a map from a canonical sparse matrix.
Sourcepub fn zero(
source: FreeModule<R>,
target: FreeModule<R>,
) -> Result<Self, ModuleError>
pub fn zero( source: FreeModule<R>, target: FreeModule<R>, ) -> Result<Self, ModuleError>
Sparse zero map between two modules over the same exact ring context.
Sourcepub fn identity(module: FreeModule<R>) -> Result<Self, ModuleError>
pub fn identity(module: FreeModule<R>) -> Result<Self, ModuleError>
Sparse identity map of one based free module.
Sourcepub fn source(&self) -> &FreeModule<R>
pub fn source(&self) -> &FreeModule<R>
Source based free module.
Sourcepub fn target(&self) -> &FreeModule<R>
pub fn target(&self) -> &FreeModule<R>
Target based free module.
Sourcepub fn sparse_matrix(&self) -> Option<&SparseMatrix<R>>
pub fn sparse_matrix(&self) -> Option<&SparseMatrix<R>>
Borrow the sparse presentation when this map retains sparse storage.
Sourcepub fn apply(
&self,
element: &ModuleElement<R>,
) -> Result<ModuleElement<R>, ModuleError>
pub fn apply( &self, element: &ModuleElement<R>, ) -> Result<ModuleElement<R>, ModuleError>
Apply this map to an element of its exact source module.
Sourcepub fn compose(&self, inner: &Self) -> Result<Self, ModuleError>
pub fn compose(&self, inner: &Self) -> Result<Self, ModuleError>
Compose self after inner.
Sourcepub fn add(&self, rhs: &Self) -> Result<Self, ModuleError>
pub fn add(&self, rhs: &Self) -> Result<Self, ModuleError>
Add maps with identical source and target based modules.
Sourcepub fn sub(&self, rhs: &Self) -> Result<Self, ModuleError>
pub fn sub(&self, rhs: &Self) -> Result<Self, ModuleError>
Subtract maps with identical source and target based modules.
Sourcepub fn copair(&self, rhs: &Self) -> Result<Self, ModuleError>
pub fn copair(&self, rhs: &Self) -> Result<Self, ModuleError>
Copair maps with one common target into a map from the direct sum of
their sources. Its matrix is the horizontal block [self rhs].
Sourcepub fn pair(&self, rhs: &Self) -> Result<Self, ModuleError>
pub fn pair(&self, rhs: &Self) -> Result<Self, ModuleError>
Pair maps with one common source into a map to the direct sum of their
targets. Its matrix is the vertical block [self; rhs].
Sourcepub fn direct_sum(&self, rhs: &Self) -> Result<Self, ModuleError>
pub fn direct_sum(&self, rhs: &Self) -> Result<Self, ModuleError>
Block-diagonal direct sum of two maps.
Sourcepub fn tensor(&self, rhs: &Self) -> Result<Self, ModuleError>where
R: CommutativeRing,
pub fn tensor(&self, rhs: &Self) -> Result<Self, ModuleError>where
R: CommutativeRing,
Tensor product of maps between finite based free modules.
The tensor bases use the same lexicographic order as
FreeModule::tensor: the left basis position is the outer index and
the right basis position is the inner index. Sparse inputs retain a
sparse Kronecker product without materializing zero coefficients.
Sourcepub fn dual(&self) -> Result<Self, ModuleError>where
R: CommutativeRing,
pub fn dual(&self) -> Result<Self, ModuleError>where
R: CommutativeRing,
Dual map between the dual based free modules.
Sourcepub fn map_coefficients<M>(
&self,
map: &M,
) -> Result<ModuleHomomorphism<M::Target>, ModuleError>where
M: CoefficientMap<Source = R>,
R: Display,
pub fn map_coefficients<M>(
&self,
map: &M,
) -> Result<ModuleHomomorphism<M::Target>, ModuleError>where
M: CoefficientMap<Source = R>,
R: Display,
Apply a checked coefficient map to source, target, and every matrix entry.
Sourcepub fn to_json(&self) -> Result<String, NoetherError>
pub fn to_json(&self) -> Result<String, NoetherError>
Serialize both endpoint modules and the retained matrix layout.
Sourcepub fn from_json(value: &str) -> Result<Self, NoetherError>
pub fn from_json(value: &str) -> Result<Self, NoetherError>
Deserialize and revalidate an exact module homomorphism.
Source§impl ModuleHomomorphism<PolynomialRing<IntegerRing>>
impl ModuleHomomorphism<PolynomialRing<IntegerRing>>
Sourcepub fn kernel(
&self,
order: ModuleMonomialOrder,
) -> Result<Submodule<PolynomialRing<IntegerRing>>, ModuleGroebnerError>
pub fn kernel( &self, order: ModuleMonomialOrder, ) -> Result<Submodule<PolynomialRing<IntegerRing>>, ModuleGroebnerError>
Exact kernel as a generated integral polynomial submodule.
Source§impl<C: Field> ModuleHomomorphism<PolynomialRing<C>>
impl<C: Field> ModuleHomomorphism<PolynomialRing<C>>
Sourcepub fn kernel(
&self,
order: ModuleMonomialOrder,
) -> Result<Submodule<PolynomialRing<C>>, ModuleGroebnerError>
pub fn kernel( &self, order: ModuleMonomialOrder, ) -> Result<Submodule<PolynomialRing<C>>, ModuleGroebnerError>
Exact kernel as a generated submodule of this map’s source.
Source§impl<C: Field> ModuleHomomorphism<QuotientRing<PolynomialRing<C>>>
impl<C: Field> ModuleHomomorphism<QuotientRing<PolynomialRing<C>>>
Sourcepub fn kernel(
&self,
order: ModuleMonomialOrder,
) -> Result<Submodule<QuotientRing<PolynomialRing<C>>>, ModuleGroebnerError>
pub fn kernel( &self, order: ModuleMonomialOrder, ) -> Result<Submodule<QuotientRing<PolynomialRing<C>>>, ModuleGroebnerError>
Exact kernel over a polynomial quotient, computed through the lifted
graph [lift(self), -I e_j] in the ambient polynomial ring.
Source§impl<R: CommutativeRing> ModuleHomomorphism<R>
impl<R: CommutativeRing> ModuleHomomorphism<R>
Sourcepub fn symmetric_power(
&self,
degree: usize,
) -> Result<ModulePowerHomomorphism<R>, ModulePowerError>
pub fn symmetric_power( &self, degree: usize, ) -> Result<ModulePowerHomomorphism<R>, ModulePowerError>
Map induced on the degree-degree symmetric powers.
Sourcepub fn exterior_power(
&self,
degree: usize,
) -> Result<ModulePowerHomomorphism<R>, ModulePowerError>
pub fn exterior_power( &self, degree: usize, ) -> Result<ModulePowerHomomorphism<R>, ModulePowerError>
Map induced on the degree-degree exterior powers.
Trait Implementations§
Source§impl<R: Ring> Add<&ModuleHomomorphism<R>> for &ModuleHomomorphism<R>
impl<R: Ring> Add<&ModuleHomomorphism<R>> for &ModuleHomomorphism<R>
Source§type Output = Result<ModuleHomomorphism<R>, ModuleError>
type Output = Result<ModuleHomomorphism<R>, ModuleError>
+ operator.Source§impl<R: Clone + Ring> Clone for ModuleHomomorphism<R>
impl<R: Clone + Ring> Clone for ModuleHomomorphism<R>
Source§fn clone(&self) -> ModuleHomomorphism<R>
fn clone(&self) -> ModuleHomomorphism<R>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<R: Ring> Debug for ModuleHomomorphism<R>
impl<R: Ring> Debug for ModuleHomomorphism<R>
Source§impl<'de, R> Deserialize<'de> for ModuleHomomorphism<R>
impl<'de, R> Deserialize<'de> for ModuleHomomorphism<R>
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: Ring> Display for ModuleHomomorphism<R>
impl<R: Ring> Display for ModuleHomomorphism<R>
Source§impl<R: Ring> SemanticType for ModuleHomomorphism<R>
impl<R: Ring> SemanticType for ModuleHomomorphism<R>
Source§const TYPE_ID: &'static str = "noether/homalg/ModuleHomomorphism@1"
const TYPE_ID: &'static str = "noether/homalg/ModuleHomomorphism@1"
Source§fn canonical_bytes(&self) -> Result<Vec<u8>, NoetherError>
fn canonical_bytes(&self) -> Result<Vec<u8>, NoetherError>
Source§fn describe() -> &'static TypeDescription
fn describe() -> &'static TypeDescription
Source§impl<R> Serialize for ModuleHomomorphism<R>
impl<R> Serialize for ModuleHomomorphism<R>
Source§impl<R: Ring> Sub<&ModuleHomomorphism<R>> for &ModuleHomomorphism<R>
impl<R: Ring> Sub<&ModuleHomomorphism<R>> for &ModuleHomomorphism<R>
Source§type Output = Result<ModuleHomomorphism<R>, ModuleError>
type Output = Result<ModuleHomomorphism<R>, ModuleError>
- operator.impl<R: Eq + Ring> Eq for ModuleHomomorphism<R>
impl<R: Ring> StructuralPartialEq for ModuleHomomorphism<R>
Auto Trait Implementations§
impl<R> Freeze for ModuleHomomorphism<R>
impl<R> RefUnwindSafe for ModuleHomomorphism<R>
impl<R> Send for ModuleHomomorphism<R>
impl<R> Sync for ModuleHomomorphism<R>
impl<R> Unpin for ModuleHomomorphism<R>
impl<R> UnwindSafe for ModuleHomomorphism<R>
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<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 more