AHP Decision Maker
Operator: Abdulla Al Fahad. How tools are built and checked
Choosing between three suppliers on price, quality, delivery and risk is hard because the criteria are not on one scale and nobody can say how much more quality matters than price. The analytic hierarchy process drops the demand for exact weights. It asks only for small judgments, one pair at a time: is quality more important than price, and by how much on a nine-step scale?
From those judgments it derives a weight for each criterion, a score for each alternative under each criterion, and an overall ranking. It also measures how self-contradictory the judgments were, which is the part a spreadsheet of weights cannot do.
It handles a goal, up to ten criteria each with up to ten sub-criteria, and up to ten alternatives, for one person or a group.
Key features
- Pairwise sliders on Saaty's scale, from equal to extreme in either direction, with a plain-language reading under each slider and an optional matrix view
- Priorities by the principal eigenvector (power iteration) or by the row geometric mean, with the largest eigenvalue, consistency index and consistency ratio shown for every matrix
- When a ratio is above 0.10, the single judgment whose change would lower it the most, with the value to move towards and the ratio that would result
- Group mode with up to eight participants, combined by the geometric mean of each judgment, with every participant's own consistency ratio listed
How the weights, the consistency ratio and the sensitivity check are worked out
Each comparison writes one entry of a reciprocal matrix: if quality is judged 3 times as important as price, the matrix holds 3 above the diagonal and 1/3 below. The weights are the principal eigenvector of that matrix, found by repeating w = Aw and rescaling until the change falls below 1e-14. For a perfectly consistent matrix this equals the geometric-mean result; for an inconsistent one the two differ slightly, which is why both are offered.
The consistency index is (lambda max - n) / (n - 1), and the consistency ratio divides it by the random index for matrices of that size. The page uses Saaty's table, 0.58 for 3 items, 0.90 for 4, 1.12 for 5, 1.24 for 6, 1.32 for 7, 1.41 for 8, 1.45 for 9 and 1.49 for 10, from Saaty, The Analytic Hierarchy Process (McGraw-Hill, 1980). Later tables use other random indices (about 0.52 for three items and 1.35 for seven, for example), so a ratio from another tool can differ from this one by up to roughly a tenth of its value. Matrices of two items are always consistent.
How it works
Local priorities are computed for every matrix. A sub-criterion's weight in the goal is its parent's weight times its own local weight. An alternative's overall score is the sum, over every criterion or sub-criterion at the bottom of the tree, of that weight times the alternative's local priority under it. The sensitivity chart moves one top-level criterion's weight from 0 to 1 while keeping the others in proportion; because scores are straight lines in that weight, the point where two lines cross is computed exactly.
Typical uses
- A county IT office compares four document-management products on cost, security, integration and support, with five staff each entering their own judgments. The group matrix gets its own ratio, each participant gets theirs, and a participant whose ratio is above 0.10 sees the judgment to revisit.
- A site-selection committee for a clinic compares five locations on travel time, rent and staffing. Dragging the travel-time weight in the sensitivity panel shows the weight at which the top location changes, which tells the committee how firmly the choice rests on that one criterion.
- A student weighs three thesis topics on interest, data availability and supervisor fit, and keeps the exported PDF as the record of how the choice was made.
Building one
- Type the goal, the alternatives (one per line), and the criteria, adding comma-separated sub-criteria where a criterion needs splitting.
- Work through the comparison cards: criteria first, then any sub-criteria, then the alternatives under each bottom-level criterion.
- Read the consistency ratio on each card and fix any that the page flags, starting with the judgment it names.
- Read the ranking, then use the sensitivity panel to see how far a criterion's weight can move before the top choice changes.
Example
The family-car example
Criteria cost, safety, style, capacity; cost split into purchase price, fuel, maintenance and resale; capacity into cargo and passenger. Cost over safety 3, cost over style 7, cost over capacity 3, safety over style 9, safety equal to capacity, capacity over style 7. Three illustrative cars.Weights and ranking
Criteria weights: cost 0.510, safety 0.234, style 0.041, capacity 0.215, with a consistency ratio of 0.074 (below 0.10). Weight in the goal: purchase price 0.249, safety 0.234, passenger capacity 0.179, fuel 0.128, resale 0.082, maintenance 0.051, style 0.041, cargo 0.036. With the example's three cars: Odyssey 0.409, Accord 0.315, Pilot 0.276; the top choice changes from Accord to Odyssey once safety's weight exceeds 0.046.Tips for best results
- Compare the two items you feel most strongly about first, and anchor the others to that judgment. The most extreme comparisons are the ones that most often break consistency.
- If the ratio stays above 0.10 after fixing the suggested judgment, try the geometric-mean option; for large matrices the two methods can rank close alternatives differently, and you want to know that.
- Use group mode with real individuals, not one person playing several roles. Aggregating one person's judgments with themselves changes nothing.
- Name sub-criteria only where a criterion has distinct parts that people weigh differently; a sub-level adds comparisons without adding insight otherwise.
Things to check before you rely on it
AHP results depend entirely on the judgments entered. A neat decimal weight is the arithmetic of the sliders, not a measurement of the world.
Adding or removing an alternative can reorder the others, which is known as rank reversal. This page applies the standard method and does not hide it.
Common errors and how to fix them
- "Alternative names must be different."
- Two lines of the alternatives box read the same once case and spacing are ignored. Rename one so each can be told apart in the results.
- "Add at least two alternatives, one per line."
- A ranking needs something to rank. Type two or more alternatives, each on its own line.
- "At most 10 alternatives are supported."
- The random index table used for the consistency check stops at ten items. Group similar alternatives, or run a first round to cut the list.
- "Every criterion needs a name."
- A criterion row is blank. Fill it in or remove the row.
Best practices
- Compare the criteria before you look at how the alternatives score, so that knowing which option would win does not bend the weights.
- Download the PDF with the consistency ratios, so a reader can see which judgments were repaired and by how much.
Checked against published numbers
A 7 by 7 matrix comparing the consumption of coffee, wine, tea, beer, soda, milk and water, from Saaty's classic example, gives the priority vector 0.177, 0.019, 0.042, 0.116, 0.190, 0.129 and 0.327 here, which are the published values to three decimals. Saaty's printed matrix is not quite reciprocal (it gives tea over wine as 2 but wine over tea as 1/3); the published vector results when both entries are reciprocals of 3, which is what the sliders enter.
The car-buying worked example on Wikipedia gives purchase price 0.246, safety 0.237, passenger capacity 0.181, fuel 0.127, resale 0.081, maintenance 0.050, style 0.042 and cargo 0.036 for the same judgments; this page gives 0.249, 0.234, 0.179, 0.128, 0.082, 0.051, 0.041 and 0.036. They agree within 0.003 but not to three decimals; Wikipedia does not state its rounding. Its alternative-level judgments are shown only as images, so only the criteria and sub-criteria were compared.
Frequently asked questions
What does a consistency ratio of 0.10 mean?
It is Saaty's rule of thumb. If you judge A twice B and B twice C, consistency suggests A about four times C; the ratio measures how far your answers stray from that kind of transitivity. Above 0.10 the judgments are contradictory enough to be worth a second look, though it is a guideline, not a test.
Why does a matrix of two items show no ratio?
A single judgment between two items cannot contradict itself, so the ratio is 0. The ratio becomes meaningful from three items upward.
How are several participants combined?
Each judgment is combined across participants by the geometric mean, entry by entry, and the group matrix is solved like any other. Averaging with the geometric mean keeps the group matrix reciprocal, which an arithmetic mean would not.
Which method should I choose, eigenvector or geometric mean?
Start with the principal eigenvector, which is the standard method. The geometric mean is a close alternative that is easier to explain; when the two disagree on the order of close alternatives, the judgments are not consistent enough to separate them.
Why did adding a fourth option change the order of the first three?
That is rank reversal. Under each criterion the scores of the alternatives are normalised to add up to 1, so a new alternative takes shares from the others in different proportions under different criteria, and two older options can swap places even though the new one beat neither. This page uses that standard (distributive) synthesis and offers no variant that avoids it, so compare the ranking with and without the new option to see whether the order holds.