Skip to content

Commit

Permalink
fix in cpp template for allocating Jacobian
Browse files Browse the repository at this point in the history
  • Loading branch information
niklwors committed Aug 25, 2015
1 parent e47e061 commit 52a9c93
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Compiler/Template/CodegenCpp.tpl
Expand Up @@ -12403,9 +12403,9 @@ template initialAnalyticJacobians(Integer indexJacobian, list<JacobianColumn> ja
let type = getConfigString(MATRIX_FORMAT)
let matrixinit = match type
case ("dense") then
'ublas::zero_matrix<double> (<%index_%>,<%indexColumn%>)'
'ublas::zero_matrix<double> (<%indexColumn%>,<%index_%>)'
case ("sparse") then
'<%index_%>,<%indexColumn%>,<%sp_size_index%>'
'<%indexColumn%>,<%index_%>,<%sp_size_index%>'
else "A matrix type is not supported"
end match
<<
Expand Down
2 changes: 2 additions & 0 deletions SimulationRuntime/cpp/Solver/CVode/CVode.cpp
Expand Up @@ -585,6 +585,8 @@ void Cvode::CVodeCore()
// Der Eventzeitpunkt kann auf der Endzeit liegen (Time-Events). In diesem Fall wird der Solver beendet, da CVode sonst eine interne Warnung schmeißt
if (_tCurrent == _tEnd)
_cv_rt = CV_TSTOP_RETURN;
if(_continuous_system->stepCompleted(_tCurrent))
_solverStatus = DONE;
}

// Zähler für die Anzahl der ausgegebenen Schritte erhöhen
Expand Down

0 comments on commit 52a9c93

Please sign in to comment.