pub struct RelativeInterfaceCertificate { /* private fields */ }Expand description
A filtered chain core relative to protected vertices.
The record includes its input chain complex, cancellation trace, retained
core, and one D V = R reduction per boundary dimension.
Implementations§
Source§impl RelativeInterfaceCertificate
impl RelativeInterfaceCertificate
Sourcepub fn build(
input: &SparseDistanceMatrix,
params: &RipsParams,
protected_vertices: &[usize],
limits: CertificateLimits,
) -> Result<Self, CertificateError>
pub fn build( input: &SparseDistanceMatrix, params: &RipsParams, protected_vertices: &[usize], limits: CertificateLimits, ) -> Result<Self, CertificateError>
Build a relative core from one filtered flag complex.
protected_vertices induces the separator subcomplex that every
cancellation fixes. Vertex labels are the input positions.
Sourcepub fn build_labeled(
input: &SparseDistanceMatrix,
labels: &[usize],
params: &RipsParams,
protected_vertices: &[usize],
limits: CertificateLimits,
) -> Result<Self, CertificateError>
pub fn build_labeled( input: &SparseDistanceMatrix, labels: &[usize], params: &RipsParams, protected_vertices: &[usize], limits: CertificateLimits, ) -> Result<Self, CertificateError>
Build a relative core with explicit global vertex labels.
labels[local] names each input vertex. Labels must be strictly
increasing. Independent child cores identify a shared separator during
Self::compose.
Sourcepub fn build_complex(
complex: &FilteredSimplicialComplex<ScalarGrade>,
max_dim: usize,
modulus: u32,
protected_vertices: &[usize],
limits: CertificateLimits,
) -> Result<Self, CertificateError>
pub fn build_complex( complex: &FilteredSimplicialComplex<ScalarGrade>, max_dim: usize, modulus: u32, protected_vertices: &[usize], limits: CertificateLimits, ) -> Result<Self, CertificateError>
Build a relative core from an explicit scalar filtered complex.
The complex must contain cells through dimension max_dim + 1.
The filtration need not come from a Vietoris-Rips flag construction.
Sourcepub fn compose(
children: &[&Self],
protected_vertices: &[usize],
limits: CertificateLimits,
) -> Result<Self, CertificateError>
pub fn compose( children: &[&Self], protected_vertices: &[usize], limits: CertificateLimits, ) -> Result<Self, CertificateError>
Compose child cores by identifying cells with equal labeled vertices.
Equal cells must have bit-identical filtration values and boundaries. The protected vertices are the separator retained for the next composition level.
Sourcepub fn protected_vertices(&self) -> &[usize]
pub fn protected_vertices(&self) -> &[usize]
Vertices whose induced subcomplex is fixed by every cancellation.
Sourcepub fn input_cells(&self) -> &[Vec<InterfaceCell>]
pub fn input_cells(&self) -> &[Vec<InterfaceCell>]
Input cells grouped by dimension.
Sourcepub fn cancellations(&self) -> &[InterfaceCancellation]
pub fn cancellations(&self) -> &[InterfaceCancellation]
Checked cancellation trace in execution order.
Sourcepub fn core_cells(&self) -> &[Vec<InterfaceCell>]
pub fn core_cells(&self) -> &[Vec<InterfaceCell>]
Retained interface core grouped by dimension.
Sourcepub fn graded_columns(&self) -> &[Vec<ChangeColumn>]
pub fn graded_columns(&self) -> &[Vec<ChangeColumn>]
Change-of-basis columns grouped by positive source dimension.
Sourcepub fn source_digest(&self) -> [u8; 32]
pub fn source_digest(&self) -> [u8; 32]
Content identifier of the pre-cancellation filtered chain complex.
Equal cores from different source complexes have different source
identifiers. Dynamic proof nodes use both this digest and Self::digest.
Sourcepub fn work(&self) -> RelativeInterfaceWork
pub fn work(&self) -> RelativeInterfaceWork
Exact cell and reduction work for this interface.
Source§impl RelativeInterfaceCertificate
impl RelativeInterfaceCertificate
Sourcepub fn verify(
&self,
limits: CertificateLimits,
) -> Result<Diagram, CertificateError>
pub fn verify( &self, limits: CertificateLimits, ) -> Result<Diagram, CertificateError>
Replay every cancellation and check the retained reduction.
Source§impl RelativeInterfaceCertificate
impl RelativeInterfaceCertificate
Sourcepub fn encode(
&self,
limits: CertificateLimits,
) -> Result<Vec<u8>, CertificateError>
pub fn encode( &self, limits: CertificateLimits, ) -> Result<Vec<u8>, CertificateError>
Encode the canonical HOLOSRI version 1 certificate.
Sourcepub fn decode(
bytes: &[u8],
limits: CertificateLimits,
) -> Result<Self, CertificateError>
pub fn decode( bytes: &[u8], limits: CertificateLimits, ) -> Result<Self, CertificateError>
Decode and verify one bounded HOLOSRI version 1 certificate.
Trait Implementations§
Source§impl Clone for RelativeInterfaceCertificate
impl Clone for RelativeInterfaceCertificate
Source§fn clone(&self) -> RelativeInterfaceCertificate
fn clone(&self) -> RelativeInterfaceCertificate
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for RelativeInterfaceCertificate
impl RefUnwindSafe for RelativeInterfaceCertificate
impl Send for RelativeInterfaceCertificate
impl Sync for RelativeInterfaceCertificate
impl Unpin for RelativeInterfaceCertificate
impl UnsafeUnpin for RelativeInterfaceCertificate
impl UnwindSafe for RelativeInterfaceCertificate
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