METHODOLOGY

How we check our calculations

Every Varyvia calculator gives an answer you can reproduce by hand. This page explains how the formulas are written and tested, where the rules behind them come from, and what to do if you think a result is wrong.

1. Each formula is a small, separate function

The arithmetic for every calculator lives in its own function, separate from the page design. A loan payment, a VAT breakdown or a working-day count is calculated by the same code wherever it appears, in English or Arabic, on the full page or in an embedded calculator. That makes each formula easy to read, review and test on its own.

2. Automated tests run before every release

More than 700 automated tests run each time the site is changed, and a release is blocked if any of them fails. They check results against hand-worked cases, edge cases such as leap years, overnight shifts and zero values, and rejection of impossible inputs such as negative quantities or a percentage above 100 where that makes no sense. Browser tests then load the live pages in both languages and use the calculators as a visitor would.

3. Worked examples are checked against the code

Each calculator page includes a guide with worked examples. Those figures are not typed in by hand and forgotten: a dedicated test recalculates every example with the calculator's own function and confirms that the article quotes the same number. If a formula changes, the test fails until the explanation is corrected. Where the English and Arabic pages start with different default values, each guide uses its own page's defaults so you can reproduce the example exactly.

4. Local rules come from official sources

Some calculators touch rules set by authorities, such as Saudi VAT, GOSI contributions, financing limits or annual leave. For these we read the official source and link to it from the guide, for example:

The calculators do not apply these rules automatically unless the page says so. You enter the rate or allowance that applies to you, and the guide explains the official figure and where to confirm it.

5. Clear inputs and honest limits

Inputs accept numbers only, with decimals where they make sense and whole numbers where a fraction would be meaningless, such as the number of people. Invalid entries show a message instead of a misleading result. Each guide ends with what the calculation does not cover, such as fees, taxes, local policies or medical judgement, so you know when to check further.

6. How results are displayed

Results are rounded for display, usually to two decimal places, while the full value is used in the calculation itself. Both language versions show Western digits so figures can be copied into spreadsheets and forms without conversion. Calculations run in your browser, and Varyvia does not store the values you enter.

7. Review dates

Calculator guides and topical guides show the date they were last reviewed. We review a page when its formula, its examples or the rules behind it change, and we update the date only when the content has actually been checked.

8. Reporting an error

If a result looks wrong, an explanation is unclear or a rule has changed, email support@varyvia.com with the page address, the values you entered and the result you expected. We recalculate every report by hand and against the code, fix the page if needed and reply with what we found.

Read more about Varyvia, or browse the guides.