Method and assumptions
1. Declare the scale
Use nonnegative ratio-scale observations with a meaningful zero. Keep the same unit within a column. Benefit/cost labels are recorded for interpretation, but this variant neither reverses cost columns nor applies min–max scaling. A different preprocessing rule defines a different weighting method.
2. Form column proportions
Divide each observation by that column’s sum. The proportions add to one for every positive-sum column. A zero observation contributes no logarithmic term, using the limiting convention 0 ln 0 = 0.
3. Measure uniformity
Entropy E is highest at uniform proportions. The contrast d = 1 − E therefore vanishes for a positive constant column. Concentration in fewer alternatives produces more contrast; this says nothing by itself about desirability or risk.
4. Normalize contrasts
Divide each d by the total contrast across criteria. A zero-sum column has undefined proportions and entropy; our explicit exclusion convention assigns d = 0. If every contrast is zero, the weights remain undefined. The software does not silently create equal weights.
pᵢⱼ = xᵢⱼ / Σᵢ xᵢⱼ
Eⱼ = −Σᵢ pᵢⱼ ln(pᵢⱼ) / ln(m)
dⱼ = 1 − Eⱼ; wⱼ = dⱼ / Σⱼ dⱼ
| Symbol | Definition |
|---|---|
| i, m | Alternative index and count; 2 ≤ m ≤ 8 |
| j, n | Criterion index and count; 2 ≤ n ≤ 6 |
| xᵢⱼ | Performance of option i on criterion j, in its declared column unit |
| wⱼ | Dimensionless nonnegative criterion weight; sum is 1 when defined |
| pᵢⱼ | Dimensionless share of the positive column sum; undefined for an all-zero column |
| Eⱼ, dⱼ | Normalized entropy and contrast, both dimensionless |
| ln | Natural logarithm; division by ln(m) removes the log-base choice |
Worked maritime example
These four service-vessel options and all quantities are original, synthetic teaching data. They are not measured vessel performance, a procurement recommendation or safety approval.
Objective: Compare synthetic port service vessel options.
Data-driven weights describe contrast within the chosen dataset. They are not universally objective priorities, operational importance, probabilities or evidence of correctness. Criteria, units, origins and alternatives remain modeling choices.
| Criterion | Unit | Preference direction |
|---|---|---|
| Daily energy | kWh/day | Cost: minimize |
| Duty capacity | jobs/day | Benefit: maximize |
| Maintenance time | h/month | Cost: minimize |
| Alternative | Daily energy | Duty capacity | Maintenance time |
|---|---|---|---|
| Vessel A | 100 | 6 | 12 |
| Vessel B | 120 | 9 | 10 |
| Vessel C | 80 | 5 | 18 |
| Vessel D | 110 | 8 | 8 |
| Alternative | Daily energy | Duty capacity | Maintenance time |
|---|---|---|---|
| Vessel A | 0.24390244 | 0.21428571 | 0.25 |
| Vessel B | 0.29268293 | 0.32142857 | 0.20833333 |
| Vessel C | 0.19512195 | 0.17857143 | 0.375 |
| Vessel D | 0.26829268 | 0.28571429 | 0.16666667 |
| Alternative | Daily energy | Duty capacity | Maintenance time |
|---|---|---|---|
| Vessel A | 0.34414316 | 0.33009537 | 0.34657359 |
| Vessel B | 0.35960939 | 0.36481498 | 0.32679498 |
| Vessel C | 0.31885474 | 0.30763689 | 0.36781097 |
| Vessel D | 0.35298646 | 0.35793228 | 0.29862658 |
| Criterion | Column sum | Entropy E | Divergence d | Excluded | Weight w |
|---|---|---|---|---|---|
| Daily energy | 410 | 0.99228114 | 0.0077188606 | No | 0.1289173 |
| Duty capacity | 28 | 0.98137852 | 0.018621476 | No | 0.31100839 |
| Maintenance time | 48 | 0.96646582 | 0.033534177 | No | 0.56007431 |
Weights defined: Yes. Total information = 0.059874514.
Substitute the values
p₁₁ = 100 / (100 + 120 + 80 + 110) = 0.24390244
E₁ = [0.34414316 + 0.35960939 + 0.31885474 + 0.35298646] / ln(4) = 0.99228114
d₁ = 1 − E₁ = 0.0077188606
w₁ = 0.0077188606 / 0.059874514 = 0.1289173
Sensitivity checks
Remove each alternative in turn, rebuild preprocessing and recompute weights. A change shows dependence on the option set. These are descriptive checks, not uncertainty intervals. With only two alternatives the leave-one-out check is omitted because the method requires at least two.
| Alternative left out | Weights defined | w: Daily energy | w: Duty capacity | w: Maintenance time |
|---|---|---|---|---|
| Vessel A | Yes | 0.13432082 | 0.27185289 | 0.59382629 |
| Vessel B | Yes | 0.10592765 | 0.2378985 | 0.65617385 |
| Vessel C | Yes | 0.092622898 | 0.45666765 | 0.45070945 |
| Vessel D | Yes | 0.17556362 | 0.41221819 | 0.41221819 |
Tables display 8 significant digits. Calculations use unrounded binary64 values; CSV preserves round-trip numeric precision. “Undefined” is never replaced by an invented score.
Interpretation and limits
- A positive multiplicative unit conversion leaves proportions unchanged; adding an offset generally changes them. Celsius-like arbitrary origins are unsuitable for this raw ratio-scale variant. Negative inputs are rejected rather than silently shifted.
- Duplicating a criterion duplicates its influence in the final normalization. Entropy does not model cross-criterion correlation. Outliers, measurement noise and which alternatives are included can change the weights.
- For numerical stability the engine evaluates the mathematically equivalent KL divergence from uniform, d = Σ[p ln(mp) − p + 1/m]/ln(m), using a small-difference series and centered original-value residuals near uniformity. Numerically resolved differences can still be far smaller than measurement precision; normalized weights then magnify negligible data contrasts. Entropy is independently accumulated with stable log1p probability logs, preserving tiny positive entropy near complete concentration. A displayed E rounded to 1 can coexist with a small positive unrounded d.
- An excluded safety-critical criterion is not unimportant in practice. Apply hard constraints and justified priorities separately; never use these weights alone to approve a vessel or operation.
Check your understanding: multiplying the entire energy column by 1,000 changes its unit from kWh to Wh. Do the entropy weights change?
No. The common positive factor cancels in the column proportions. Adding 1,000 to every energy entry would generally change them.
Primary methodology sources
Roszkowska & Wachowicz (2024), Entropy 26, 365, §2.1, equations (3), (4), (7).
Shannon (1948), A Mathematical Theory of Communication. Information-theory foundation; not presented as the source of the later criterion-weighting algorithm.
The declared zero, tie and numerical edge-case policies are implementation choices of this tool. entropy v1.0.0.