diff --git a/fdelmodc/demo/pars b/fdelmodc/demo/pars deleted file mode 100644 index e94ff542cafef10cb45d02f42ea2f70e77f69778..0000000000000000000000000000000000000000 --- a/fdelmodc/demo/pars +++ /dev/null @@ -1,5 +0,0 @@ -file_cp=syncl_cp.su ischeme=1 file_den=syncl_ro.su file_src=wave.su \ -file_rcv=shot_xsrc-200.su src_type=7 src_orient=1 \ -src_injectionrate=1 rec_type_vz=0 rec_type_p=1 rec_int_vz=2 \ -dtrcv=0.004 rec_delay=0.1 verbose=2 tmod=4.10 dxrcv=10.0 xrcv1=-2250 \ -xrcv2=2250 zrcv1=0 zrcv2=0 xsrc=0 zsrc=1150 ntaper=200 left=2 right=2 top=1 bottom=2 diff --git a/fdelmodc/fdelmodc.c b/fdelmodc/fdelmodc.c index 691f8d1409e33a063a4ccdd4b3f7c6b9ac0c24f1..899f78c67894af737539e63a513f1061351f4fee 100644 --- a/fdelmodc/fdelmodc.c +++ b/fdelmodc/fdelmodc.c @@ -90,7 +90,7 @@ char *sdoc[] = { " file_beam=beam.su . base name for beam fields ", " dx= ............... read from model file: if dx==0 then dx= can be used to set it", " dz= ............... read from model file: if dz==0 then dz= can be used to set it", -" dt= ............... read from file_src: if dt==0 then dt= can be used to set it", +" dt= ............... read from file_src: if dt is set it will interpolate file_src to dt sampling", "" , " OPTIONAL PARAMETERS:", " ischeme=3 ......... 1=acoustic, 2=visco-acoustic 3=elastic, 4=visco-elastic", diff --git a/fdelmodc/writeRec.c b/fdelmodc/writeRec.c index 877bbe940f02dd23d9a4f244d589cedcad6ef8fe..167e5f796ca7d4261ff8912a0a0d54eb68710ec9 100644 --- a/fdelmodc/writeRec.c +++ b/fdelmodc/writeRec.c @@ -85,7 +85,12 @@ int writeRec(recPar rec, modPar mod, bndPar bnd, wavPar wav, int ixsrc, int izsr hdr.ns = nsam; hdr.trwf = rec.n; hdr.ntr = (ishot+1)*rec.n; - hdr.f1 = 0.0; + if (mod.grid_dir) { /* reverse time modeling */ + hdr.f1 = (-mod.nt+1)*mod.dt; + } + else { + hdr.f1 = 0.0; + } hdr.d1 = mod.dt*rec.skipdt; hdr.d2 = (rec.x[1]-rec.x[0])*mod.dx; hdr.f2 = mod.x0+rec.x[0]*mod.dx; diff --git a/fdelmodc/writeSnapTimes.c b/fdelmodc/writeSnapTimes.c index 37904962cc7e7043deb72c871ccf6be00690e978..2b68a698c0d67fa15af414e96a7d53b781952923 100644 --- a/fdelmodc/writeSnapTimes.c +++ b/fdelmodc/writeSnapTimes.c @@ -37,7 +37,7 @@ int writeSnapTimes(modPar mod, snaPar sna, bndPar bnd, int ixsrc, int izsrc, int static int first=1; int n1, ibndx, ibndz, ixs, izs, ize, i, j; int ix, iz, ix2; - float *snap, sdx; + float *snap, sdx, stime; segy hdr; if (sna.nsnap==0) return 0; @@ -65,7 +65,10 @@ int writeSnapTimes(modPar mod, snaPar sna, bndPar bnd, int ixsrc, int izsrc, int (itime <= sna.delay+(sna.nsnap-1)*sna.skipdt) ) { isnap = NINT((itime-sna.delay)/sna.skipdt); - if (verbose) vmess("Writing snapshot(%d) at time=%.4f", isnap+1, itime*mod.dt); + + if (mod.grid_dir) stime = (-mod.nt+1+itime)*mod.dt; /* reverse time modeling */ + else stime = itime*mod.dt; + if (verbose) vmess("Writing snapshot(%d) at time=%.4f", isnap+1, stime); if (first) { append=0;