diff --git a/DynareMain.cc b/DynareMain.cc
index 4d6336f8df3d3c9ff33ed142a5b44c5229ab6045..ead3b74a80bfbb24837c5dd75d6d99a902e8cf2e 100644
--- a/DynareMain.cc
+++ b/DynareMain.cc
@@ -41,7 +41,7 @@ void main2(stringstream &in, string &basename, bool debug, bool clear_all, bool
            bool nograph, bool nointeractive, bool parallel, ConfigFile &config_file,
            WarningConsolidation &warnings_arg, bool nostrict, bool check_model_changes,
            bool minimal_workspace, bool compute_xrefs, FileOutputType output_mode,
-           LanguageOutputType lang, bool sec_order_param_deriv
+           LanguageOutputType lang
 #if defined(_WIN32) || defined(__CYGWIN32__)
            , bool cygwin, bool msvc
 #endif
@@ -57,7 +57,6 @@ usage()
   cerr << "Dynare usage: dynare mod_file [debug] [noclearall] [onlyclearglobals] [savemacro[=macro_file]] [onlymacro] [nolinemacro] [notmpterms] [nolog] [warn_uninit]"
        << " [console] [nograph] [nointeractive] [parallel[=cluster_name]] [conffile=parallel_config_path_and_filename] [parallel_slave_open_mode] [parallel_test]"
        << " [-D<variable>[=<value>]] [-I/path] [nostrict] [fast] [minimal_workspace] [compute_xrefs] [output=dynamic|first|second|third] [language=C|C++|julia]"
-       << " [no_2nd_order_params_derivs]"
 #if defined(_WIN32) || defined(__CYGWIN32__)
        << " [cygwin] [msvc]"
 #endif
@@ -91,7 +90,6 @@ main(int argc, char **argv)
   bool no_line_macro = false;
   bool no_log = false;
   bool no_warn = false;
-  bool sec_order_param_deriv = true;
   bool warn_uninit = false;
   bool console = false;
   bool nograph = false;
@@ -121,8 +119,6 @@ main(int argc, char **argv)
         debug = true;
       else if (!strcmp(argv[arg], "noclearall"))
         clear_all = false;
-      else if (!strcmp(argv[arg], "no_2nd_order_params_derivs"))
-        sec_order_param_deriv = false;
       else if (!strcmp(argv[arg], "onlyclearglobals"))
         {
           clear_all = false;
@@ -322,7 +318,7 @@ main(int argc, char **argv)
   main2(macro_output, basename, debug, clear_all, clear_global,
         no_tmp_terms, no_log, no_warn, warn_uninit, console, nograph, nointeractive,
         parallel, config_file, warnings, nostrict, check_model_changes, minimal_workspace,
-        compute_xrefs, output_mode, language, sec_order_param_deriv
+        compute_xrefs, output_mode, language
 #if defined(_WIN32) || defined(__CYGWIN32__)
         , cygwin, msvc
 #endif
diff --git a/DynareMain2.cc b/DynareMain2.cc
index 386f939cda1ff08eb407768f7bcd7646e3b6f870..4bead8354296391277758dcda7651b1e32fa78cd 100644
--- a/DynareMain2.cc
+++ b/DynareMain2.cc
@@ -30,7 +30,7 @@ main2(stringstream &in, string &basename, bool debug, bool clear_all, bool clear
       bool nograph, bool nointeractive, bool parallel, ConfigFile &config_file,
       WarningConsolidation &warnings, bool nostrict, bool check_model_changes,
       bool minimal_workspace, bool compute_xrefs, FileOutputType output_mode,
-      LanguageOutputType language, bool sec_order_param_deriv
+      LanguageOutputType language
 #if defined(_WIN32) || defined(__CYGWIN32__)
       , bool cygwin, bool msvc
 #endif
@@ -51,7 +51,7 @@ main2(stringstream &in, string &basename, bool debug, bool clear_all, bool clear
   mod_file->evalAllExpressions(warn_uninit);
 
   // Do computations
-  mod_file->computingPass(no_tmp_terms, output_mode, compute_xrefs, sec_order_param_deriv);
+  mod_file->computingPass(no_tmp_terms, output_mode, compute_xrefs);
 
   // Write outputs
   if (output_mode != none)
diff --git a/ModFile.cc b/ModFile.cc
index 1a62e8004811663313adce46603d94cc29e71beb..972a5985bf24c9af7db50e8062aaf5b719350b36 100644
--- a/ModFile.cc
+++ b/ModFile.cc
@@ -469,7 +469,7 @@ ModFile::transformPass(bool nostrict)
 }
 
 void
-ModFile::computingPass(bool no_tmp_terms, FileOutputType output, bool compute_xrefs, bool sec_order_param_deriv)
+ModFile::computingPass(bool no_tmp_terms, FileOutputType output, bool compute_xrefs)
 {
   // Mod file may have no equation (for example in a standalone BVAR estimation)
   if (dynamic_model.equation_number() > 0)
@@ -490,10 +490,10 @@ ModFile::computingPass(bool no_tmp_terms, FileOutputType output, bool compute_xr
 	  const bool static_hessian = mod_file_struct.identification_present
 	    || mod_file_struct.estimation_analytic_derivation;
           FileOutputType paramsDerivatives = none;
+          if (mod_file_struct.identification_present)
+              paramsDerivatives = first;
           if (mod_file_struct.estimation_analytic_derivation)
-            paramsDerivatives = third;
-          if (mod_file_struct.identification_present || !sec_order_param_deriv)
-            paramsDerivatives = first;
+              paramsDerivatives = third;
 	  static_model.computingPass(global_eval_context, no_tmp_terms, static_hessian,
 				     false, paramsDerivatives, block, byte_code);
 	}
@@ -527,10 +527,10 @@ ModFile::computingPass(bool no_tmp_terms, FileOutputType output, bool compute_xr
 		    || mod_file_struct.estimation_analytic_derivation
 		    || output == third;
                   FileOutputType paramsDerivatives = none;
+                  if (mod_file_struct.identification_present)
+                      paramsDerivatives = first;
                   if (mod_file_struct.estimation_analytic_derivation)
-                    paramsDerivatives = third;
-                  if (mod_file_struct.identification_present || !sec_order_param_deriv)
-                    paramsDerivatives = first;
+                      paramsDerivatives = third;
 		  dynamic_model.computingPass(true, hessian, thirdDerivatives, paramsDerivatives, global_eval_context, no_tmp_terms, block, use_dll, byte_code, compute_xrefs);
 		}
 	    }
diff --git a/ModFile.hh b/ModFile.hh
index 8dcb91409c261e934ec1aad9204370ed7b2e3250..c720b45e9c56c1aae96d047c35cac8b4110f6b7f 100644
--- a/ModFile.hh
+++ b/ModFile.hh
@@ -132,8 +132,7 @@ public:
   //! Execute computations
   /*! \param no_tmp_terms if true, no temporary terms will be computed in the static and dynamic files */
   /*! \param compute_xrefs if true, equation cross references will be computed */
-  /*! \param sec_order_param_deriv if true, compute second order param derivatives*/
-  void computingPass(bool no_tmp_terms, FileOutputType output, bool compute_xrefs, bool sec_order_param_deriv);
+  void computingPass(bool no_tmp_terms, FileOutputType output, bool compute_xrefs);
   //! Writes Matlab/Octave output files
   /*!
     \param basename The base name used for writing output files. Should be the name of the mod file without its extension