Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
bbardoczy committed Aug 7, 2019
2 parents bdecaaf + bc1e764 commit 0dd6ce6
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 3 deletions.
Binary file added docs/figures/rbc_dag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 10 additions & 1 deletion docs/rbc.html
Original file line number Diff line number Diff line change
Expand Up @@ -11934,7 +11934,16 @@ <h2 id="1-Steady-state">1 Steady state<a class="anchor-link" href="#1-Steady-sta
<div class="inner_cell">
<div class="text_cell_render border-box-sizing rendered_html">
<h2 id="2-Model-blocks">2 Model blocks<a class="anchor-link" href="#2-Model-blocks">&#182;</a></h2><p>The second step of solving the model is to come up with a Directed Acyclic Graph (DAG) representation for it and specify its building blocks.</p>
<p>The 7 equations of the model can be organized as 3 simple blocks to form a Directed Acyclic Graph (DAG) in 2 unknowns $\{K, L\}$ and 2 targets, the Euler equation and goods market clearing.</p>
<p>The 7 equations of the model can be organized as three simple blocks to form a Directed Acyclic Graph (DAG) in two unknowns $\{K, L\}$ and two targets, the euler equation and goods market clearing:</p>
<p><img src="figures/rbc_dag.png" alt="Directed Acyclic Graph for RBC model"></p>

</div>
</div>
</div>
<div class="cell border-box-sizing text_cell rendered"><div class="prompt input_prompt">
</div>
<div class="inner_cell">
<div class="text_cell_render border-box-sizing rendered_html">
<p>In our code, simple blocks are specified as regular Python functions endowed with the decorator <code>@simple</code>. In the body of the function, we directly implement the corresponding equilibrium conditions. The decorator turns the function into an instance of <code>SimpleBlock</code>, a class that, among other things, knows how to handle time displacements such as <code>K(-1)</code> to denote 1-period lags and <code>r(+1)</code> to denote 1-period leads. In general, one can write (-s) and (+s) to denote s-period lags and leads.</p>

</div>
Expand Down
Binary file added figures/rbc_dag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 10 additions & 2 deletions rbc.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,15 @@
"\n",
"The second step of solving the model is to come up with a Directed Acyclic Graph (DAG) representation for it and specify its building blocks.\n",
"\n",
"The 7 equations of the model can be organized as 3 simple blocks to form a Directed Acyclic Graph (DAG) in 2 unknowns $\\{K, L\\}$ and 2 targets, the Euler equation and goods market clearing.\n",
"The 7 equations of the model can be organized as three simple blocks to form a Directed Acyclic Graph (DAG) in two unknowns $\\{K, L\\}$ and two targets, the euler equation and goods market clearing:\n",
"\n",
"![Directed Acyclic Graph for RBC model](figures/rbc_dag.png) "
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"\n",
"In our code, simple blocks are specified as regular Python functions endowed with the decorator ``@simple``. In the body of the function, we directly implement the corresponding equilibrium conditions. The decorator turns the function into an instance of ``SimpleBlock``, a class that, among other things, knows how to handle time displacements such as `K(-1)` to denote 1-period lags and `r(+1)` to denote 1-period leads. In general, one can write (-s) and (+s) to denote s-period lags and leads. "
]
Expand Down Expand Up @@ -411,7 +419,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.8"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down

0 comments on commit 0dd6ce6

Please sign in to comment.