diff --git a/tests/Makefile.am b/tests/Makefile.am index f6db78ee2..9a055bfd0 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -97,10 +97,6 @@ MODFILES = \ gsa/ls2003.mod \ gsa/cod_ML_morris/cod_ML_morris.mod \ gsa/morris/nk_est.mod \ - simul/ramst.mod \ - simul/ramst_a.mod \ - simul/ramst_mshocks.mod \ - simul/ramst_mshocks_vec.mod \ on-the-fly/ex1.mod \ on-the-fly/ex2.mod \ on-the-fly/ex3.mod \ @@ -110,6 +106,7 @@ MODFILES = \ equation_tags/example1_with_tags.mod \ equation_tags/ramst_static_tag.mod \ equation_tags/ramst_static_tag_block.mod \ + stochastic_simulations/example1.mod \ stochastic_simulations/example1_irf_shocks.mod \ stochastic_simulations/example1long.mod \ stochastic_simulations/example2long.mod \ @@ -164,8 +161,6 @@ MODFILES = \ stat_functions/ramst_normcdf_and_friends_use_dll.mod \ stat_functions/ramst_normcdf_and_friends_bytecode.mod \ stat_functions/example1_abs_sign.mod \ - simul/predetermined_variables.mod \ - simul/histval_det.mod \ preprocessor_checks/comments.mod \ preprocessor_checks/example1_mlv.mod \ preprocessor_checks/ramst_model_edit.mod \ @@ -269,13 +264,6 @@ MODFILES = \ identification/forward_looking/forward_looking_empty_ghx.mod \ identification/forward_looking/forward_looking_varobs_x.mod \ model_diagnostics/example2_block_model_diag.mod \ - simul/example1.mod \ - simul/ramst_vec.mod \ - simul/Solow_no_varexo.mod \ - simul/simul_ZLB_purely_forward.mod \ - simul/simul_ZLB_purely_forward_no_solution.mod \ - simul/Irreversible_investment.mod \ - simul/linear_state_space_arma.mod \ perfect_foresight/initval_endval_blocks/initval_endval_test.mod \ perfect_foresight/initval_endval_blocks/histval_initval_test.mod \ conditional_forecasts/1/fs2000_cal.mod \ @@ -361,6 +349,18 @@ MODFILES = \ stochastic-backward-models/solow_cd.mod \ stochastic-backward-models/solow_ces.mod \ stochastic-backward-models/solow_cd_with_steadystate.mod \ + deterministic_simulations/ramst.mod \ + deterministic_simulations/ramst_a.mod \ + deterministic_simulations/ramst_mshocks.mod \ + deterministic_simulations/ramst_mshocks_vec.mod \ + deterministic_simulations/predetermined_variables.mod \ + deterministic_simulations/histval_det.mod \ + deterministic_simulations/ramst_vec.mod \ + deterministic_simulations/Solow_no_varexo.mod \ + deterministic_simulations/simul_ZLB_purely_forward.mod \ + deterministic_simulations/simul_ZLB_purely_forward_no_solution.mod \ + deterministic_simulations/Irreversible_investment.mod \ + deterministic_simulations/linear_state_space_arma.mod \ deterministic_simulations/purely_forward/ar1.mod \ deterministic_simulations/purely_forward/nk.mod \ deterministic_simulations/purely_backward/ar1.mod \ @@ -874,8 +874,8 @@ deterministic_simulations/multiple_lead_lags/sim_lead_lag_aux_vars.o.trs: determ deterministic_simulations/multiple_lead_lags/sim_lead_lag.m.trs: deterministic_simulations/multiple_lead_lags/sim_base.m.trs deterministic_simulations/multiple_lead_lags/sim_lead_lag_aux_vars.m.trs deterministic_simulations/multiple_lead_lags/sim_lead_lag.o.trs: deterministic_simulations/multiple_lead_lags/sim_base.o.trs deterministic_simulations/multiple_lead_lags/sim_lead_lag_aux_vars.o.trs -deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.m.trs: simul/ramst.m.trs -deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.o.trs: simul/ramst.o.trs +deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.m.trs: deterministic_simulations/ramst.m.trs +deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.o.trs: deterministic_simulations/ramst.o.trs loglinear/example4_loglinear.m.trs: loglinear/example4_exp.m.trs loglinear/example4_loglinear.o.trs: loglinear/example4_exp.o.trs @@ -989,11 +989,11 @@ particle/local_it_k_test_parallel.o.trs: particle/first_spec.o.trs pruning/AS_pruned_state_space_red_shock.m.trs: pruning/AnSchorfheide_pruned_state_space.m.trs pruning/AS_pruned_state_space_red_shock.o.trs: pruning/AnSchorfheide_pruned_state_space.o.trs -preprocessor_checks/ramst_model_edit.m.trs: simul/ramst.m.trs -preprocessor_checks/ramst_model_edit.o.trs: simul/ramst.o.trs +preprocessor_checks/ramst_model_edit.m.trs: deterministic_simulations/ramst.m.trs +preprocessor_checks/ramst_model_edit.o.trs: deterministic_simulations/ramst.o.trs -log_transform/ramst.m.trs: simul/ramst.m.trs -log_transform/ramst.o.trs: simul/ramst.o.trs +log_transform/ramst.m.trs: deterministic_simulations/ramst.m.trs +log_transform/ramst.o.trs: deterministic_simulations/ramst.o.trs model-inversion/nk-1/invert.m.trs: model-inversion/nk-1/simulate.m.trs model-inversion/nk-1/invert.o.trs: model-inversion/nk-1/simulate.o.trs @@ -1030,8 +1030,8 @@ solve_algo_12_14/purely_forward_14.o.trs: solve_algo_12_14/purely_forward_refere estimation/conditional-likelihood/1/fs2000_estimation_conditional.m.trs: estimation/conditional-likelihood/1/fs2000_estimation_exact.m.trs estimation/conditional-likelihood/1/fs2000_estimation_conditional.o.trs: estimation/conditional-likelihood/1/fs2000_estimation_exact.o.trs -deprecated/ramst.m.trs: simul/ramst.m.trs -deprecated/ramst.o.trs: simul/ramst.o.trs +deprecated/ramst.m.trs: deterministic_simulations/ramst.m.trs +deprecated/ramst.o.trs: deterministic_simulations/ramst.o.trs observation_trends_and_prefiltering/MCMC: m/observation_trends_and_prefiltering/MCMC o/observation_trends_and_prefiltering/MCMC @@ -1126,10 +1126,6 @@ deterministic_simulations: m/deterministic_simulations o/deterministic_simulatio m/deterministic_simulations: $(patsubst %.mod, %.m.trs, $(filter deterministic_simulations/%.mod, $(MODFILES))) o/deterministic_simulations: $(patsubst %.mod, %.o.trs, $(filter deterministic_simulations/%.mod, $(MODFILES))) -simul: m/simul o/simul -m/simul: $(patsubst %.mod, %.m.trs, $(filter simul/%.mod, $(MODFILES))) -o/simul: $(patsubst %.mod, %.o.trs, $(filter simul/%.mod, $(MODFILES))) - ep: m/ep o/ep m/ep: $(patsubst %.mod, %.m.trs, $(filter ep/%.mod, $(MODFILES))) o/ep: $(patsubst %.mod, %.o.trs, $(filter ep/%.mod, $(MODFILES))) diff --git a/tests/deprecated/ramst.mod b/tests/deprecated/ramst.mod index 713f3a86b..cd1d4b404 100644 --- a/tests/deprecated/ramst.mod +++ b/tests/deprecated/ramst.mod @@ -34,7 +34,7 @@ end; simul(periods=200); -benchmark = load('../simul/ramst/Output/ramst_results.mat'); +benchmark = load('../deterministic_simulations/ramst/Output/ramst_results.mat'); if max(abs(benchmark.oo_.endo_simul-oo_.endo_simul)) > 1e5 error('The results of simul are inconsistent with perfect_foresight_setup+perfect_foresight_solver'); diff --git a/tests/simul/Irreversible_investment.mod b/tests/deterministic_simulations/Irreversible_investment.mod similarity index 100% rename from tests/simul/Irreversible_investment.mod rename to tests/deterministic_simulations/Irreversible_investment.mod diff --git a/tests/simul/Solow_no_varexo.mod b/tests/deterministic_simulations/Solow_no_varexo.mod similarity index 100% rename from tests/simul/Solow_no_varexo.mod rename to tests/deterministic_simulations/Solow_no_varexo.mod diff --git a/tests/simul/histval_det.mod b/tests/deterministic_simulations/histval_det.mod similarity index 100% rename from tests/simul/histval_det.mod rename to tests/deterministic_simulations/histval_det.mod diff --git a/tests/simul/linear_state_space_arma.mod b/tests/deterministic_simulations/linear_state_space_arma.mod similarity index 100% rename from tests/simul/linear_state_space_arma.mod rename to tests/deterministic_simulations/linear_state_space_arma.mod diff --git a/tests/deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.mod b/tests/deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.mod index 76aa3c147..61f92c4f5 100644 --- a/tests/deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.mod +++ b/tests/deterministic_simulations/multiple_lead_lags/ramst_augmented_histval.mod @@ -71,7 +71,7 @@ if max(abs(junk(M_.maximum_lag+1:end)-oo_.endo_simul(strmatch('y_backward',M_.en error('Solution of purely backwards model not correct') end -ramst_results=load('../../simul/ramst/Output/ramst_results.mat'); +ramst_results=load('../../deterministic_simulations/ramst/Output/ramst_results.mat'); if max(abs(ramst_results.oo_.endo_simul(strmatch('k',ramst_results.M_.endo_names,'exact'),1:end-M_.maximum_lead)-oo_.endo_simul(strmatch('k',M_.endo_names,'exact'),1:end-M_.maximum_lead)))>1e-10 error('Solution of forward part of the model not correct') end diff --git a/tests/simul/predetermined_variables.mod b/tests/deterministic_simulations/predetermined_variables.mod similarity index 100% rename from tests/simul/predetermined_variables.mod rename to tests/deterministic_simulations/predetermined_variables.mod diff --git a/tests/simul/ramst.mod b/tests/deterministic_simulations/ramst.mod similarity index 100% rename from tests/simul/ramst.mod rename to tests/deterministic_simulations/ramst.mod diff --git a/tests/simul/ramst_a.mod b/tests/deterministic_simulations/ramst_a.mod similarity index 100% rename from tests/simul/ramst_a.mod rename to tests/deterministic_simulations/ramst_a.mod diff --git a/tests/simul/ramst_mshocks.mod b/tests/deterministic_simulations/ramst_mshocks.mod similarity index 100% rename from tests/simul/ramst_mshocks.mod rename to tests/deterministic_simulations/ramst_mshocks.mod diff --git a/tests/simul/ramst_mshocks_vec.mod b/tests/deterministic_simulations/ramst_mshocks_vec.mod similarity index 100% rename from tests/simul/ramst_mshocks_vec.mod rename to tests/deterministic_simulations/ramst_mshocks_vec.mod diff --git a/tests/simul/ramst_vec.mod b/tests/deterministic_simulations/ramst_vec.mod similarity index 100% rename from tests/simul/ramst_vec.mod rename to tests/deterministic_simulations/ramst_vec.mod diff --git a/tests/simul/simul_ZLB_purely_forward.mod b/tests/deterministic_simulations/simul_ZLB_purely_forward.mod similarity index 100% rename from tests/simul/simul_ZLB_purely_forward.mod rename to tests/deterministic_simulations/simul_ZLB_purely_forward.mod diff --git a/tests/simul/simul_ZLB_purely_forward_no_solution.mod b/tests/deterministic_simulations/simul_ZLB_purely_forward_no_solution.mod similarity index 100% rename from tests/simul/simul_ZLB_purely_forward_no_solution.mod rename to tests/deterministic_simulations/simul_ZLB_purely_forward_no_solution.mod diff --git a/tests/log_transform/ramst.mod b/tests/log_transform/ramst.mod index a99501158..edc86f1b5 100644 --- a/tests/log_transform/ramst.mod +++ b/tests/log_transform/ramst.mod @@ -45,7 +45,7 @@ if max(abs(oo_.endo_simul(idx_log_c, :) - log(oo_.endo_simul(idx_c, :)))) > 1e-7 error('Transformation not correctly performed') end -S = load('../simul/ramst/Output/ramst_results.mat'); +S = load('../deterministic_simulations/ramst/Output/ramst_results.mat'); if max(abs(oo_.endo_simul(idx_c, :) - S.oo_.endo_simul(idx_c, :))) > 1e-7 error('Result differs from non-transformed model') end diff --git a/tests/preprocessor_checks/ramst_model_edit.mod b/tests/preprocessor_checks/ramst_model_edit.mod index 1bbfc96ec..dd103628a 100644 --- a/tests/preprocessor_checks/ramst_model_edit.mod +++ b/tests/preprocessor_checks/ramst_model_edit.mod @@ -56,7 +56,7 @@ end; perfect_foresight_setup(periods=200); perfect_foresight_solver; -S = load('../simul/ramst/Output/ramst_results.mat'); +S = load('../deterministic_simulations/ramst/Output/ramst_results.mat'); if any(size(oo_.endo_simul) ~= size(S.oo_.endo_simul)) || any(any(abs(oo_.endo_simul - S.oo_.endo_simul) > 1e-10)) error('Model editing failure') end diff --git a/tests/simul/ramst2.mod b/tests/simul/ramst2.mod deleted file mode 100644 index e74d3aef1..000000000 --- a/tests/simul/ramst2.mod +++ /dev/null @@ -1,46 +0,0 @@ -var c k dc s; -varexo x; - -parameters alph gam delt bet aa; -alph=0.5; -gam=0.5; -delt=0.02; -bet=0.05; -aa=0.5; - - -model; -c + k - aa*x*k(-1)^alph - (1-delt)*k(-1); -c^(-gam) - (1+bet)^(-1)*(aa*alph*x(+1)*k^(alph-1) + 1 - delt)*c(+1)^(-gam); -dc = c - c(-1); -s = (dc>=0)-(dc<0); -end; - -initval; -x = 1; -k = ((delt+bet)/(1.0*aa*alph))^(1/(alph-1)); -c = aa*k^alph-delt*k; -dc = 0; -s = 1; -end; - -steady; - -check; - -shocks; -var x; -periods 1; -values 1.2; -end; - -perfect_foresight_setup(periods=200); -perfect_foresight_solver; - -dynasave('myfile') c x k; -dynatype('myfile1.txt') c x k; - -rplot c; -rplot k; -rplot dc; -rplot s; diff --git a/tests/simul/example1.mod b/tests/stochastic_simulations/example1.mod similarity index 100% rename from tests/simul/example1.mod rename to tests/stochastic_simulations/example1.mod