% ============================================================================ % WP18 — Appendix B: numerical algorithm, grids, tolerances and diagnostics % ============================================================================ \section{Numerical algorithm and diagnostics} \label{app:computation} \setcounter{table}{0}\setcounter{figure}{0} \subsection{Algorithm} The stationary equilibrium is computed as follows. (1) Given prices $(p,\tilde p_r)$, the rent from \eqref{eq:rent}, the nominal rate, the estate lottery and the rebate, solve the household problem backward from $J$ to $1$: for each age, compute the values of the cash-only branches (rent, buy, refinance, sell-and-rent, move) on the cash-on-hand grid, with the loan chosen among eleven fractions of the binding origination constraint and the house size by comparison of the stored size-specific values, and the value of staying on the full state grid; next-period liquid assets are chosen by exhaustive search on the asset grid followed by a golden-section refinement; the gift at $j_g$ is chosen among twelve fractions of cash; the estate at $J$ is the terminal wealth. (2) Simulate the dynasty panel with common random numbers: \NDynasties{} slots, each holding a parent and a child whose phases are equidistributed, for ten generations of burn-in and six recorded periods, with the gift and the estate transmitted within the slot. (3) Compute excess demands in the two markets, the conditional means of the simulated estates by quintile (the lottery) and the transfer-tax revenue (the rebate). (4) Clear the rental market in $\tilde p_r$ by the Illinois regula falsi inside a regula falsi on $p$ for the owner-occupied market, then update the lottery and the rebate with damping 0.7 and repeat until the relative excess demands are below $5\times10^{-4}$ and the lottery changes by less than $10^{-3}$. The supply scales $\bar H$, $\bar H_r$ are set once, at the baseline, so that $p^* = \tilde p^*_r = 1$ (\SupplyScaleOwner{} and \SupplyScaleRental{} units). A transition after an unanticipated shock at $t = 0$ is computed by shooting in the sequence space: guess the log price paths $(\log p_t,\log\tilde p_{r,t})_{t