Fix half-symbol offset in jt65sim.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6187 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Steven Franke 2015-11-26 13:41:07 +00:00
parent 7f9024bf62
commit c2ed418262
2 changed files with 2 additions and 2 deletions

View File

@ -45,7 +45,7 @@ real function fchisq65(cx,npts,fsample,nflip,a,ccfmax,dtmax)
j=nsps+(i-1)*nsps/16 !steps by 8 samples (1/16 of a symbol)
k=j-nsps
ss(i)=0.
if(k.ge.0) then
if(k.ge.0 .and. j.le.npts) then
z=csx(j)-csx(k) ! difference over span of 128 pts
ss(i)=fac*(real(z)**2 + aimag(z)**2)
endif

View File

@ -111,7 +111,7 @@ program jt65sim
k=12000 + xdt*12000 !Start audio at t = xdt + 1.0 s
isym0=-99
do i=1,npts !Add this signal into cdat()
isym=nint(i/sps)+1
isym=floor(i/sps)+1
if(isym.gt.nsym) exit
if(isym.ne.isym0) then
freq=f0 + itone(isym)*baud*mode65