Description
equivalent is true when every positive-weight coordinate matches exactly; differingIgnoredAxes lists zero-weight indexes whose values differ.
Weighted coordinate distances depend on whether weights multiply absolute differences or squared differences. Zero weights can make different vectors equivalent, and derivatives at a zero distance or absolute-value corner need explicit treatment.
equivalent is true when every positive-weight coordinate matches exactly; differingIgnoredAxes lists zero-weight indexes whose values differ.
When to use this tool
Use Weighted Distance Zeroaxis Equivalence Flag when checking one weighted-axis contribution, support rule or derivative.
How to use the tool and how it works
- Enter first, second, weights. Keep parallel arrays aligned. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read equivalent, differingIgnoredAxes. Inspect equivalent before interpreting the associated values.
Require equally long first, second and nonnegative weights arrays. equivalent is true when every positive-weight coordinate matches exactly; differingIgnoredAxes lists zero-weight indexes whose values differ.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| first | First | Required. Array of finite number; maximum items 256. |
| second | Second | Required. Array of finite number; maximum items 256. |
| weights | Position-aligned nonnegative weights under the specified model convention. | Required. Array of finite number; maximum items 256. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| equivalent | Exact agreement on positive-weight axes only; zero-weight differences are ignored. | Required. Boolean. |
| differingIgnoredAxes | Differing Ignored Axes | Required. Array of safe integer; maximum items 256. |
{
"input": {
"first": [
1,
2
],
"second": [
1,
5
],
"weights": [
1,
0
]
},
"output": {
"equivalent": true,
"differingIgnoredAxes": [
1
]
}
} Limitations and assumptions
- Zero weights create equivalence classes, so this is generally a pseudometric convention rather than identity of vectors. No tolerance, missing-value policy or distance magnitude is computed.
- 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 a complete distance implementation with an explicit weighting and missing-coordinate convention for vector comparison and optimization.
References
Similar or alternative tools
- Weighted Distance Zero Support
positiveSupport counts comparable positive-weight axes; totalWeight sums comparable weights; defined is true when at least one such weight is positive.
- Weighted Absolute Gap Term
contribution = abs(first-second)*weight.