write names of epilogue variables
parent
3694fc40b3
commit
41d38551e5
|
@ -1011,6 +1011,8 @@ ModFile::writeOutputFiles(const string &basename, bool clear_all, bool clear_glo
|
|||
<< "M_.ramsey_eq_nbr = " << mod_file_struct.ramsey_eq_nbr << ";" << endl
|
||||
<< "M_.set_auxiliary_variables = exist(['./+' M_.fname '/set_auxiliary_variables.m'], 'file') == 2;" << endl;
|
||||
|
||||
epilogue.writeOutput(mOutputFile);
|
||||
|
||||
if (dynamic_model.equation_number() > 0)
|
||||
{
|
||||
if (linear_decomposition)
|
||||
|
|
|
@ -415,3 +415,16 @@ Epilogue::writeEpilogueFile(const string &basename) const
|
|||
output << "end" << endl;
|
||||
output.close();
|
||||
}
|
||||
|
||||
void
|
||||
Epilogue::writeOutput(ostream &output) const
|
||||
{
|
||||
if (def_table.empty())
|
||||
return;
|
||||
|
||||
int idx = 1;
|
||||
output << "M_.epilogue_names = cell(" << def_table.size() << ",1);" << endl;
|
||||
for (const auto & [symb_id, expr] : def_table)
|
||||
output << "M_.epilogue_names{" << idx++ << "} = '"
|
||||
<< symbol_table.getName(symb_id) << "';" << endl;
|
||||
}
|
||||
|
|
|
@ -95,6 +95,9 @@ public:
|
|||
|
||||
//! Write the steady state file
|
||||
void writeEpilogueFile(const string &basename) const;
|
||||
|
||||
//! Write Output
|
||||
void writeOutput(ostream &output) const;
|
||||
};
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue