Model sequential choices using recursive optimization, bounded controls, and evolving states. Inspect policy grids quickly. Get optimal actions and trajectories for each planning period.
Use the responsive input grid below. Large screens show three columns, smaller screens show two, and mobile shows one.
The sample values below match the default inputs in the calculator and give a practical finite-horizon optimization scenario.
| Parameter | Example Value | Description |
|---|---|---|
| Time horizon | 6 | Six optimization periods. |
| Initial state | 10 | Starting system level. |
| Discount factor | 0.95 | Future value weighting. |
| State range | 0 to 50 | Allowed grid for state interpolation. |
| State step | 1 | Distance between state grid points. |
| Control range | 0 to 15 | Allowed control choices each period. |
| Control step | 0.5 | Distance between control options. |
| State transition | x(t+1) = 0.90x(t) + 1.20u(t) + 2.00 | Evolution equation. |
| Stage objective | 12x - 0.25x² - 5u - 0.60u² - 0.15xu | Per-period payoff rule. |
| Terminal objective | 8x(T+1) - 0.10x(T+1)² | Final-state reward rule. |
This calculator solves a finite-horizon dynamic optimization problem with one state variable and one control variable.
Where: x is the state, u is the control, δ is the discount factor, and T is the horizon length.
Method: The calculator uses backward induction on a discrete state-control grid. When next-state values fall between grid points, linear interpolation estimates the continuation value.
It finds the sequence of controls that maximizes total discounted value across a finite planning horizon, subject to the transition equation and chosen control limits.
They define the state grid used for dynamic programming. A wider grid captures more outcomes. A smaller step improves precision, but it also increases runtime and memory use.
The discount factor reduces the weight of future rewards. A value near 1 treats future periods as important. A lower value makes early rewards dominate the solution.
Continuation values are clipped to the nearest grid boundary through interpolation. If this happens often, widen the state range so the optimization better reflects your system.
Yes. Represent benefits as small or zero values and enter penalties as positive coefficients. Maximizing a negative net payoff works like minimizing total cost.
Reduce steps when the solution changes sharply between nearby states or controls, or when you want a closer approximation to a continuous problem. Balance accuracy against speed.
Yes, as long as your chosen ranges include negative values and the model interpretation supports them. The calculator works with positive or negative states and controls.
This tool uses grid search and interpolation, which approximate a continuous optimization problem. Finer grids usually reduce the gap between numerical and exact solutions.
Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.