File tree 1 file changed +10
-1
lines changed
1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -228,10 +228,19 @@ void DASolver::calcObjStd(Time& runTime)
228
228
is filled at least once, i.e., runTime.timeIndex() >= steps
229
229
*/
230
230
231
- if (!primalObjStdActive_ || runTime . timeIndex () < 1 )
231
+ if (!primalObjStdActive_ )
232
232
{
233
233
return ;
234
234
}
235
+ else if (runTime .timeIndex () < 1 )
236
+ {
237
+ // if primalObjStd is active and timeIndex = 0, we need to reset primalObjStd_ to a large value
238
+ // NOTE: we need to reset primalObjStd_ for each primal call!
239
+ // Because timeIndex == 0, we don't need to compute the objStd, so we can return
240
+ // we will start computing the ojbStd for timeIndex>=1
241
+ primalObjStd_ = 999.0 ;
242
+ return ;
243
+ }
235
244
236
245
label steps = daOptionPtr_ -> getSubDictOption < label > ("primalObjStdTol" , "steps" );
237
246
You can’t perform that action at this time.
0 commit comments