anchor.diff:          elseif( a(cindex)>=table%tbval(ccol, crow+dd-1) ) then
              outa(:) = table%tbval(1:ccol-1, crow+dd-1)
           else
  -          do i=crow, crow+dd-1
  +          do i=crow, crow+dd-2
               if( a(cindex)>=table%tbval(ccol, i) .and. a(cindex)<table%tbval(ccol, i+1) ) then 
                 lambda = (a(cindex)-table%tbval(ccol, i))/(table%tbval(ccol, i+1)-table%tbval(ccol, i))
                 outa(:) = (1.d0-lambda)*table%tbval(1:ccol-1, i)+ lambda* table%tbval(1:ccol-1, i+1) 
  
positive.code:               dd = ddd
                call GetTableGrad( a, cindex, table, dd, crow, outa )	
          else
            do i=crow, crow+dd-1, ddd
              if( a(cindex)==table%tbval(ccol, i) ) then
                crow = i
                cindex = cindex+1
  
negative.code: 
        ddd = dd / table%tbindex(cindex)
        ccol = table%tbcol-cindex+1
        nval = size(outa)
  
        if( ddd==1 ) then
          if( a(cindex)<table%tbval(ccol, crow) ) then
  