How we build our calculators

Every number on this site comes from a formula you can read on the calculator's page. This is how those formulas are written, checked and kept correct.

1. The formula comes first

Each calculator starts from the standard formula for its question: the amortization formula for a loan payment, the Henderson-Hasselbalch equation for a buffer, Naegele's rule (280 days from the last period) for a due date. The page's "How it works" section shows that formula with each symbol explained, so you can redo the calculation yourself.

Where experts use more than one method, the calculator says which one it uses, and often shows several side by side. The body surface area calculator, for example, gives the Mosteller, DuBois and Haycock results together.

2. Published sources for health and money

Calculators that follow a specific published method or guideline list it under "Sources": the journal paper for an equation, or the official page for a threshold, such as the American Heart Association blood pressure categories or the FDA's 400 mg caffeine guidance. A source is only added after checking that the calculator's code does exactly what the source describes.

3. Automatic tests on every change

Before any change goes live, an automated test suite runs every calculator:

  • Over 900 test cases check calculators against answers worked out by hand or taken from the source.
  • Snapshot tests record the exact output of every older calculator, so any change to a result is caught and reviewed.
  • Each worked example on a page is recalculated during the build, so the examples always match the calculator.
  • Pages are opened in a real browser on desktop and phone sizes, to check that each calculator, chart and unit switch works.

4. Inputs that make sense

Calculators refuse inputs that can't be right, like more saves than shots on goal or a February 30, and say why rather than showing a wrong answer. Units can be switched between metric and imperial, and the limits on each field switch with them.

5. Charts drawn from the same formula

The charts, reference tables and pictures on each page are computed with the calculator's own formula, not drawn separately. A reference table of monthly payments by interest rate, for example, is the calculator run at each of those rates.

6. Corrections

If you think a result is wrong, email info@elixirblend.com with the calculator, your inputs and what you expected. Confirmed errors are fixed, a test is added so the same error can't come back, and the fix is listed on the updates page.

The calculators give estimates for planning and learning, not medical, financial, legal or tax advice. Check important decisions with a qualified professional.