just formatting changes
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2659 ac1d8469-bf42-47a9-8791-bf33cf982152time-shift
parent
aa3b7c78f3
commit
473b4d9a2f
|
@ -75,7 +75,6 @@ KordpDynare::KordpDynare(const char** endo, int num_endo,
|
||||||
FSSparseTensor* t = new FSSparseTensor(iord, nY+nYs+nYss+nExog,nY);
|
FSSparseTensor* t = new FSSparseTensor(iord, nY+nYs+nYss+nExog,nY);
|
||||||
md.insert(t);
|
md.insert(t);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
catch (...){
|
catch (...){
|
||||||
mexPrintf("k_ord_dynare: dynare constructor, error in StateNamelist construction.\n");
|
mexPrintf("k_ord_dynare: dynare constructor, error in StateNamelist construction.\n");
|
||||||
|
@ -232,10 +231,6 @@ void KordpDynare::calcDerivatives(const Vector& yy, const Vector& xx)
|
||||||
/* This version is not currently in use */
|
/* This version is not currently in use */
|
||||||
void KordpDynare::calcDerivatives(const Vector& yy, ogu::Jacobian& jacob)
|
void KordpDynare::calcDerivatives(const Vector& yy, ogu::Jacobian& jacob)
|
||||||
{
|
{
|
||||||
// ConstVector yym(yy, nstat(), nys());
|
|
||||||
// ConstVector yyp(yy, nstat()+npred(), nyss());
|
|
||||||
|
|
||||||
// Vector yyp(yy, nstat()+npred(), nyss());
|
|
||||||
|
|
||||||
//double *g1, *g2;
|
//double *g1, *g2;
|
||||||
TwoDMatrix * jj= &jacob;
|
TwoDMatrix * jj= &jacob;
|
||||||
|
@ -429,10 +424,6 @@ Vector * KordpDynare::LLxSteady( const Vector& yS){
|
||||||
************************************/
|
************************************/
|
||||||
|
|
||||||
vector<int> * KordpDynare::ReorderDynareJacobianIndices( const vector<int> * varOrder){
|
vector<int> * KordpDynare::ReorderDynareJacobianIndices( const vector<int> * varOrder){
|
||||||
// if ((nJcols != tdx->ncols()) && ( nY != tdx->nrows())) {
|
|
||||||
// mexPrintf("k_ord_dynare.cpp: Error in ReorderBlocks: wrong size of jacobian");
|
|
||||||
// return;
|
|
||||||
// }
|
|
||||||
// create temporary square 2D matrix size nEndo x nEndo (sparse)
|
// create temporary square 2D matrix size nEndo x nEndo (sparse)
|
||||||
// for the lag, current and lead blocks of the jacobian
|
// for the lag, current and lead blocks of the jacobian
|
||||||
// int * JacobianIndices = (int*) calloc(nJcols+1, sizeof(int));
|
// int * JacobianIndices = (int*) calloc(nJcols+1, sizeof(int));
|
||||||
|
|
|
@ -41,34 +41,6 @@
|
||||||
|
|
||||||
class KordpDynare;
|
class KordpDynare;
|
||||||
|
|
||||||
// derive from Approximation to get protected derivatives
|
|
||||||
/******
|
|
||||||
class FistOrderApproximation: public Approximation{
|
|
||||||
TwoDMatrix *gy;
|
|
||||||
TwoDMatrix *gu;
|
|
||||||
public:
|
|
||||||
FistOrderApproximation();
|
|
||||||
FistOrderApproximation(FistOrderApproximation& fo): ::Approximation(fo){
|
|
||||||
if (&(fo.GetGy())!=0){
|
|
||||||
gy= new TwoDMatrix(fo.GetGy());
|
|
||||||
gu= new TwoDMatrix(fo.GetGu());
|
|
||||||
}
|
|
||||||
};
|
|
||||||
virtual ~FistOrderApproximation(){
|
|
||||||
delete gy;
|
|
||||||
delete gu;
|
|
||||||
};
|
|
||||||
virtual void approxAtSteady(); // NOTE: change the Approximation parent to use virual too so that it can be overriden !!
|
|
||||||
//FGSContainer* GetRuleDers(){return rule_ders;};
|
|
||||||
//FGSContainer* GetRuleDersSS(){return rule_ders_ss;};
|
|
||||||
const TwoDMatrix& GetGy(){return (const TwoDMatrix&)(*gy);};
|
|
||||||
const TwoDMatrix& GetGu(){return (const TwoDMatrix&)(*gu);};
|
|
||||||
virtual void saveRuleDerivs(FirstOrder& fo);
|
|
||||||
};
|
|
||||||
***********/
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*////////////////////////////////////////////*/
|
/*////////////////////////////////////////////*/
|
||||||
// instantiations of pure abstract class NameList in dynamic_model.h:
|
// instantiations of pure abstract class NameList in dynamic_model.h:
|
||||||
/*////////////////////////////////////////////*/
|
/*////////////////////////////////////////////*/
|
||||||
|
@ -194,8 +166,6 @@ public:
|
||||||
{return *ySteady;}
|
{return *ySteady;}
|
||||||
Vector& getSteady()
|
Vector& getSteady()
|
||||||
{return *ySteady;}
|
{return *ySteady;}
|
||||||
/// const ogdyn::DynareModel& getModel() const
|
|
||||||
/// {return *model;}
|
|
||||||
|
|
||||||
// here is true public interface
|
// here is true public interface
|
||||||
void solveDeterministicSteady(Vector& steady);
|
void solveDeterministicSteady(Vector& steady);
|
||||||
|
@ -278,6 +248,3 @@ public:
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Local Variables:
|
|
||||||
// mode:C++
|
|
||||||
// End:
|
|
||||||
|
|
|
@ -427,8 +427,8 @@ extern "C" {
|
||||||
e.print(errfd);
|
e.print(errfd);
|
||||||
fclose(errfd);
|
fclose(errfd);
|
||||||
return;// 255;
|
return;// 255;
|
||||||
}
|
} //catch
|
||||||
};
|
}; // end of mexFunction()
|
||||||
}; // end of extern C
|
}; // end of extern C
|
||||||
|
|
||||||
//////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////
|
||||||
|
|
|
@ -84,9 +84,7 @@ public:
|
||||||
DynamicModelDLL(const char* fname, const int length,const int jcols,
|
DynamicModelDLL(const char* fname, const int length,const int jcols,
|
||||||
const int nMax_lag, const int nExog, const char * sExt);
|
const int nMax_lag, const int nExog, const char * sExt);
|
||||||
virtual ~DynamicModelDLL(){close();};
|
virtual ~DynamicModelDLL(){close();};
|
||||||
// DynamicFn get(){return DynamicDLLfunc;};
|
|
||||||
// void
|
|
||||||
// ((DynamicFn())*) get(){return Dynamic;};
|
|
||||||
// evaluate Dynamic model DLL
|
// evaluate Dynamic model DLL
|
||||||
void eval(double *y, double *x, int nb_row_x, double *params,
|
void eval(double *y, double *x, int nb_row_x, double *params,
|
||||||
int it_, double *residual, double *g1, double *g2){
|
int it_, double *residual, double *g1, double *g2){
|
||||||
|
|
Loading…
Reference in New Issue