Ramsey_policy with planner_discount=0 or a stochastic d.f

Hi,

I have a model where welfare is of the form:

Welfare(0) = v(0) + betaTrue * GN(+1) * theta(+1) / theta(0) * Welfare(+1)

where GN and theta are log-AR(1) processes, not necessarily contemporaneously independent of v.

My plan for solving this with ramsey_policy was to set planner_discount=0 in the call to Ramsey Policy, with planner_objective Welfare.

However, at present (4.2.5), line 103 of dyn_ramsey_static.m takes beta^(-1), and thus results in NaN returns from that function when beta=0. So clearly at present dyn_ramsey_static.m does not support planner_discount=0, and hence does not support this work-around for stochastic discount factors.

Is there an easy code fix to support planner_discount=0? Or any other suggested work arounds?

Thanks in advance,

Tom