diff --git a/src/modstartup.f90 b/src/modstartup.f90 index 1798beea..a26758af 100644 --- a/src/modstartup.f90 +++ b/src/modstartup.f90 @@ -1192,7 +1192,7 @@ subroutine baseprofs tb(k)=tsurf+lapserate(1)*(zf(k)-zsurf) else j=1 - do while(zf(k)>zmat(j)) + do while(zf(k)>=zmat(j)) j=j+1 end do tb(k)=tmat(j-1)+lapserate(j)*(zf(k)-zmat(j-1))