[−][src]Trait storage_proofs::zigzag_graph::ZigZag
Associated Types
type BaseHasher: Hasher
type BaseGraph: Graph<Self::BaseHasher>
Required methods
fn zigzag(&self) -> Self
zigzag returns a new graph with expansion component inverted and a distinct base DRG graph -- with the direction of drg connections reversed. (i.e. from high-to-low nodes). The name is 'weird', but so is the operation -- hence the choice.
fn base_graph(&self) -> Self::BaseGraph
Constructs a new graph.
fn expansion_degree(&self) -> usize
fn reversed(&self) -> bool
fn expanded_parents(&self, node: usize) -> Vec<usize>
fn real_index(&self, i: usize) -> usize
fn new_zigzag(
nodes: usize,
base_degree: usize,
expansion_degree: usize,
seed: [u32; 7]
) -> Self
nodes: usize,
base_degree: usize,
expansion_degree: usize,
seed: [u32; 7]
) -> Self
Implementors
impl<'a, H, G> ZigZag for ZigZagGraph<H, G> where
H: Hasher,
G: Graph<H>,
[src]
H: Hasher,
G: Graph<H>,
type BaseHasher = H
type BaseGraph = G
fn new_zigzag(
nodes: usize,
base_degree: usize,
expansion_degree: usize,
seed: [u32; 7]
) -> Self
[src]
nodes: usize,
base_degree: usize,
expansion_degree: usize,
seed: [u32; 7]
) -> Self
fn zigzag(&self) -> Self
[src]
To zigzag a graph, we just toggle its reversed field. All the real work happens when we calculate node parents on-demand.