Module 3: Names, games and letter valuesLesson 7 of 124 min read
The mathematics of love calculators
Type two names, press a button and a percentage appears. It feels like the computer has looked into your future, but what really happens is a short, neat piece of mathematics. Seeing the steps takes nothing away from the fun. It just shows why the game is fair and repeatable: the same two names always give the same score, whichever order you type them in.
Step 1: clean the names
Computers are fussy about text, so the first job is to make names comparable. Our calculator turns everything into lower-case Latin letters, removes accents so José becomes jose, and drops spaces, hyphens and digits. Without this step, Anna and anna would count as two different people.
Step 2: put the pair in order
Love should not depend on who types first. So the two cleaned names are sorted alphabetically and joined with a separator. Romeo and Juliet and Juliet and Romeo both become the same string, juliet|romeo, before anything is calculated.
Step 3: a hash function
That string is fed into a hash function. A hash function takes text of any length and returns a fixed-size number, and the key property is that the same input always produces the same output. We use FNV-1a, a fast, well-known hash designed by Glenn Fowler, Landon Curt Noll and Kiem-Phong Vo.
FNV-1a starts from a fixed number, then for each character mixes it in with a bitwise operation and multiplies by a large prime. Tiny changes in the input, one extra letter, produce a completely different result. FNV is not meant for security, only for speed and spread, which is what a game needs.
It also means a near miss tells you nothing. Jon and Jonny are close for a person but completely different for a hash, so their scores with the same partner can be far apart. There is no hidden pattern to decode.
Step 4: turn it into a percentage
The hash is a big number, often in the billions. To get a score from 0 to 100 the calculator keeps the remainder after dividing by 101, a step called modulo. Every score in that range is reachable, and none is favoured on purpose.
Worked example: Romeo and Juliet
Clean: romeo, juliet. Sort and join: juliet|romeo. FNV-1a hash of that text, then the remainder after dividing by 101: 38. Swap the order of the names and the result is still 38, because step 2 produced the same text.
Why the score still feels meaningful
Psychologists have long known that people read personal meaning into general statements, an effect first shown in a classroom by Bertram Forer in 1948. A number next to two names invites the same reaction: a high score feels like confirmation, a low one like a puzzle to explain. Knowing that helps you enjoy the result as an icebreaker. It is a game you can share, laugh about and play again with friends, not a measure of any real relationship.
Try two names, then swap their order and watch the score stay the same.
Try the love calculatorQuick check
Three questions. Pick an answer to see why.
Are name-based love calculators scientifically predictive?
Show the answer
Answer: No, they apply a fixed formula to letters for entertainment The score comes from a hash of the letters, which knows nothing about the people.
Why do the same two names always produce the same score?
Show the answer
Answer: The calculation is deterministic: same input, same output A hash function always returns the same number for the same text.
Why are the two names sorted before the hash?
Show the answer
Answer: So the order you type them in does not change the result Sorting turns both orders into the same text before hashing.
An honest note
All numerology, zodiac and gematria materials are provided for entertainment, cultural and historical context, and personal reflection only.
Sources
Last checked October 25, 2026