Definition at line 441 of file makeschedule.cc.
References i.
Referenced by main().
443 for (
size_t i=1;
i<obs.size()-1;
i++)
445 if (obs[
i].duration()>=5./24/60)
448 if (obs[
i-1].name==
"SLEEP" && obs[
i+1].name==
"SLEEP")
451 cout <<
"Mini source [" << obs[
i].name <<
"] detected < 5min" << endl;
453 if (obs[
i-1].name==
"SLEEP" && obs[
i+1].name==
"SLEEP")
455 obs[
i-1].end = obs[
i+2].begin;
457 obs.erase(obs.begin()+
i+1);
458 obs.erase(obs.begin()+
i);
462 cout <<
"Combined two surrounding sleep into one" << endl;
467 if (obs[
i-1].name==
"SLEEP")
469 obs[
i-1].end = obs[
i+1].begin;
470 obs.erase(obs.begin()+
i);
473 cout <<
"Extended previous sleep" << endl;
478 if (obs[
i+1].name==
"SLEEP")
480 obs[
i+1].begin = obs[
i-1].end;
481 obs.erase(obs.begin()+
i);
483 cout <<
"Extended following sleep" << endl;