diff --git a/examples/global-lunar-bombardment/craterlist.in b/examples/global-lunar-bombardment/craterlist.in index 3cbc8f03..7c342404 100644 --- a/examples/global-lunar-bombardment/craterlist.in +++ b/examples/global-lunar-bombardment/craterlist.in @@ -1,28 +1,28 @@ # Dcrat(m) vel(m/s) ang(deg) lat(lunar_deg) yoff(lunar_deg) t(Ga) 2400000 18.3e3 45.0 -53.0 191.0 4.31 -690000 18.3e3 45.0 -21.3 343.4 4.31 +690000 18.3e3 45.0 -21.3 343.4 4.309 334000 18.3e3 45.0 58.9 213.4 4.29 342000 18.3e3 45.0 -32.8 163.8 4.28 -378000 18.3e3 45.0 -81.0 123.0 4.26 -430000 18.3e3 45.0 -16.0 293.0 4.26 +378000 18.3e3 45.0 -81.0 123.0 4.258 +430000 18.3e3 45.0 -16.0 293.0 4.259 878000 18.3e3 45.0 -2.5 86.9 4.26 -600000 18.3e3 45.0 25.1 190.6 4.26 +600000 18.3e3 45.0 25.1 190.6 4.257 361000 18.3e3 45.0 -55.7 314.8 4.24 452000 18.3e3 45.0 13.4 201.8 4.23 -672000 18.3e3 45.0 51.2 237.5 4.23 -312000 18.3e3 45.0 -57.3 163.1 4.23 +672000 18.3e3 45.0 51.2 237.5 4.231 +312000 18.3e3 45.0 -57.3 163.1 4.229 923000 18.3e3 45.0 25.4 18.8 4.22 351000 18.3e3 45.0 34.2 263.0 4.20 885000 18.3e3 45.0 -15.6 35.1 4.17 -460000 18.3e3 45.0 -5.0 291.3 4.14 +460000 18.3e3 45.0 -5.0 291.3 4.141 582000 18.3e3 45.0 18.35 175.2 4.14 -492000 18.3e3 45.0 -36.1 208.3 4.14 -331000 18.3e3 45.0 5.5 141.1 4.13 -321000 18.3e3 45.0 -57.4 135.1 4.13 +492000 18.3e3 45.0 -36.1 208.3 4.139 +331000 18.3e3 45.0 5.5 141.1 4.128 +321000 18.3e3 45.0 -57.4 135.1 4.129 650000 18.3e3 45.0 -49.8 265.4 4.13 417000 18.3e3 45.0 -4.4 202.2 4.11 -816000 18.3e3 45.0 -23.8 320.8 4.09 -582000 18.3e3 45.0 2.0 231.0 4.09 +816000 18.3e3 45.0 -23.8 320.8 4.091 +582000 18.3e3 45.0 2.0 231.0 4.092 640000 18.3e3 45.0 27.3 148.8 4.09 421000 18.3e3 45.0 26.1 147.0 4.089 618000 18.3e3 45.0 57.26 82.0 4.08 @@ -30,4 +30,4 @@ 1321000 18.3e3 45.0 37.0 341.5 3.87 326000 18.3e3 45.0 -74.9 133.5 3.86 937000 18.3e3 45.0 -20.1 265.2 3.81 -252000 18.3e3 45.0 44.8 328.4 3.65 \ No newline at end of file +252000 18.3e3 45.0 44.8 328.4 3.65 diff --git a/examples/global-lunar-bombardment/ctem.in b/examples/global-lunar-bombardment/ctem.in index 4220c91e..acaabd04 100755 --- a/examples/global-lunar-bombardment/ctem.in +++ b/examples/global-lunar-bombardment/ctem.in @@ -16,8 +16,8 @@ realcraterlist craterlist.in ! list of 'real' craters for Quas ! IDL driver in uts -interval 628.0 -numintervals 1 ! Total number of intervals (total time = interval * numintervals) <--when runtype is 'single' +interval 6.280 +numintervals 100 ! Total number of intervals (total time = interval * numintervals) <--when runtype is 'single' restart F ! Restart a previous run impfile NPFextrap.dat ! Impactor SFD rate file (col 1: Dimp (m), col 2: ! impactors > D (m**(-2) y**(-1)) popupconsole F ! Pop up console window every output interval @@ -33,7 +33,7 @@ runtype single ! Run type: options are normal / ! statistical: surface is reset between intervals ! CTEM required inputs -seed 33790 ! Random number generator seed +seed 76535 ! Random number generator seed gridsize 2000 ! Size of grid in pixels numlayers 10 ! Number of perched layers pix 3.08e3 ! Pixel size (m) diff --git a/src/crater/crater_populate.f90 b/src/crater/crater_populate.f90 index 249dbfcf..07852501 100644 --- a/src/crater/crater_populate.f90 +++ b/src/crater/crater_populate.f90 @@ -60,6 +60,7 @@ subroutine crater_populate(user,surf,crater,domain,prod,production_list,vdist,nt real(DP) :: rhpmin = -1.0_DP ! Smallest rim height to diameter ratio real(DP) :: ddmax ! Maximum depth/diameter real(DP) :: ddmin ! Maximum depth/diameter + real(DP) :: timestamp_old integer(I8B) :: icrater ! Loop counters integer(I4B) :: nkilled ! Number of craters killed in a tally step integer(I4B) :: onum ! Number of craters observed in a tally step @@ -138,12 +139,13 @@ subroutine crater_populate(user,surf,crater,domain,prod,production_list,vdist,nt oldpbarpos = 0 do while (icrater < ntotcrat) makecrater = .true. + timestamp_old = real(curyear + real(icrater,kind=DP) / real(ntotcrat,kind=DP) * user%interval,kind=SP) icrater = icrater + 1 crater%timestamp = real(curyear + real(icrater,kind=DP) / real(ntotcrat,kind=DP) * user%interval,kind=SP) pbarpos = nint(real(icrater) / real(ntotcrat) * PBARRES) !if in quasiMC mode: check to see if it's time for a real crater if (user%doquasimc) then - if (crater%timestamp > user%rctime) then + if ((user%rctime > timestamp_old) .and. (user%rctime < crater%timestamp)) then write(*,*) "Real crater at ", crater%timestamp user%testflag = .true. user%testimp = rclist(1, rccount)