Description
Calculate a directed vertex's out-degree minus in-degree and report balance.
Graph records separate vertex/edge identities, direction, degree counts and weighted-entry conventions. A zero weight differs from no edge, and local degree balance or endpoint continuity does not establish a whole graph’s connectivity or a valid traversal. Parallel edges need an explicit occurrence convention.
Calculate a directed vertex's out-degree minus in-degree and report balance.
When to use this tool
Use Digraph In Out Degree Imbalance when checking the stated graph degree, walk, key or entry-presence convention.
How to use the tool and how it works
- Enter inDegree, outDegree. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read outMinusIn, balanced. Inspect balanced before interpreting the associated values.
Require nonnegative whole incoming/outgoing degrees. Return outDegree-inDegree and balanced when they are equal.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| inDegree | In Degree | Required. Safe integer; minimum 0. |
| outDegree | Out Degree | Required. Safe integer; minimum 0. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| outMinusIn | Out Minus In | Required. Safe integer. |
| balanced | Balanced | Required. Boolean. |
{
"input": {
"inDegree": 3,
"outDegree": 5
},
"output": {
"outMinusIn": 2,
"balanced": false
}
} Limitations and assumptions
- A local balanced vertex does not establish an Eulerian graph, global connectivity or a valid degree sequence.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Use the complete graph and appropriate structural/traversal algorithms for realizability, connectivity, Eulerian properties and globally unique edge handling.
References
Similar or alternative tools
- Tree Leaf Degree Deficit
Count degree-one vertices and sum the two-minus-degree contributions of a supplied degree list.
- Directed Loop In Out Degree Pair Tool
Calculate directed loop in out degree pair from explicit caller-supplied inputs.