The expressions above read these as $const. They are the figures the annual refresh replaces, so they live as data rather than being written into the formulas — which is what makes a year-on-year change a one-line diff instead of an edit to arithmetic.
Constant
Value
standardRate
0.25
foodRate
0.15
servicesRate
0.12
marineRate
0.1111
registrationThreshold
50000
registrationThresholdCharity
140000
Test vectors (6)
Every case is executed against this model on each build, by the Java engine and independently by a JavaScript one. A mismatch of a single cent fails the build, so the page cannot ship advertising a figure the model no longer produces.
Case 1 — N1 1,000 kr net at 25%
given amount
1000
given direction
add
given category
standard
given reverseCharge
no
given charity
no
given turnover12Months
0
expect vatAmount
250
expect grossAmount
1250
expect netAmount
1000
Case 2 — N2 1,250 kr gross back to net
given amount
1250
given direction
remove
given category
standard
given reverseCharge
no
given charity
no
given turnover12Months
0
expect netAmount
1000
expect vatAmount
250
Case 3 — N3 food at 15%
given amount
1000
given direction
add
given category
food
given reverseCharge
no
given charity
no
given turnover12Months
0
expect vatAmount
150
expect grossAmount
1150
Case 4 — N4 a hotel room at 12% — not the 8% the 2014 resolution stated
given amount
1000
given direction
add
given category
services12
given reverseCharge
no
given charity
no
given turnover12Months
0
expect rate
0.12
expect vatAmount
120
Case 5 — N5 exactly 50,000 kr does not yet require registration
given amount
0
given direction
add
given category
standard
given reverseCharge
no
given charity
no
given turnover12Months
50000
expect mustRegister
false
Case 6 — N6 a charity at 100,000 kr is still under its 140,000 kr limit
The whole model as JSON — inputs, outputs, formulas, vectors and sources in one re-runnable document.
This model is published under CC BY 4.0: use it, adapt it, build on it, with attribution. The licence covers the model — the expression of each rule and the arrangement of the catalog. The rates and thresholds are law, and nobody licenses those; the sources above are where they come from.