local mod = 1000000007
local mfl = math.floor
local function badd(x, y)
  return (x + y) % mod
end
local function bmul(x, y)
  local x0, y0 = x % 31623, y % 31623
  local x1, y1 = mfl(x / 31623), mfl(y / 31623)
  return (x1 * y1 * 14122 + (x1 * y0 + x0 * y1) * 31623 + x0 * y0) % mod
end

local mfl, msq = math.floor, math.sqrt
local function solve(n, k)
  local sq = 1 + mfl(msq(n))
  if n < sq * sq then sq = sq - 1 end
  local stage = {}
  for i = 1, sq do
    stage[i] = 1
  end
  local sum = sq
  if sq * (sq + 1) <= n then
    table.insert(stage, mfl(n / sq) - sum)
    sum = sum + stage[sq + 1]
  end
  for i = sq - 1, 1, -1 do
    table.insert(stage, mfl(n / i) - sum)
    sum = sum + stage[#stage]
  end
  local dp1, dp2 = {}, {}
  for i = 1, #stage do
    dp1[i] = stage[i]
  end
  for ik = 2, k do
    local src = ik % 2 == 0 and dp1 or dp2
    local dst = ik % 2 == 0 and dp2 or dp1
    local tsum = 0
    for i = #stage, 1, -1 do
      tsum = badd(tsum, src[#stage - i + 1])
      dst[i] = bmul(stage[i], tsum)
    end
  end
    local ret = 0
  if k % 2 == 0 then
    for i = 1, #stage do
      ret = badd(ret, dp2[i])
    end
  else
    for i = 1, #stage do
      ret = badd(ret, dp1[i])
    end
  end
  return ret
end

local n, k = io.read("*n", "*n")
print(solve(n, k))
