Description
Sum replacementWeights, subtract removedWeight for delta, and add delta to the supplied path cost.
A walk is an ordered sequence of visited vertices or edges, while a path normally adds structural restrictions. Sequence manipulation and endpoint checks alone do not verify that every required graph edge exists.
Sum replacementWeights, subtract removedWeight for delta, and add delta to the supplied path cost.
When to use this tool
Use Path Cost Single Edge Replacement Term when you need a sequence transformation, endpoint comparison, or path-related local calculation.
How to use the tool and how it works
- Enter cost, removedWeight, replacementWeights. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read cost, delta. Use the output convention below.
Sum replacementWeights, subtract removedWeight for delta, and add delta to the supplied path cost.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| cost | Cost | Required. Finite number. |
| removedWeight | Removed Weight | Required. Finite number. |
| replacementWeights | Replacement Weights | Required. Array of finite number; maximum items 256. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| cost | Cost | Required. Finite number. |
| delta | Sum of replacement weights minus the removed edge weight; may be negative. | Required. Finite number. |
{
"input": {
"cost": 10,
"removedWeight": 4,
"replacementWeights": [
2,
3
]
},
"output": {
"cost": 11,
"delta": 1
}
} Limitations and assumptions
- All costs share one unit and signed weights are accepted; this does not verify path membership, search for routes, detect negative cycles, or prove that a shortest path remains optimal.
- 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 each consecutive edge against the graph and check the required path or cycle properties. Use a dedicated traversal or shortest-path algorithm when reachability or optimality is the real question.
References
Similar or alternative tools
- Graph Walk Vertex Occurrence Position
Collect every zero-based position where a walk entry equals vertex and return positions and their count.
- Graph Path Reversal Oriented Edge Sign
Reverse the list order and negate each sign.