SPB Git

spb/wp29_uqo

Public
5.6 KB · 71 lines markdown
1# F5-conf-04 — VFI vs closed-form policy (optimal growth, log utility)23## Question4A planner maximises Σ β^t ln c_t subject to y_{t+1} = (y_t − c_t)^α (Cobb–Douglas, productivity 1, full5depreciation). We derive the closed-form policy and value function, solve the Bellman equation numerically by6value-function iteration (VFI) on the prescribed grid, and compare the two at y = 0.5, 1, 2 (policy) and y = 1 (value).78## Data and exclusions9The only input is `data/model.csv` (10 rows; `n_input_rows`): α = 0.36, β = 0.95, grid of 400 points (`grid_points_used`)10log-spaced on [0.05, 5], VFI tolerance 1e-8 (sup norm), evaluation points 0.5, 1.0, 2.0. These are model parameters,11not observations. Nothing was excluded (`out/exclusions.csv`); all 400 grid points are analysed (`n_analysed`).12No deviation from the prescribed design was needed (`data_issues` = []). The evaluation points are not grid nodes13(`diag_eval_points_on_grid` all false; log step `diag_grid_log_step` ≈ 0.01154), so the VFI policy and value are14linearly interpolated in ln y between the neighbouring nodes, as the task allows. No randomness is used (`random_seed` = null).1516## Method17**Closed form (guess and verify).** Guess V(y) = A + B ln y. The first-order condition of18max_c {ln c + βA + βBα ln(y − c)} gives 1/c = αβB/(y − c), so c = y/(1 + αβB). Matching the coefficient on ln y gives19B = 1 + αβB ⇒ B = 1/(1 − αβ), hence **c(y) = (1 − αβ) y** and the savings rate is (y − c)/y = **αβ**. Matching constants gives20**A = [ln(1 − αβ) + (αβ/(1 − αβ)) ln(αβ)] / (1 − β)**. Assumptions: log utility, Cobb–Douglas technology y' = k^α with210 < α < 1 and unit productivity, full depreciation, deterministic environment, 0 < β < 1, and an interior solution22(0 < c < y, which holds since 0 < αβ < 1). I checked independently that this V is a fixed point of the Bellman operator at23y = 0.5, 1, 2 by numerical maximisation (see `out/state/checks.md`, check 3).2425**VFI.** State: y on the 400-point log grid. Choice: next-period output y'_j on the same grid, which requires capital26k = (y'_j)^{1/α} and leaves c = y_i − (y'_j)^{1/α}; choices with c ≤ 0 are infeasible (utility −∞). Starting from V₀ = 0, iterate27V_{n+1}(y_i) = max_j {ln c_ij + β V_n(y'_j)} until sup|V_{n+1} − V_n| < 1e-8. The policy is c at the argmax. The numerical28policy never uses the closed form. No optimal choice lies at either grid bound (`diag_choice_at_lower_bound` = 0,29`diag_choice_at_upper_bound` = 0), so the grid does not truncate the solution.3031**Contraction.** The Bellman operator T satisfies Blackwell's sufficient conditions on bounded functions: monotonicity32(V ≤ W ⇒ TV ≤ TW) and discounting (T(V + a) = TV + βa). Hence ‖TV − TW‖∞ ≤ β‖V − W‖∞, modulus **β = 0.95**33(`contraction_modulus`). (Log utility is unbounded on (0, ∞); on the compact discretised grid all values are bounded, so the34argument applies exactly to the discrete operator that is iterated.)3536## Results37| quantity | closed form | VFI |38|---|---|---|39| c(0.5) | 0.329 (`c_closed_y05`) | 0.328818 (`c_num_y05`) |40| c(1.0) | 0.658 (`c_closed_y1`) | 0.658994 (`c_num_y1`) |41| c(2.0) | 1.316 (`c_closed_y2`) | 1.309625 (`c_num_y2`) |42| V(1) | −19.524412 (`value_closed_y1`) | −19.524756 (`value_num_y1`) |4344- Maximum absolute policy discrepancy over the three points: 0.006375 (`max_abs_error_policy`), attained at y = 245  (≈ 0.5 % of c); relative errors at y = 0.5 and 1 are below 0.2 %.46- Value at y = 1 differs by 3.4e-4 utils (`diag_value_abs_error_y1`).47- Closed-form savings rate αβ = 0.342 (`savings_rate_closed_form`), i.e. c = 0.658 y.48- Contraction modulus 0.95 (`contraction_modulus`). VFI met the stopping rule after 361 iterations (`n_iterations`) with49  final sup change 9.997e-9 (`final_sup_change`).50- Over the whole grid, max policy error is 0.0251 (`diag_policy_max_abs_error_on_grid`) and max value error 4.8e-451  (`diag_value_max_abs_error_on_grid`).5253## Uncertainty54The problem is deterministic; there is no sampling uncertainty. The numerical error has two sources:55(i) **iteration error**: by the contraction property, ‖V_n − V*‖∞ ≤ β/(1 − β)·‖V_n − V_{n−1}‖∞ ≤ 1.9e-756(`diag_value_tolerance_bound`), negligible; (ii) **discretisation error**: the choice y' is restricted to grid nodes and57results at off-grid points are linearly interpolated. This dominates: the 3.4e-4 value gap at y = 1 is far larger than58the 1.9e-7 iteration bound. The policy error is roughly proportional to the change in capital between adjacent choice nodes,59Δk ≈ (k/α)·Δln y', which grows with y; this explains why the error is largest at y = 2 and at the top of the grid.6061## Limitations and open issues62- The validation holds only for the single parameter point (α = 0.36, β = 0.95) and the single grid (400 log-spaced points on63  [0.05, 5], tolerance 1e-8). Discretisation error depends on the grid density (log step ≈ 0.0115), on α (through64  k = y'^{1/α}), on the level of y, and on the interpolation rule for off-grid evaluation points. A finer grid or a65  continuous choice of c would reduce it; these were not run because the task prescribes the grid.66- The VFI policy is a step function between nodes, so pointwise errors at individual nodes can be as large as67  `diag_policy_max_abs_error_on_grid`, which is larger than the error at the three evaluation points.68- The closed form needs log utility, Cobb–Douglas technology, full depreciation and an interior solution; it does not69  extend to partial depreciation or CRRA utility with σ ≠ 1.70- Feasibility: complete (`feasibility`); no part of the task was left undone.71
Files · 4f59ed568641ceda6f39552d5cc3a441aa812088
Menu

Theme