Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with solution to Ex 2 in LQ Control: Foundations lecture #280

Open
jms202 opened this issue Dec 14, 2020 · 4 comments
Open

Issue with solution to Ex 2 in LQ Control: Foundations lecture #280

jms202 opened this issue Dec 14, 2020 · 4 comments
Assignees

Comments

@jms202
Copy link

jms202 commented Dec 14, 2020

In the lecture LQ Control: Foundations, the solution to Exercise 2 includes the following line:

Rf2 = lq_retired.P

Is this correct? Isn't Rf2 supposed to be the terminal value function not the P matrix? The documentation for the `LQ' constructor says:

 |  Rf : array_like(float), optional(default=None)
 |      Rf is the final (in a finite horizon model) payoff(or cost)
 |      matrix that corresponds with the control variable u and is n x
 |      n.  Should be symetric and non-negative definite
@shlff
Copy link
Member

shlff commented Dec 17, 2020

Thanks @jms202 and @jstac .

Hi @jms202 , this is correct. Please look at section solution in lecture lq_control.

You are half right in that

  • Rf2 is supposed to be the terminal condition (not the terminal value function), that is, $x'Rf2x=J_T(x)$.

But please note that both in the lecture and exercise 2, we are discussing a finite-horizon case, where

  • every value function $J_t$ has the form $J_t (x) = x'P_t x + d_t$,
  • for the terminal condition, we have $P_T:=R_f$ and $d_T=0$.

Therefore, we have Rf2 = lq_retired.P.

Please feel free to let me know if you have any question.

@jms202
Copy link
Author

jms202 commented Dec 18, 2020 via email

@shlff
Copy link
Member

shlff commented Dec 18, 2020

Hi @jms202 ,

Thanks for your appreciation.

Before answering your question, please allow me to clarify your statement:

  • I think what your statement refers to is equation (13) in lecture lqcontrol,
  • i.e., $d_{t-1} = \beta * (d_t + trace(C' P_t C))$ with $d_T=0$ (instead of $d_K=0$)

Let me assume this first. Please note that

  • we derive equation (13) from equation (11) backward,
  • we get $d_T=0$ directly from equation (11), while assuming $d_{t-1} = \beta * (d_t + trace(C' P_t C))$,
  • so it doesn't matter whether $C$ equal or not equal zero vector here.

What's more, when you study an economic model, it is helpful to distinguish between exogenous and endogenous variables. For example, in the LQ control system of this lecture,

  • matrices $A, B, C, \cdots$ are exogenously given or assumed,
  • variables $x_{t}, a_t,\cdots$ are endogenously determined by this system.

Once you figured out these, you will have a better understanding of this and other lectures.

Please feel free to let me know if you have any question.

Best,
Shu

@jms202
Copy link
Author

jms202 commented Dec 21, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants