This is related to: https://lectures.quantecon.org/py/rational_expectations.html#

While solving the planners problem, I had made my R matrix of the following form:

The lectures have it as:

The minimization turns out to be the same (as far as I know) which is -S(Yt, Y(t+1)), but my final answer turns out to be different (my k0 is twice as much as the actual answers’).

Why is this the case? Would be helpful if anyone could shed some light here.

Thanks