Remove unfinished “occbin” option to perfect_foresight_solver and extended_path

Partially reverts f914837aff and
567156aad4.
issue#70
Sébastien Villemot 2021-02-22 15:53:09 +01:00
parent 825b9ee8ef
commit 54365b16ed
No known key found for this signature in database
GPG Key ID: 2CECE9350ECEBE4A
5 changed files with 2 additions and 16 deletions

View File

@ -211,9 +211,6 @@ void
PerfectForesightSolverStatement::checkPass(ModFileStructure &mod_file_struct, WarningConsolidation &warnings)
{
mod_file_struct.perfect_foresight_solver_present = true;
// Fill in option_occbin of mod_file_struct
if (options_list.num_options.find("occbin") != options_list.num_options.end())
mod_file_struct.occbin_option = true;
}
void
@ -4638,10 +4635,6 @@ ExtendedPathStatement::checkPass(ModFileStructure &mod_file_struct, WarningConso
cerr << "ERROR: the 'periods' option of 'extended_path' is mandatory" << endl;
exit(EXIT_FAILURE);
}
// Fill in option_occbin of mod_file_struct
if (options_list.num_options.find("occbin") != options_list.string_options.end())
mod_file_struct.occbin_option = true;
}
void

View File

@ -122,7 +122,7 @@ class ParsingDriver;
%token UNIFORM_PDF UNIT_ROOT_VARS USE_DLL USEAUTOCORR GSA_SAMPLE_FILE USE_UNIVARIATE_FILTERS_IF_SINGULARITY_IS_DETECTED
%token VALUES VAR VAREXO VAREXO_DET VARIABLE VAROBS VAREXOBS PREDETERMINED_VARIABLES VAR_EXPECTATION VAR_EXPECTATION_MODEL PLOT_SHOCK_DECOMPOSITION MODEL_LOCAL_VARIABLE
%token WRITE_LATEX_DYNAMIC_MODEL WRITE_LATEX_STATIC_MODEL WRITE_LATEX_ORIGINAL_MODEL WRITE_LATEX_STEADY_STATE_MODEL
%token XLS_SHEET XLS_RANGE LMMCP OCCBIN BANDPASS_FILTER COLORMAP VAR_MODEL PAC_MODEL QOQ YOY AOA PAC_EXPECTATION TREND_COMPONENT_MODEL
%token XLS_SHEET XLS_RANGE LMMCP BANDPASS_FILTER COLORMAP VAR_MODEL PAC_MODEL QOQ YOY AOA PAC_EXPECTATION TREND_COMPONENT_MODEL
%left EQUAL_EQUAL EXCLAMATION_EQUAL
%left LESS GREATER LESS_EQUAL GREATER_EQUAL
%left PLUS MINUS
@ -1261,7 +1261,6 @@ perfect_foresight_solver_options : o_stack_solve_algo
| o_solve_algo
| o_robust_lin_solve
| o_lmmcp
| o_occbin
| o_pf_tolf
| o_pf_tolx
| o_noprint
@ -2975,7 +2974,6 @@ extended_path_option : o_periods
| o_extended_path_order
| o_hybrid
| o_lmmcp
| o_occbin
;
model_diagnostics : MODEL_DIAGNOSTICS ';'
@ -3698,7 +3696,6 @@ o_period : PERIOD EQUAL INT_NUMBER { driver.option_num("period", $3); };
o_outfile : OUTFILE EQUAL filename { driver.option_str("outfile", $3); };
o_outvars : OUTVARS EQUAL '(' symbol_list ')' { driver.option_symbol_list("outvars"); };
o_lmmcp : LMMCP {driver.option_num("lmmcp.status", "true"); };
o_occbin : OCCBIN {driver.option_num("occbin", "true"); };
o_function : FUNCTION EQUAL filename { driver.option_str("function", $3); };
o_sampling_draws : SAMPLING_DRAWS EQUAL INT_NUMBER { driver.option_num("sampling_draws",$3); };
o_use_shock_groups : USE_SHOCK_GROUPS { driver.option_str("plot_shock_decomp.use_shock_groups","default"); }

View File

@ -666,7 +666,6 @@ DATE -?[0-9]+([ya]|m([1-9]|1[0-2])|q[1-4])
<DYNARE_STATEMENT>posterior_sampler_options {return token::POSTERIOR_SAMPLER_OPTIONS;}
<DYNARE_STATEMENT>silent_optimizer {return token::SILENT_OPTIMIZER;}
<DYNARE_STATEMENT>lmmcp {return token::LMMCP;}
<DYNARE_STATEMENT>occbin {return token::OCCBIN;}
<DYNARE_STATEMENT>additional_optimizer_steps {return token::ADDITIONAL_OPTIMIZER_STEPS;}
<DYNARE_STATEMENT>bartlett_kernel_lag {return token::BARTLETT_KERNEL_LAG; }
<DYNARE_STATEMENT>optimal {

View File

@ -655,7 +655,6 @@ ModFile::transformPass(bool nostrict, bool stochastic, bool compute_xrefs, bool
*/
if (!(mod_file_struct.ramsey_model_present || mod_file_struct.discretionary_policy_present)
&& !(mod_file_struct.bvar_present && dynamic_model.equation_number() == 0)
&& !(mod_file_struct.occbin_option)
&& (dynamic_model.equation_number() != symbol_table.endo_nbr()))
{
cerr << "ERROR: There are " << dynamic_model.equation_number() << " equations but " << symbol_table.endo_nbr() << " endogenous variables!" << endl;

View File

@ -1,5 +1,5 @@
/*
* Copyright © 2006-2020 Dynare Team
* Copyright © 2006-2021 Dynare Team
*
* This file is part of Dynare.
*
@ -127,8 +127,6 @@ public:
bool corr_options_statement_present{false};
//! Whether a Markov Switching DSGE is present
bool ms_dsge_present{false};
//! Whether occbin is present
bool occbin_option{false};
//! Stores the original number of equations in the model_block
int orig_eq_nbr{0};
//! Stores the number of equations added to the Ramsey model