diff --git a/content/docs/conf.py b/content/docs/conf.py index 3d8e668a..210f731b 100644 --- a/content/docs/conf.py +++ b/content/docs/conf.py @@ -15,6 +15,8 @@ "sphinx.ext.napoleon", "sphinx_autodoc_typehints", "sphinx_copybutton", + "myst_nb", + "sphinx.ext.viewcode", ] source_suffix = [".rst", ".md"] @@ -31,6 +33,14 @@ myst_enable_extensions = [ "colon_fence", + "deflist", + "dollarmath", + "amsmath", + "html_admonition", + "html_image", + "linkify", + "substitution", + "tasklist", ] intersphinx_mapping = { diff --git a/content/paper/1_intro.md b/content/paper/1_intro.md index 7e6b66f4..b510b965 100644 --- a/content/paper/1_intro.md +++ b/content/paper/1_intro.md @@ -1,5 +1,3 @@ - - +++ {"part": "abstract"} Heterogeneous agent models with multiple decisions are often solved using inefficient grid search methods that require many evaluations and are slow. This paper provides a novel method for solving such models using an extension of the Endogenous Grid Method (EGM) that uses Gaussian Process Regression (GPR) to interpolate functions on unstructured grids. First, I propose an intuitive and strategic procedure for decomposing a problem into subproblems which allows the use of efficient solution methods. Second, using an exogenous grid of post-decision states and solving for an endogenous grid of pre-decision states that obey a first-order condition greatly speeds up the solution process. Third, since the resulting endogenous grid can often be non-rectangular at best and unstructured at worst, GPR provides an efficient and accurate method for interpolating the value, marginal value, and decision functions. Applied sequentially to each decision within the problem, the method is able to solve heterogeneous agent models with multiple decisions in a fraction of the time and with less computational resources than are required by standard methods currently used. Software to reproduce these methods is available under the [`Econ-ARK/HARK`](https://econ-ark.org/) project for the `python` programming language. @@ -17,29 +15,12 @@ I would like to thank Chris Carroll, Matthew White, and Simon Scheidegger for th ## Background -% Introduce the topic by providing a brief overview of the issue and why it is important to study it. - -% Identify the research question: Clearly state the research question or problem being addressed in the current study. -% Provide context: Explain why the topic is important to study and what gap in the existing knowledge the current study aims to fill. -% Summarize the existing literature: Briefly describe what is currently known about the topic, including any relevant studies or theories that have been previously published. -% Highlight the limitations of previous research: Identify any limitations or gaps in the existing literature and explain how the current study will address these limitations. -% Provide a rationale for the study: Explain why the current study is needed and why it is a significant contribution to the existing knowledge on the topic. - -% Use only the first paragraph to state the question and describe its importance. Don't weave -% around, be overly broad, or use prior literature to motivate it (the question is not important -% because so many papers looked at this issue before!). - Macroeconomic modeling aims to describe a complex world of agents interacting with each other and making decisions in a dynamic setting. The models are often very complex, require strong underlying assumptions, and use a lot of computational power to solve. One of the most common methods to solve these complex problems is using a grid search method to solve the model. The Endogenous Grid Method (EGM) developed by {cite:t}`Carroll2006` allows dynamic optimization problems to be solved in a more computationally efficient and faster manner than the previous method of convex optimization using grid search. Many problems that before took hours to compute became much easier to solve and allowed macroeconomists and computational economists to focus on estimation and simulation. However, the Endogenous Grid Method is limited to a few specific classes of problems. Recently, the classes of problems to which EGM can be applied have been expanded[^f1], but with every new method comes a new set of limitations. This paper introduces a new approach to EGM in a multivariate setting. The method is called Sequential EGM (or EGM$^n$) and introduces a novel way of breaking down complex problems into a sequence of simpler, smaller, and more tractable problems, along with an exploration of new multidimensional interpolation methods that can be used to solve these problems. [^f1]: {cite:t}`Barillas2007, Maliar2013, Fella2014, White2015, Iskhakov2017`, among others. ## Literature Review -% Summarize the existing literature on the topic and highlight any gaps or limitations in the current research. - -% Then use the second paragraph for a summary of the most relevant literature -% (not a full Section!). Hint: use present tense, to be consistent. "Smith (1986) presents a similar model, ..." - {cite:t}`Carroll2006` first introduced the Endogenous Grid Method as a way to speed up the solution of dynamic stochastic consumption-savings problems. The method consists of starting with an exogenous grid of post-decision states and using the inverse of the first-order condition to find the optimal consumption policy that rationalizes such post-decision states. Given the optimal policy and post-decision states, it is straightforward to calculate the initial pre-decision state that leads to the optimal policy. Although this method is certainly innovative, it only applied to a model with one control variable and one state variable. {cite:t}`Barillas2007` further extend this method by including more than one control variable in the form of a labor-leisure choice, as well as a second state variable for stochastic persistence. {cite:t}`Hintermaier2010` introduce a model with collateral constraints and non-separable utility and solve using an EGM method that allows for occasionally binding constraints among endogenous variables. {cite:t}`Jorgensen2013` evaluates the performance of the Endogenous Grid Method against other methods for solving dynamic stochastic optimization problems and finds it to be fast and efficient. {cite:t}`Maliar2013` develop the Envelope Condition Method based on a similar idea as the Endogenous Grid Method, avoiding the need for costly numerical optimization and grid search. However, their model is limited to infinite horizon problems as it is a forward solution method. @@ -50,42 +31,20 @@ For the papers discussed above, continuity and smoothness of the value and first {cite:t}`Clausen2020` formalize the applicability of the Endogenous Grid Method and its extensions to discrete choice models and discuss the nesting of problems to efficiently find accurate solutions. {cite:t}`Druedahl2021` similarly suggest the nesting of problems to efficiently use the Endogenous Grid Method within problems with multiple control variables. However, while these nested methods reduce the complexity of solving these models, they often still require grid search methods as is the case with {cite:t}`Druedahl2021`. -% Finally, this paper contributes to the literature of solving dynamic optimization problems using machine learning tools. {cite:t}`Scheidegger2019` introduce the use of Gaussian Process Regression to compute global solutions for high-dimensional dynamic stochastic problems. {cite:t}`Maliar2021` use non-linear regression and neural networks to estimate systems of equations that characterize dynamic economic models. - ## Research Question -% Clearly state the research question or problem being addressed in the current study. - -% Next, while still on page one, the third paragraph must begin: "The purpose of this paper is ...", -% and summarize what you actually do. (Paragraphs 2 and 3 could be reversed.) - The purpose of this paper is to describe a new method for solving dynamic optimization problems efficiently and accurately while avoiding convex optimization and grid search methods with the use of the Endogenous Grid Method and first-order conditions. The method is called Sequential EGM (or EGM$^n$) and introduces a novel way of breaking down complex problems into a sequence of simpler, smaller, and more tractable problems, along with an exploration of new multidimensional interpolation methods that can be used to solve these problems. This paper also illustrates an example of how Sequential EGM can be used to solve a dynamic optimization problem in a multivariate setting. ## Methodology -% Briefly describe the research methodology used in the study, including any data sources, econometric techniques, or other methods used. - The sequential Endogenous Grid Method consists of 3 major parts: First, the problem to be solved should be broken up into a sequence of smaller problems that themselves don't add any additional state variables or introduce asynchronous dynamics with respect to the uncertainty. If the problem is broken up in such a way that uncertainty can happen in more than one period, then the solution to this sequence of problems might be different from the aggregate problem due to giving the agent additional information about the future by realizing some uncertainty. Second, I evaluate each of the smaller problems to see if they can be solved using the Endogenous Grid Method. This evaluation is of greater scope than the traditional Endogenous Grid Method, as it allows for the resulting exogenous grid to be non-regular. If the subproblem can not be solved with EGM, then convex optimization is used. Third, if the exogenous grid generated by the EGM is non-regular, then I use a multidimensional interpolation method that takes advantage of machine learning tools to generate an interpolating function. Solving each subproblem in this way, the sequential Endogenous Grid Method is capable of solving complex problems that are not solvable with the traditional Endogenous Grid Method and are difficult and time-consuming to solve with convex optimization and grid search methods. ## Contributions -% Discuss how the current study contributes to the existing literature and what new insights it provides. - -% That sets you up for the fourth paragraph, which lists "The contributions of -% this work" – relative to that prior literature. Clarify what you do that's different - The Sequential Endogenous Grid Method is capable of solving multivariate dynamic optimization problems in an efficient and fast manner by avoiding grid search. This should allow researchers and practitioners to solve more complex problems that were previously not easily accessible to them, but more accurately capture the dynamics of the macroeconomy. By using advancements in machine learning techniques such as Gaussian Process Regression, the Sequential Endogenous Grid Method is capable of solving problems that were not previously able to be solved using the traditional Endogenous Grid Method. In particular, the Sequential Endogenous Grid Method is different from NEGM in that it allows for using more than one Endogenous Grid Method step to solve a problem, avoiding costly grid search methods to the extent that the problem allows. Additionally, the Sequential Endogenous Grid Method often sheds light on the problem by breaking it down into a sequence of simpler problems that were not previously apparent. This is because intermediary steps in the solution process generate value and marginal value functions of different pre- and post-decision states that can be used to understand the problem better. -% The fifth paragraph then summarizes your results. Tell the answer, so they know what to expect, -% and how to think about each step along the way, what's driving your results. - ## Outline -% Provide a brief overview of the results and conclusions that will be presented in the article. -% In the sixth and final paragraph, as an aid to the reader, plot the course for the rest of the paper. -% "The first Section below presents a theoretical model that can be used to generate specific -% hypotheses. Then [Section %s](#method) presents the econometric model, ..." - [Section %s](#method) presents a basic model that illustrates the sequential Endogenous Grid Method in one dimension. Then [Section %s](#multdim) introduces a more complex method with two state variables to demonstrate the use of machine learning tools to generate an interpolating function. In [Section %s](#multinterp) I present the unstructured interpolation methods using machine learning in more detail. [Section %s](#conditions) discusses the theoretical requirements to use the Sequential Endogenous Grid Method. Finally, [Section %s](#conclusion) concludes with some limitations and future work. diff --git a/content/paper/2_method.md b/content/paper/2_method.md index e132955b..f49de9ee 100644 --- a/content/paper/2_method.md +++ b/content/paper/2_method.md @@ -1,5 +1,3 @@ - - (method)= # The Sequential Endogenous Grid Method @@ -8,17 +6,17 @@ The baseline problem which I will use to demonstrate the Sequential Endogenous Grid Method (EGM$^n$) is a discrete time version of {cite:t}`Bodie1992` where a consumer has the ability to adjust their labor as well as their consumption in response to financial risk. The objective consists of maximizing the present discounted lifetime utility of consumption and leisure. -\begin{equation} +```{math} \VFunc_0(\BLev_0, \tShkEmp_0) = \max \Ex_{t} \left[ \sum_{n = 0}^{T-t} \DiscFac^{n} \utilFunc(\CLev_{t+n}, \Leisure_{t+n}) \right] -\end{equation} +``` In particular, this example makes use of a utility function that is based on Example 1 in the paper, which is that of additively separable utility of labor and leisure as -\begin{equation} +```{math} \utilFunc(\CLev, \Leisure) = \util(\CLev) + \h(\Leisure) = \frac{C^{1-\CRRA}}{1-\CRRA} + \labShare^{1-\CRRA} \frac{\Leisure^{1-\leiShare}}{1-\leiShare} -\end{equation} +``` where the term $\labShare^{1-\CRRA}$ is introduced to allow for a balanced growth path as in {cite:t}`Mertens2011`. The use of additively separable utility is ad-hoc, as it will allow for the use of multiple EGM steps in the solution process, as we'll see later. @@ -26,7 +24,7 @@ This model represents a consumer who begins the period with a level of bank bala The problem can be written in normalized recursive form[^f2] as -\begin{equation} +```{math} \begin{split} \vFunc_{t}(\bRat_{t}, \tShkEmp_{t}) & = \max_{\{\cRat_{t}, \leisure_{t}, \riskyshare_{t}\}} \utilFunc(\cRat_{t}, \leisure_{t}) + @@ -41,29 +39,16 @@ The problem can be written in normalized recursive form[^f2] as \riskyshare_{t} \\ \bRat_{t+1} & = \aRat_{t} \Rport_{t+1} / \PGro_{t+1} \end{split} -\end{equation} +``` in which $\labor_{t}$ is the time supplied to labor net of leisure, $\mRat_{t}$ is the market resources totaling bank balances and labor income, $\aRat_{t}$ is the amount of saving assets held by the consumer, and $\riskyshare_{t}$ is the risky share of assets, which induce a $\Rport_{t+1}$ return on portfolio that results in next period's bank balances $\bRat_{t+1}$ normalized by next period's permanent income $\PGro_{t+1}$. [^f2]: As in {cite:t}`Carroll2009`, where the utility of normalized consumption and leisure is defined as - \begin{equation} +```{math} \utilFunc(\cRat_{t}, \leisure_{t}) = \PLev_{t}^{1-\CRRA} \frac{\cRat_{t}^{1-\CRRA}}{1-\CRRA} + (\labShare\PLev_{t}) ^{1-\CRRA} \frac{\leisure_{t}^{1-\leiShare}}{1-\leiShare} - \end{equation} - -% \begin{equation} -% \begin{split} -% \vFunc_{t}(\bRat_{t}, \tShkEmp_{t}) & = \max_{\cRat_{t}, -% \leisure_{t}} \util(\cRat_{t}) + \h(\leisure_{t}) + -% \vEnd_{t} (\aRat_{t}) -% \\ -% & \text{s.t.} \\ -% \labor_{t} & = 1 - \leisure_{t} \\ -% \mRat_{t} & = \bRat_{t} + \tShkEmp_{t}\labor_{t} \\ -% \aRat_{t} & = \mRat_{t} - \cRat_{t} \\ -% \end{split} -% \end{equation} +``` ## Restating the problem sequentially @@ -71,7 +56,7 @@ We can make a few choices to create a sequential problem which will allow us to Starting from the beginning of the period, we can define the labor-leisure problem as -\begin{equation} +```{math} \begin{split} \vFunc_{t}(\bRat_{t}, \tShkEmp_{t}) & = \max_{ \leisure_{t}} \h(\leisure_{t}) + \vOpt_{t} (\mRat_{t}) \\ @@ -80,22 +65,22 @@ Starting from the beginning of the period, we can define the labor-leisure probl \labor_{t} & = 1 - \leisure_{t} \\ \mRat_{t} & = \bRat_{t} + \tShkEmp_{t}\labor_{t}. \end{split} -\end{equation} +``` The pure consumption-saving problem is then -\begin{equation} +```{math} \begin{split} \vOpt_{t}(\mRat_{t}) & = \max_{\cRat_{t}} \util(\cRat_{t}) + \DiscFac\vEnd_{t}(\aRat_{t}) \\ & \text{s.t.} \\ 0 & \leq \cRat_{t} \leq \mRat_{t} \\ \aRat_{t} & = \mRat_{t} - \cRat_{t}. \end{split} -\end{equation} +``` Finally, the risky portfolio problem is -\begin{equation} +```{math} \begin{split} \vEnd_{t}(\aRat_{t}) & = \max_{\riskyshare_{t}} \Ex_{t} \left[ \PGro_{t+1}^{1-\CRRA} @@ -107,29 +92,10 @@ Finally, the risky portfolio problem is \riskyshare_{t} \\ \bRat_{t+1} & = \aRat_{t} \Rport_{t+1} / \PGro_{t+1}. \end{split} -\end{equation} +``` This sequential approach is explicitly modeled after the nested approaches explored in {cite:t}`Clausen2020` and {cite:t}`Druedahl2021`. However, I will offer additional insights that expand on these methods. An important observation is that now, every single choice is self-contained in a subproblem, and although the structure is specifically chosen to minimize the number of state variables at every stage, the problem does not change by this structural imposition. This is because there is no additional information or realization of uncertainty that happens between decisions, as can be seen by the expectation operator being in the last subproblem. From the perspective of the consumer, these decisions are essentially simultaneous, but a careful organization into sub-period problems enables us to solve the model more efficiently and can provide key economic insights. In this problem, as we will see, a key insight will be the ability to explicitly calculate the marginal value of wealth and the Frisch elasticity of labor. -%\begin{equation} -% \begin{split} -% \vFunc_{t}(\bRat_{t}) & = \max_{ \labor_{t}} \h(\leisure_{t}) + \Ex_{t} \left[ \vOpt_{t} (\mRat_{t}) \right] \\ -% & \text{s.t.} \\ -% \labor_{t} & = 1 - \leisure_{t} \\ -% \mRat_{t} & = \bRat_{t} + \tShkEmp_{t+1}\labor_{t} \\ -% \end{split} -%\end{equation} -% -%\begin{equation} -% \begin{split} -% \vOpt_{t}(\mRat_{t}) & = \max_{\aRat_{t}} \util(\cRat_{t}) + \DiscFac \Ex_{t} -% \left[ \PGro_{t+1}^{1-\CRRA} \vFunc_{t+1} (\bRat_{t+1}) \right] \\ -% & \text{s.t.} \\ -% \aRat_{t} & = \mRat_{t} - \cRat_{t} \\ -% \bRat_{t+1} & = \aRat_{t} \Rfree / \PGro_{t+1} -% \end{split} -%\end{equation} - ## The portfolio decision subproblem As useful as it is to be able to use the EGM step more than once, there are clear problems where the EGM step is not applicable. This basic labor-portfolio choice problem demonstrates where we can use an additional EGM step, and where we can not. First, we go over a subproblem where we can not use the EGM step. @@ -138,174 +104,174 @@ In reorganizing the labor-portfolio problem into subproblems, we assigned the ut Restating the problem in compact form gives -\begin{equation} +```{math} \vEnd_{t}(\aRat_{t}) = \max_{\riskyshare_{t}} \Ex_{t} \left[ \PGro_{t+1}^{1-\CRRA} \vFunc_{t+1}\left(\aRat_{t}(\Rfree + (\Risky_{t+1} - \Rfree) \riskyshare_{t}), \tShkEmp_{t+1}\right) \right]. -\end{equation} +``` The first-order condition with respect to the risky portfolio share is then -\begin{equation} +```{math} \Ex_{t} \left[ \PGro_{t+1}^{-\CRRA} \vFunc_{t+1}^{\bRat}\left(\bRat_{t+1}, \tShkEmp_{t+1}\right) (\Risky_{t+1} - \Rfree) \right] = 0. -\end{equation} +``` Finding the optimal risky share requires numerical optimization and root-solving of the first-order condition. To close out the problem, we can calculate the envelope condition as -\begin{equation} +```{math} \vEnd_{t}'(\aRat_{t}) = \Ex_{t} \left[ \PGro_{t+1}^{-\CRRA} \vFunc_{t+1}^{\bRat}\left(\bRat_{t+1}, \tShkEmp_{t+1}\right) \Rport_{t+1} \right]. -\end{equation} +``` ### A note on avoiding taking expectations more than once We could instead define the portfolio choice subproblem as: -\begin{equation} +```{math} \vEnd_{t}(\aRat_{t}) = \max_{\riskyshare_{t}} \vOptAlt(\aRat_{t}, \riskyshare_{t}) -\end{equation} +``` where -\begin{equation} +```{math} \begin{split} \vOptAlt_{t}(\aRat_{t}, \riskyshare_{t}) & = \Ex_{t} \left[ \PGro_{t+1}^{1-\CRRA} \vFunc_{t+1}\left(\bRat_{t+1}, \tShkEmp_{t+1}\right) \right] \\ \Rport_{t+1} & = \Rfree + (\Risky_{t+1} - \Rfree) \riskyshare_{t} \\ \bRat_{t+1} & = \aRat_{t} \Rport_{t+1} / \PGro_{t+1} \end{split} -\end{equation} +``` In this case, the process is similar. The only difference is that we don't have to take expectations more than once. Given the next period's solution, we can calculate the marginal value functions as: -\begin{equation} +```{math} \begin{split} \vOptAlt_{t}^{\aRat}(\aRat_{t}, \riskyshare_{t}) & = \Ex_{t} \left[ \PGro_{t+1}^{-\CRRA} \vFunc_{t+1}'\left(\bRat_{t+1}, \tShkEmp_{t+1}\right) \Rport_{t+1} \right] \\ \vOptAlt_{t}^{\riskyshare}(\aRat_{t}, \riskyshare_{t}) & = \Ex_{t} \left[ \PGro_{t+1}^{-\CRRA} \vFunc_{t+1}'\left(\bRat_{t+1}, \tShkEmp_{t+1}\right) \aRat_{t} (\Risky_{t+1} - \Rfree) \right] \\ \end{split} -\end{equation} +``` If we are clever, we can calculate both of these in one step. Now, the optimal risky share can be found by the first-order condition and we can use it to evaluate the envelope condition. -\begin{equation} +```{math} \text{F.O.C.:} \qquad \vOptAlt_{t}^{\riskyshare}(\aRat_{t}, \riskyshare_{t}^{*}) = 0 \qquad \text{E.C.:} \qquad \vEnd_{t}^{\aRat}(\aRat_{t}) = \vOptAlt_{t}^{\aRat}(\aRat_{t}, \riskyshare_{t}^{*}) -\end{equation} +``` ## The consumption-saving subproblem The consumption-saving EGM follows {cite:t}`Carroll2006` but I will cover it for exposition. We can begin the solution process by restating the consumption-savings subproblem in a more compact form, substituting the market resources constraint and ignoring the no-borrowing constraint for now. The problem is: -\begin{equation} +```{math} \vOpt_{t}(\mRat_{t}) = \max_{\cRat_{t}} \util(\cRat_{t}) + \DiscFac \vEnd_{t}(\mRat_{t}-\cRat_{t}) -\end{equation} +``` To solve, we derive the first-order condition with respect to $\cRat_{t}$ which gives the familiar Euler equation: -\begin{equation} +```{math} \utilFunc'(\cRat_t) = \DiscFac \vEnd_{t}'(\mRat_{t} - \cRat_{t}) = \DiscFac \vEnd_{t}'(\aRat_{t}) -\end{equation} +``` Inverting the above equation is the (first) EGM step. -\begin{equation} +```{math} \cEndFunc_{t}(\aRat_{t}) = \utilFunc'^{-1}\left( \DiscFac \vEnd_{t}'(\aRat_{t}) \right) -\end{equation} +``` Given the utility function above, the marginal utility of consumption and its inverse are -\begin{equation} +```{math} \utilFunc'(\cRat) = \cRat^{-\CRRA} \qquad \utilFunc'^{-1}(\xRat) = \xRat^{-1/\CRRA}. -\end{equation} +``` {cite:t}`Carroll2006` demonstrates that by using an exogenous grid of $\aMat$ points we can find the unique $\cEndFunc_{t}(\aMat)$ that optimizes the consumption-saving problem, since the first-order condition is necessary and sufficient. Further, using the market resources constraint, we can recover the exact amount of market resources that is consistent with this consumption-saving decision as -\begin{equation} +```{math} \mEndFunc_{t}(\aMat) = \cEndFunc_{t}(\aMat) + \aMat. -\end{equation} +``` This $\mEndFunc_{t}(\aMat)$ is the ``endogenous'' grid that is consistent with the exogenous decision grid $\aMat$. Now that we have a $(\mEndFunc_{t}(\aMat), \cEndFunc_{t}(\aMat))$ pair for each $\aRat \in \aMat$, we can construct an interpolating consumption function for market resources points that are off-the-grid. The envelope condition will be useful in the next section, but for completeness is defined here. -\begin{equation} +```{math} \vOpt_{t}'(\mRat_{t}) = \DiscFac \vEnd_{t}'(\aRat_{t}) = \utilFunc'(\cRat_{t}) -\end{equation} +``` ## The labor-leisure subproblem The labor-leisure subproblem can be restated more compactly as: -\begin{equation} +```{math} \vFunc_{t}(\bRat_{t}, \tShkEmp_{t}) = \max_{ \leisure_{t}} \h(\leisure_{t}) + \vOpt_{t}(\bRat_{t} + \tShkEmp_{t}(1-\leisure_{t})) -\end{equation} +``` The first-order condition with respect to leisure implies the labor-leisure Euler equation -\begin{equation} +```{math} \h'(\leisure_{t}) = \vOpt_{t}'(\mRat_{t}) \tShkEmp_{t} -\end{equation} +``` The marginal utility of leisure and its inverse are -\begin{equation} +```{math} \h'(\leisure) = \labShare\leisure^{-\leiShare} \qquad \h'^{-1}(\xRat) = (\xRat/\labShare)^{-1/\leiShare} -\end{equation} +``` Using an exogenous grid of $\mMat$ and $\tShkMat$, we can find leisure as -\begin{equation} +```{math} \zEndFunc_{t}(\mMat, \tShkMat) = \h'^{-1}\left( \vOpt_{t}'(\mMat) \tShkMat \right) -\end{equation} +``` In this case, it's important to note that there are conditions for leisure itself. An agent with a small level of market resources $\mRat_{t}$ might want to work more than their available time endowment, especially at higher levels of income $\tShkEmp_{t}$, if the utility of leisure is not enough to compensate for their low wealth. In these situations, the optimal unconstrained leisure might be negative, so we must impose a constraint on the optimal leisure function. This is similar to the treatment of an artificial borrowing constraint in the pure consumption subproblem. From now on, let's call this constrained optimal function $\hat{\zEndFunc}_{t}(\mMat, \tShkMat)$, where -\begin{equation} +```{math} \hat{\zEndFunc}_{t}(\mMat, \tShkMat) = \max \left[ \min \left[ \zEndFunc_{t}(\mMat, \tShkMat), 1 \right], 0 \right] -\end{equation} +``` Then, we derive labor as $\lEndFunc_{t}(\mRat_{t}, \tShkEmp_{t}) = 1 - \hat{\zEndFunc}_{t}(\mRat_{t}, \tShkEmp_{t})$. Finally, for each $\tShkEmp_{t}$ and $\mRat_{t}$ as an exogenous grid, we can find the endogenous grid of bank balances as $\bEndFunc_{t}(\mRat_{t}, \tShkEmp_{t}) = \mRat_{t} - \tShkEmp_{t}\lEndFunc_{t}(\mRat_{t}, \tShkEmp_{t})$. The envelope condition then provides a heterogeneous Frisch elasticity of labor as simply -\begin{equation} +```{math} \vFunc_{t}^{b}(\bRat_{t}, \tShkEmp_{t}) = \vOpt_{t}'(\mRat_{t}) = \h'(\leisure_{t})/\tShkEmp_{t}. -\end{equation} +``` ## Alternative Parametrization An alternative formulation for the utility of leisure is to state it in terms of the disutility of labor as in (references) -\begin{equation} +```{math} \h(\labor) = - \leiShare \frac{\labor^{1+\labShare}}{1+\labShare} -\end{equation} +``` In this case, we can restate the problem as -\begin{equation} +```{math} \h(\leisure) = - \leiShare \frac{(1-\leisure)^{1+\labShare}}{1+\labShare} -\end{equation} +``` The marginal utility of leisure and its inverse are -\begin{equation} +```{math} \h'(\leisure) = \leiShare(1-\leisure)^{\labShare} \qquad \h'^{-1}(\xRat) = 1 - (\xRat/\leiShare)^{1/\labShare} -\end{equation} +``` ## Curvilinear Grids diff --git a/myst.yml b/myst.yml index c95db744..f9d02aa6 100644 --- a/myst.yml +++ b/myst.yml @@ -1,9 +1,10 @@ -version: 1 +version: 2 site: template: article-theme options: logo: content/public/econ-ark-logo.png logo_text: Econ-ARK + favicon: public/econ-ark-logo-small.png title: Alan Lujan - EGMⁿ subtitle: The Sequential Endogenous Grid Method short_title: EGMⁿ @@ -40,7 +41,6 @@ site: static: true domains: - alanlujan91.curve.space - favicon: public/econ-ark-logo-small.png project: title: "EGMⁿ: The Sequential Endogenous Grid Method" short_title: EGMⁿ @@ -494,7 +494,6 @@ project: '\sLvl': '\mathbf{s}' '\TLvl': '\mathbf{T}' '\ULvl': '\mathbf{U}' - '\VLvl': '\mathbf{V}' '\vLvl': '\mathbf{v}' '\WLvl': '\mathbf{W}' '\XLvl': '\mathbf{X}'