Skip to content

Main content

Adjacency Zero Vs Absent Policy Tool

Resolve one adjacency entry using explicit presence and zero-weight conventions. A zero-weight edge is retained unless the caller explicitly treats zero as absent.

Loading tool…

Description

Return edgeExists when present is true and either zeroIsAbsent is false or weight is nonzero.

A graph has vertices, edges, and a convention for direction, loops, and repeated edges. A local condition such as an edge count or degree sum may be necessary for a structure without proving that the full graph has that structure.

Return edgeExists when present is true and either zeroIsAbsent is false or weight is nonzero.

When to use this tool

Use Adjacency Zero Vs Absent Policy when you need one graph-record component or necessary structural check.

How to use the tool and how it works

  1. Enter present, weight, zeroIsAbsent. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read edgeExists. Inspect edgeExists before interpreting the associated values.

Return edgeExists when present is true and either zeroIsAbsent is false or weight is nonzero.1

Input fieldMeaning and unitsAccepted input
presentPresentRequired. Boolean.
weightWeightRequired. Finite number.
zeroIsAbsentZero Is AbsentRequired. Boolean.
Output fieldInterpretationReturned shape
edgeExistsEdge ExistsRequired. Boolean.
json
{
  "input": {
    "present": true,
    "weight": 0,
    "zeroIsAbsent": false
  },
  "output": {
    "edgeExists": true
  }
}

Limitations and assumptions

  • The policy is supplied and signed weights are allowed; an absent entry never becomes an edge and no graph data is inspected.
  • 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

Validate the complete graph, including connectivity and edge conventions, before drawing a structural conclusion.

References

  1. Calculation and input contract: graph/adjacency-zero-vs-absent-policy — tool.io

Similar or alternative tools