Description
Return sqrt(first × second) through separate square roots for affinity and half the squared difference of those roots for squaredDistanceTerm.
Divergences and information densities compare probabilities on a common support. A weighted cell contribution and an unweighted logarithmic ratio differ, and zero-support cases require explicit limits.
Return sqrt(first × second) through separate square roots for affinity and half the squared difference of those roots for squaredDistanceTerm.
When to use this tool
Use Hellinger Affinity Symbol Term when you need one precisely defined information-comparison term.
How to use the tool and how it works
- Enter first, second. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read affinity, squaredDistanceTerm. Use the output convention below.
Return sqrt(first × second) through separate square roots for affinity and half the squared difference of those roots for squaredDistanceTerm.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| first | First value or boundary under the stated formula. | Required. Finite number; minimum 0; maximum 1. |
| second | Second value or boundary under the stated formula. | Required. Finite number; minimum 0; maximum 1. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| affinity | Affinity | Required. Finite number. |
| squaredDistanceTerm | Squared Distance Term | Required. Finite number. |
{
"input": {
"first": 0.25,
"second": 1
},
"output": {
"affinity": 0.5,
"squaredDistanceTerm": 0.125
}
} Limitations and assumptions
- Probabilities are each in [0, 1]; the terms must be aggregated over matching normalized supports for full-distribution measures.
- 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
Align and validate complete distributions before summing terms or interpreting a full divergence or dependence measure.
References
Similar or alternative tools
- Jensen Shannon One Bin Contribution
Validate first and second in [0, 1], use their mean as reference, and return half-weighted base-two relative-entropy terms, treating zero terms as zero.
- Bhattacharyya Log Affinity Term
Require affinity in (0, 1] and return -ln(affinity) as distance.