Skip to content

@graphty/graphty-element / format / DerivedGraph

Interface: DerivedGraph ​

Defined in: graph-format/dist/src/types/snapshot.d.ts:274

A new snapshot produced from an existing one by a structural mapping the caller specifies, plus index maps back to the source (design section 7.3). Never cached by the format. Every map is null when the corresponding index space is unchanged; edgeRemap maps every merged edge to its survivor so a per-edge result of the derived graph writes back onto source edges with out[e] = vec[edgeRemap[e]], and edgeRemap[edgeOrigin[d]] === d for every derived edge d.

Properties ​

blockSizes ​

readonly blockSizes: U32 | null

Defined in: graph-format/dist/src/types/snapshot.d.ts:295

contract only: source nodes per new node; null otherwise.


edgeOrigin ​

readonly edgeOrigin: U32 | null

Defined in: graph-format/dist/src/types/snapshot.d.ts:286

New edge index -> source edge index (a merged edge: its SURVIVOR's source index, never INVALID_INDEX); null when unchanged.


edgeRemap ​

readonly edgeRemap: U32 | null

Defined in: graph-format/dist/src/types/snapshot.d.ts:293

Source edge index -> new index; a merged / collapsed edge maps to its SURVIVOR, a dropped edge to INVALID_INDEX; null when unchanged.


nodeOrigin ​

readonly nodeOrigin: U32 | null

Defined in: graph-format/dist/src/types/snapshot.d.ts:281

New node index -> source node index (contract: the LOWEST source index of the block); null when the node space is unchanged.


nodeRemap ​

readonly nodeRemap: U32 | null

Defined in: graph-format/dist/src/types/snapshot.d.ts:288

Source node index -> new index (contract: the block) or INVALID_INDEX (dropped); null when unchanged.


report ​

readonly report: object

Defined in: graph-format/dist/src/types/snapshot.d.ts:297

How many source edges were dropped and how many merged.

droppedEdges ​

readonly droppedEdges: number

mergedEdges ​

readonly mergedEdges: number


snapshot ​

readonly snapshot: GraphSnapshot

Defined in: graph-format/dist/src/types/snapshot.d.ts:276

The derived snapshot; this for the identity cases (transpose / toUndirected of an undirected snapshot).