Let \(\tau (n)\) be the Dirichlet divisor function and let \(k\geqslant 2\) be a fixed integer. In this paper we show that for sufficient large T and a suitable constant C, the error term \(\begin{aligned} \Delta _k(x)=\sum _{n_1,\ldots ,n_k\leqslant x}\tau (n_1 \ldots n_k)-x^kP_k(\log x) \end{aligned}\) changes its sign on every interval \([T,T+C\sqrt{T}]\) . Moreover we show that a proportion of intervals \([T,T+C\sqrt{T}\log ^{-2k-3}T]\) contain no such sign change.
When \(k=1\) , these results are consistent with the results given by Heath-Brown and Tsang (J Number Theory 49(1):73–83, 1994).