What does Knapsacks, Inspection Games and the Customs Reversal Point conclude, in numbers, about “The Border as an Inspection Game: Mixed Equilibria of Declaring and Risk Profiling”?
Answer: Chapter 3 treats border inspection as an inspection game; under illustrative parameters the break-even inspection rate for not declaring is 0.1852, and risk profiling makes the inspection rate jump from 0.0380 to 0.5035 between two and four crossings a quarter.
Scope of the numbers: Its parameters are illustrative and laws differ from place to place; all calculations are generated by its programs; the book is not individual legal or tax advice. Marked boxes separate published evidence, runnable Python calculations (19 programs), classical sources and the author's hypotheses.
Data table
The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 0.0380, 0.5035
| trips/qtr | P(comm|k) | inspect p(k) | trips/yr | P(no insp) | E insp |
|---|---|---|---|---|---|
| 0 | 0.0002 | 0.0201 | 0 | 1.0000 | 0.00 |
| 1 | 0.0026 | 0.0215 | 4 | 0.9168 | 0.09 |
| 2 | 0.0311 | 0.0380 | 8 | 0.7334 | 0.30 |
| 3 | 0.2861 | 0.1859 | 12 | 0.0847 | 2.23 |
| 4 | 0.8336 | 0.5035 | 16 | 0.0000 | 8.06 |
| 5 | 0.9843 | 0.5909 | 20 | 0.0000 | 11.82 |
| 6 | 0.9987 | 0.5993 | 24 | 0.0000 | 14.38 |
| 7 | 0.9999 | 0.5999 | 28 | 0.0000 | 16.80 |
| 8 | 1.0000 | 0.6000 | 32 | 0.0000 | 19.20 |
| a flat rate with the same prior would be 0.0316 for everyone | |||||
| at 6 trips a quarter, a flat rule leaves P(no insp) 0.4627 |
Show the full program
# Chapter 3. p32: risk profiling makes the inspection rate rise with trips.
# Among travellers on a route a share pi = 0.02 carry goods for resale.
# Ordinary travellers make Poisson(0.4) trips a quarter, commercial
# carriers Poisson(5). A risk engine that has seen k trips in a quarter
# holds the posterior P(commercial | k) by Bayes' rule and sets the
# inspection rate p(k) = 0.02 + 0.58 P(commercial | k). For a buyer who
# keeps k trips a quarter all year (4k trips), the table gives the chance
# of a year without any inspection and the expected inspections. The
# prior, the trip rates and the linear rule are illustrative.
import math
PI, LO, HI, BASE, SPAN = 0.02, 0.4, 5.0, 0.02, 0.58
def pois(k, lam):
return math.exp(-lam) * lam ** k / math.factorial(k)
print("trips/qtr P(comm|k) inspect p(k) trips/yr P(no insp) E insp")
for k in range(0, 9):
a = PI * pois(k, HI)
b = (1 - PI) * pois(k, LO)
post = a / (a + b)
p = BASE + SPAN * post
n = 4 * k
print("{:9d}{:11.4f}{:14.4f}{:10d}{:12.4f}{:8.2f}".format(
k, post, p, n, (1 - p) ** n, n * p))
flat = BASE + SPAN * PI
print("a flat rate with the same prior would be {:.4f} for everyone"
.format(flat))
print("at 6 trips a quarter, a flat rule leaves P(no insp) {:.4f}"
.format((1 - flat) ** 24))Single source and citation
Fan, Y. (2026). Two-Dimensional Volume-Weight Knapsacks for Cross-Border Buyers, Port Risk-Profiling Inspection Games and the Scale Reversal Point to Formal Customs Clearance (Version 1.0.0), Chapter 3: The Border as an Inspection Game: Mixed Equilibria of Declaring and Risk Profiling. 5D Library. DOI pending
DOI pending · monograph page goes live after publication · 5DL-B-174 · v1.0.0 · CC-BY-NC-ND-4.0
BibTeX
@book{fan2026174,
author = {Fan, Yafu},
title = {Two-Dimensional Volume-Weight Knapsacks for Cross-Border Buyers, Port Risk-Profiling Inspection Games and the Scale Reversal Point to Formal Customs Clearance},
year = {2026},
publisher = {5D Library},
edition = {1.0.0},
note = {DOI pending}
}Other chapter answers in this book
- Chapter 1 · One Suitcase as a Two-Dimensional Knapsack: Weight, Volume and the Price of Greedy Density
- Chapter 2 · The Larger of Actual and Volumetric Weight: Break-Even Density, Mixed Loads and Vacuum Packing
- Chapter 4 · The Nonlinearity of Hidden Penalties: Back Taxes, Confiscation, Tracing and Credit
- Chapter 5 · The Scale Reversal Point: Landed Cost of Carrying, Cross-Border E-Commerce and General Trade
- Chapter 6 · Tail Risk in a Year of Cash Flow and the Landed-Cost Calculator
- Chapter 7 · Classical Sources: the Salt Policy of the Guanzi "Hai Wang" and Smith's Smuggler
- Chapter 8 · Practice and Falsification: Checklists for Buyers and Owners, the Calculator and a Pre-Registered Protocol