MCPcopy Create free account
hub / github.com/ElementsProject/lightning / get_arc_flow

Function get_arc_flow

plugins/renepay/mcf.c:391–398  ·  view source on GitHub ↗

Helper function. * Given an arc of the network (not residual) give me the flow. */

Source from the content-addressed store, hash-verified

389/* Helper function.
390 * Given an arc of the network (not residual) give me the flow. */
391static s64 get_arc_flow(
392 const struct residual_network *network,
393 const struct arc arc)
394{
395 assert(!arc_is_dual(arc));
396 assert(arc_dual(arc).idx < tal_count(network->cap));
397 return network->cap[ arc_dual(arc).idx ];
398}
399
400/* Helper function.
401 * Given an arc idx, return the node from which this arc emanates in the residual network. */

Callers 1

get_flow_pathsFunction · 0.70

Calls 2

arc_is_dualFunction · 0.70
arc_dualFunction · 0.70

Tested by

no test coverage detected