Save times are defined by either tsave(isavet(ifile),ifile) or itsave(isaveit(ifile),ifile) or dtsave(ifile) or ditsave(ifile) tsavestart(ifile) determines first start time. This only affects read out times determined by dtsave(ifiles). Other conditions may be included.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer | :: | ifile |
logical function timetosave(ifile) use mod_global_parameters integer:: ifile logical:: oksave oksave=.false. if (it==itsave(isaveit(ifile),ifile)) then oksave=.true. isaveit(ifile)=isaveit(ifile)+1 end if if (it==itsavelast(ifile)+ditsave(ifile)) oksave=.true. if (global_time>=tsave(isavet(ifile),& ifile).and.global_time-dt<tsave(isavet(ifile),ifile)) then oksave=.true. isavet(ifile)=isavet(ifile)+1 end if if(global_time>=tsavestart(ifile)-smalldouble)then if (global_time>=tsavelast(ifile)+dtsave(ifile)-smalldouble)then oksave=.true. n_saves(ifile) = n_saves(ifile) + 1 endif endif if (oksave) then tsavelast(ifile) =global_time itsavelast(ifile)=it end if timetosave=oksave return end function timetosave