Skip to main content

Module incidence

Module incidence 

Source
Expand description

DC network primitives: the signed incidence matrix A, branch susceptances b, the flow map B Aᵀ, and the phase shift injection.

Edge orientation is fixed to MATPOWER’s from→to: column e of A has +1 at the from bus (tail) and −1 at the to bus (head). Columns run over in-service branches in case.branches order; branch_of_col maps a column back to its source branch index.

Structs§

IncidenceParts
The incidence factorization of a case under one DC convention.

Enums§

DcConvention
DC susceptance convention for b_e and the Laplacian.

Functions§

build_flow_map
The flow map B Aᵀ, shape m × n: f = (B Aᵀ) θ.
build_incidence
Build A, b, the phase shift injection, and the column→branch map.
diagonal
Sparse diagonal matrix from values (square, len × len).
susceptance_diag
B = diag(b), shape m × m.