Differences between revisions 1 and 2
Revision 1 as of 2008-07-13 12:12:54
Size: 2314
Editor: email
Comment:
Revision 2 as of 2008-07-13 12:16:32
Size: 2452
Editor: email
Comment:
Deletions are marked like this. Additions are marked like this.
Line 42: Line 42:
 * It is the solution function provide by each participant that permits to compute {{{yt}}} and {{{ytp1}}} from {{{ytm1}}} and {{{e}}}.

Testing program for problem A

List of tests

  1. accuracy on a sphere in the state space
  2. accuracy on a stochastic simulation
  3. Den Haan Marcet statistique

SVN archive

Archive name: http://www.cepremap.cnrs.fr/svn/JedcTestSuiteTestsA

Content

Comments

  • My original idea was to use Dynare parser to generate the model to be tested. I think now it is unecessarily complicated. It is simpler to code the models directly in C++, providing for the changes in spefications and parameter values.
  • The model is made of forward looking, backward looking and static equations
    • for backward looking and static equations, it is sufficient to return the residual of the equation
    • for forward looking equations, we need both the conditional expectation of the residual (tests 1 and 2) and the residual for a given value of next period variables (den Haan Marcet statistic). It is therefore necessary to factorize all the elements of the equation that don't need to be integrated and write in another function the part of the equation that needs integration.

Example

void error(ytm1,yt,frwd_part,e,params,error)
{
  error[0] = yt[1] - params[0]*ytm1[1]-e[0];
  error[1] = yt[0] - params[1]*frwd_part[0];
}

void forward_part(ytm1,yt,ytp1,e,params,frwd)
{
  frwd_part[0] = ytp1[0]*ytp1[1];
}

then forward_part can be integrated as needed over the distribution of ytp1

  • It is the solution function provide by each participant that permits to compute yt and ytp1 from ytm1 and e.

JedcTestsuiteWiki: TestBenchProblemA (last edited 2010-08-18 10:57:35 by SébastienVillemot)