Fix constants in var model (it has to be a vector).

var-models
Stéphane Adjemian (Ryûk) 2021-07-16 19:50:02 +02:00
parent a6add6127b
commit c6a7d56b36
Signed by: stepan
GPG Key ID: 295C1FE89E17EB3C
1 changed files with 1 additions and 1 deletions

View File

@ -536,7 +536,7 @@ VarModelTable::writeOutput(const string &basename, ostream &output) const
<< " a0 = eye(" << lhs.size() << ");" << endl
<< " end" << endl
<< " if nargout>2" << endl
<< " constants = zeros(" << lhs.size() << ");" << endl;
<< " constants = zeros(" << lhs.size() << ",1);" << endl;
for (auto [eqn, expr] : constants.at(name))
{
ar_output << " constants(" << eqn + 1 << ") = ";