You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The second constraint incorporates notion that individuals only spend
133
136
money on their own end of life consumption. Also, Since $u(.)$ is strictly increasing, both constraints will hold as equalities.
134
137
135
138
136
-
Substituting $s_t$ we get from the first constraint into the second constraint we get $c^2_{t+1}$ in terms of $c^1_t$, i.e.,
139
+
Substituting $s_t$ we get from the first constraint into the second constraint we get $c^2_{t+1}$ in terms of $c^1_t$, i.e.,
137
140
138
-
$$
141
+
```{math}
142
+
:label: c_2_olg
139
143
c^2_{t+1} = R_{t+1}(w_t - c^1_t)
140
-
$$
144
+
```
141
145
Thus first-order condition for a maximum can be written in the
142
146
familiar form of the consumption Euler equation.
143
147
Plugging $c^2_{t+1}$ into the objective function and taking derivative with respect to $c^1_t$ yield the Euler equation,
@@ -240,7 +244,7 @@ def plot45(olg, kstar=None):
240
244
m = 1000
241
245
k_grid = np.linspace(kmin, kmax, m)
242
246
k_grid_next = np.empty_like(k_grid)
243
-
247
+
244
248
for i in range(m):
245
249
k_grid_next[i] = k_next(olg, k_grid[i])
246
250
@@ -293,8 +297,7 @@ there is a unique steady state in $(0, \infty)$.
293
297
294
298
Let's find the value of $k^*$.
295
299
296
-
By observing the above graph, we can see that the value of $k^*$ roughly falls between $(0.15, 0.2)$.
297
-
Using this information, we will again use [scipy.optimize.newton](https://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.newton.html#scipy.optimize.newton).
300
+
By observing the above graph, we can see that the value of $k^*$ roughly falls between $(0.15, 0.2)$. Using this information, we will again use [scipy.optimize.newton](https://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.newton.html#scipy.optimize.newton).
298
301
299
302
```{code-cell} ipython3
300
303
def solve_for_k_star(x, model):
@@ -329,14 +332,14 @@ Let's define the constants and three distinct intital conditions
Since $u$ is quasilinear, in order to solve for $c^1_t$, we will need to use [scipy.optimize.newton](https://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.newton.html#scipy.optimize.newton).
0 commit comments