What does Beyond Distillation conclude, in numbers, about “The Pricing Engine: Constraint Solving, Invariants and Property Tests”?
Answer: In M1 the cost converts to 38.00, the lower bound is 70.91 and the four tiers run from 71.90 to 113.90. In M2 the cost converts to 167.20, the lower bound is 299.47, the ending rule is "whole tens minus one" and the tiers run from 309.00 to 489.00. In M3 the cost converts to 7.98, the lower bound is 17.58, the ending is ninety-nine cents and the tiers run from 17.99 to 28.99. The lowest-tier margins in the three markets are 0.3076, 0.3174 and 0.3607, each at or above its own floor; the floor in M3 is 0.35, while M1 and M2 keep 0.30.
Scope of the numbers: Parameters are illustrative and all calculations are generated by the book's programs. This is general business analysis, not investment, legal or medical advice, and the code it generates is teaching material deployed to no site.
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.30, 0.3076, 0.3174, 0.35, 0.3607, 113.90
| mkt cost floor p* tier1 tier2 tier3 list ok | |
| M1 | 38.00 70.91 71.90 78.90 95.90 113.90 True |
| M2 | 167.20 299.47 309.00 339.00 409.00 489.00 True |
| M3 | 7.98 17.58 17.99 19.99 23.99 28.99 True |
| lowest tier margin per market: | |
| M1 | 0.3076 (floor 0.30) |
| M2 | 0.3174 (floor 0.30) |
| M3 | 0.3607 (floor 0.35) |
| rule text shared by all markets | 4 rules; market rows: 3 |
Show the full program
# Chapter 2. p23: one specification compiled into three market organs.
# The same rule text (margin floor, ending rule, four-tier early-bird
# ladder with real seat counts, list price = first ending at or above
# 1.6 x the floor price) is compiled against three illustrative market
# profiles. Units M1, M2, M3 are made-up units, not currencies; exchange
# factors, fees and endings are illustrative. Exact fractions throughout.
import math
from fractions import Fraction as F
COST_U = F(38)
OFFS = [F(45, 100), F(30, 100), F(15, 100), F(0)]
MARKETS = [
# name, units per U, platform fee, pay fee, fixed, floor, step, end
("M1", F(1), F(12, 100), F(3, 100), F(1), F(30, 100), F(1),
F(90, 100)),
("M2", F(44, 10), F(10, 100), F(35, 1000), F(2), F(30, 100), F(10),
F(9)),
("M3", F(21, 100), F(15, 100), F(29, 1000), F(3, 10), F(35, 100),
F(1), F(99, 100)),
]
def up(x, step, end):
k = math.floor((x - end) / step)
p = k * step + end
while p < x:
p += step
return p
def down(x, step, end):
k = math.floor((x - end) / step)
p = k * step + end
while p > x:
p -= step
return p
def compile_market(m):
name, fx, plat, pay, fixed, floor, step, end = m
cost = COST_U * fx
pstar = (fixed + cost) / (1 - plat - pay - floor)
pmin = up(pstar, step, end)
lp = up(pstar * F(16, 10), step, end)
tiers = [max(down(lp * (1 - o), step, end), pmin) for o in OFFS]
marg = [(p * (1 - plat - pay) - fixed - cost) / p for p in tiers]
ok = all(x >= floor for x in marg) and \
all(a <= b for a, b in zip(tiers, tiers[1:]))
return cost, pstar, tiers, marg, ok
if __name__ == "__main__":
print("mkt cost floor p* tier1 tier2 tier3 list ok")
for m in MARKETS:
cost, pstar, tiers, marg, ok = compile_market(m)
print("{:<3} {:>7.2f} {:>9.2f} {} {}".format(
m[0], float(cost), float(pstar),
" ".join("{:>8.2f}".format(float(p)) for p in tiers), ok))
print("lowest tier margin per market:")
for m in MARKETS:
cost, pstar, tiers, marg, ok = compile_market(m)
print(" {} {:.4f} (floor {:.2f})".format(
m[0], float(min(marg)), float(m[5])))
n_rules = 4
print("rule text shared by all markets: {} rules; market rows: {}"
.format(n_rules, len(MARKETS)))Single source and citation
Fan, Y. (2026). Beyond Distillation: Executable Business-Organ Synthesis, Generative Code Crystallisation and Living-System Bootstrapping (Version 1.0.0), Chapter 2: The Pricing Engine: Constraint Solving, Invariants and Property Tests. 5D Library. DOI pending
DOI pending · monograph page goes live after publication · 5DL-B-378 · v1.0.0 · CC-BY-NC-ND-4.0
BibTeX
@book{fan2026378,
author = {Fan, Yafu},
title = {Beyond Distillation: Executable Business-Organ Synthesis, Generative Code Crystallisation and Living-System Bootstrapping},
year = {2026},
publisher = {5D Library},
edition = {1.0.0},
note = {DOI pending}
}Other chapter answers in this book
- Chapter 1 · The Ceiling of Distillation: Compression Keeps, Synthesis Generates
- Chapter 3 · The Front-End Statechart: Reachability, Deadlock and an Interface Gate on Every Path
- Chapter 4 · The Objection Tree: Coverage, Depth and the Order of Repairs
- Chapter 5 · The Live Probe: CUSUM, False-Alarm Run Lengths and Writing Back into the Mother Book
- Chapter 6 · Crystallinity and Bootstrapping: Mutation Testing, a Composite Index and the Limits of Self-Fingerprinting
- Chapter 7 · Classical Sources East and West: the Kaogongji's Four Conditions, the Laozi's Generative Sequence and Aristotle's Four Causes
- Chapter 8 · The Empirical Loop: Field Tools and Checker Specifications