makeB

makeB(baseMVA, bus, branch, alg)

makeB() - Builds the FDPF matrices, B prime and B double prime.

[BP, BPP] = MAKEB(MPC, ALG)
[BP, BPP] = MAKEB(BASEMVA, BUS, BRANCH, ALG)

Returns the two matrices B prime and B double prime used in the fast
decoupled power flow. Does appropriate conversions to p.u. ALG is either
'FDXB' or 'FDBX', the corresponding value of MPOPT.pf.alg option
specifying the power flow algorithm.
Bus numbers must be consecutive beginning at 1 (i.e. internal ordering).

Note: For backward compatibility, ALG can also take on a value of
2 or 3, corresponding to values of the old PF_ALG option. This usage
is deprecated and will be removed in a future version.

Example:
    [Bp, Bpp] = makeB(baseMVA, bus, branch, 'FDXB');

See also fdpf().