source: issm/oecreview/Archive/25834-26739/ISSM-26225-26226.diff

Last change on this file was 26740, checked in by Mathieu Morlighem, 3 years ago

CHG: added 25834-26739

File size: 1.6 KB
  • ../trunk-jpl/src/c/classes/Inputs/TransientInput.cpp

    Cannot display: file marked as a binary type.
    svn:mime-type = application/octet-stream
    Cannot display: file marked as a binary type.
    svn:mime-type = application/octet-stream
    Cannot display: file marked as a binary type.
    svn:mime-type = application/octet-stream
     
    431431        if (reCast<IssmDouble>(nsteps)<time1/dt) nsteps=nsteps+1;
    432432        time1 = nsteps*dt;
    433433
    434         if(cycle && (time<time0 || time>time1)){
     434        if(cycle){
    435435
    436436                /*See by how many intervals we have to offset time*/
    437437                IssmDouble deltat = time1-time0;
     
    440440                int num_intervals = reCast<int,IssmDouble>(fabs(time-time0)/deltat);
    441441
    442442                /*Uncomment following line if you would like to apply a cycle BEFORE the time series starts*/
    443                 //if(time<time0) num_intervals = -num_intervals-1;
     443                if(time<time0) num_intervals = -num_intervals-1;
    444444
    445445                if(fabs(time-time0)/deltat == reCast<IssmDouble>(num_intervals)){
    446446                        /*Hack to make sure we always cover the last value of the series (discussion with Nicole)*/
Note: See TracBrowser for help on using the repository browser.