In reference to the calculation above I can offer some Maple code that confirms the correctness of the result (answer is $\tau(k)$). This algorithm is very fast and does not iterate over all permutations but only over cycle decompositions, which are treated according to their multiplicity in $S_n$. This makes it possible to compute with values like $n=24,$ which would otherwise be out of reach ($24!$ has $23$ digits).
Here is some sample output:
> seq(v(n, 1), n=1..24);
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
> seq(v(n, 6), n=1..24);
1, 2, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4
> seq(v(n, 12), n=1..24);
1, 2, 3, 4, 4, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6
> seq(v(n, 16), n=1..24);
1, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5
> seq(v(n, 24), n=1..24);
1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8
This is the code:
with(group);
pet_cycleind_vrec :=
proc(n)
local p, s;
option remember;
if n=0 then return 1; fi;
expand(1/n*add(a[l]*pet_cycleind_vrec(n-l), l=1..n));
end;
fp :=
proc(n, p, k)
local nonfixed, q, j, cyc;
q := p;
for j to k-1 do
q := mulperms(q, p);
od;
nonfixed := 0;
for cyc in q do
nonfixed := nonfixed + nops(cyc);
od;
n - nonfixed;
end;
v :=
proc(n, k)
option remember;
local t, el, v, q, cf, d, len, deg, res, cycs;
res := 0;
for t in pet_cycleind_vrec(n) do
el := 1;
cf := t; cycs := [];
for v in indets(t) do
deg := degree(t, v);
cf := cf/v^deg;
len := op(1, v);
if len>1 then
for d to deg do
cycs :=
[op(cycs), [seq(el+q, q=0..(len-1))]];
el := el + len;
od;
else
el := el + deg;
fi;
od;
res := res + cf*fp(n, cycs, k);
od;
res;
end;