The science
Population. Growth is logistic, dP/dt = r g P (1 − P/K) + m (1 − P/K), with K the housing capacity (6 per house, 24 in the town hall, 30 in a castle), r = 0.012 per hour, g a happiness/sanitation factor and m = 0.25 settlers per hour; over capacity people leave, with no food the realm shrinks. The closed form is P(t) = K / (1 + ((K − P0)/P0) e−rt).
Harvest. Farm output follows the year: f(d) = 0.8 + 0.35 cos(2π(d − 200)/360), peaking mid-July and lowest in January. Unmilled grain loses 20 % to spoilage; windmills mill it. Fishing boats at a port add food that dips a little when the water is icy.
Wind. A windmill converts P = ½ ρ A v3 Cp with ρ = 1.225 kg/m³, blade radius 9 m, Cp = 0.30 (a real sail mill is below the Betz limit 16/27 = 0.593). Milling capacity is scaled to the power at the 6 m/s design wind.
Harbour (Archimedes). A cog floats when its weight equals the weight of displaced water: m = ρw L B Cb d. With L = 24 m, B = 7 m, Cb = 0.55 the hull gains 92.4 t per metre of draught. The laden draught may not exceed the water depth minus a 0.6 m keel margin, so cargo = 92.4 t/m × (D − 0.6) − 60 t of empty ship: 69 t at 2.0 m, 143 t after dredging to 2.8 m. Income = ships × cargo × price / voyage time × ice factor (the river part-freezes in winter, up to −45 %).
Garrison and defence. Defence = (walls × 1.2 + towers × 5 + Σ units × strength × (0.8 + 0.4 · drill) + 40 per castle) × masonry bonus. Drill rises 0.9 per day with barracks space. Every few weeks a raid check compares defence with a rising threat; treaties of peace cut the threat by 22 % each. No fighting is shown; this is a planning rating, not a battle simulation.
Diplomacy. Each neighbour keeps a relation 0–100 that relaxes toward a baseline, dr/dt = k (b − r), k = 0.0016 per hour, so r(t) = b + (r0 − b) e−kt. Gifts, trade treaties and peace pacts raise the baseline; below 30 a trade treaty lapses, below 40 a peace pact breaks. Random envoys and border quarrels move relations a little.
Labour and money. Workers are 62 % of the population minus troops; output scales with staffing = min(1, workers/jobs). Gold = tax + market + harbour trade + treaty imports − upkeep. Market prices follow stock with elasticity 0.5: price = base (ref/stock)0.5.
Honest limits. All prices, costs, yields, troop strengths and the raid model are illustrative game constants, not medieval statistics; the realm names are invented. Buildings, ships and the king were modelled in Blender (vertex-coloured, not texture-baked); population, economy, diplomacy and seasons run in the page.