Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions lectures/arma.md
Original file line number Diff line number Diff line change
Expand Up @@ -864,6 +864,8 @@ where `ma_poly` and `ar_poly` correspond to the polynomials in {eq}`arma_poly` -
* `ma_poly` is the vector $(1, \theta_1, \theta_2, \ldots, \theta_q)$
* `ar_poly` is the vector $(1, -\phi_1, -\phi_2, \ldots, - \phi_p)$

Both vectors must have the same length, so the shorter one is padded with trailing zeros: `dimpulse` reads them as polynomials in positive powers of $z$, and an `ar_poly` longer than `ma_poly` would otherwise delay the response by the difference in their lengths.

To this end, we also maintain the arrays `ma_poly` and `ar_poly` as instance data, with their values computed automatically from the values of `phi` and `theta` supplied by the user.

If the user decides to change the value of either `theta` or `phi` ex-post by assignments
Expand Down
4 changes: 0 additions & 4 deletions lectures/markov_jump_lq.md
Original file line number Diff line number Diff line change
Expand Up @@ -240,10 +240,6 @@ The conditional expectation $\bar P_i$ appears inside the inverse.

Averaging the quadratic forms $(\beta B_i' P_j A_i + W_i)' (Q_i + \beta B_i' P_j B_i)^{-1} (\beta B_i' P_j A_i + W_i)$ over $j$ instead gives a different and incorrect recursion, except when next period's Markov state is known with certainty or when $Q_i + \beta B_i' P_j B_i$ and $B_i' P_j A_i$ do not vary with $j$.

At the time of writing, `quantecon.LQMarkov` implements that averaged recursion.

In the examples below, its decision rules differ from those of the correct recursion by at most 2 percent.

## Applications

We use the following imports.
Expand Down
2 changes: 0 additions & 2 deletions lectures/policy_regimes.md
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,6 @@ The decision rule in regime $i$ is $q_t = -F_i x_t$ with $F_i = (Q_i + \beta B'

We code the iteration directly.

At the time of writing, `quantecon.LQMarkov` averages over next-period Markov states outside the matrix inverse, which gives a different recursion when $\Pi$ has more than one nonzero element in a row.

```{code-cell} python3
def solve_regimes(φs, Π, tol=1e-12, max_iter=20_000):
"Decision rules F_i for regimes with feedback coefficients φs and transition matrix Π."
Expand Down
Loading