Skip to content
This repository was archived by the owner on May 18, 2019. It is now read-only.

Commit 891db48

Browse files
ptaeuberOpenModelica-Hudson
authored andcommitted
Always initialize lambda with 0
Addition to 5cf25d1 Belonging to [master]: - #2173
1 parent df6431c commit 891db48

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

SimulationRuntime/c/simulation/solver/nonlinearSolverHomotopy.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2154,6 +2154,10 @@ int solveHomotopy(DATA *data, threadData_t *threadData, int sysNumber)
21542154
debugVectorDouble(LOG_NLS_V,"System extrapolation", solverData->xStart, solverData->n);
21552155
}
21562156
vecCopy(solverData->n, solverData->xStart, solverData->x0);
2157+
// Initialize lambda variable with 0
2158+
solverData->x0[solverData->n] = 0.0;
2159+
solverData->x[solverData->n] = 0.0;
2160+
solverData->x1[solverData->n] = 0.0;
21572161
/* Use actual working point for scaling */
21582162
for (i=0;i<solverData->n;i++){
21592163
solverData->xScaling[i] = fmax(systemData->nominal[i],fabs(solverData->x0[i]));

0 commit comments

Comments
 (0)