For any positive integer $k$ denote by $S(k)$ the number of solutions $(x,y)\in \mathbb{Z}_+ \times \mathbb{Z}_+$ of the system
$$\begin{cases} \left\lceil\frac{x\cdot d}{y}\right\rceil\cdot \frac{x}{d}=\left\lceil\left(\sqrt{y}+1\right)^2\right\rceil \\ \mid x-y\mid =k , \end{cases}$$
where $d$ is the greatest common divisor of positive integers $x$ and $y.$ Determine $S(k)$ as a function of $k$. (Here $\lceil z\rceil$ denotes the smalles integer number which is bigger or equal than $z.$)
1. **Initial Setup and Assumptions:**
   - We are given the system of equations:
     \[
     \begin{cases}
     \left\lceil\frac{x \cdot d}{y}\right\rceil \cdot \frac{x}{d} = \left\lceil\left(\sqrt{y} + 1\right)^2\right\rceil \\
     |x - y| = k
     \end{cases}
     \]
   - Here, \(d\) is the greatest common divisor (gcd) of \(x\) and \(y\), and \(\lceil z \rceil\) denotes the ceiling function.

2. **Case Analysis:**
   - We need to consider two cases based on the relationship between \(x\) and \(y\):
     - \(y = x + k\)
     - \(x = y + k\)

3. **Case 1: \(y = x + k\):**
   - Substituting \(y = x + k\) into the first equation:
     \[
     \frac{x \cdot d}{y} = \frac{x \cdot d}{x + k}
     \]
   - Since \(d\) is the gcd of \(x\) and \(y\), \(\frac{x \cdot d}{x + k} < d\). Therefore:
     \[
     \left\lceil \frac{x \cdot d}{x + k} \right\rceil \cdot \frac{x}{d} \leq x < y < \left\lceil \left(\sqrt{y} + 1\right)^2 \right\rceil
     \]
   - This leads to a contradiction, so \(y = x + k\) is not possible.

4. **Case 2: \(x = y + k\):**
   - Substituting \(x = y + k\) into the first equation:
     \[
     \left\lceil \frac{(y + k) \cdot d}{y} \right\rceil \cdot \frac{y + k}{d} = \left\lceil \left(\sqrt{y} + 1\right)^2 \right\rceil
     \]
   - Simplifying the left-hand side:
     \[
     \frac{(y + k) \cdot d}{y} = d + \frac{k \cdot d}{y}
     \]
     \[
     \left\lceil d + \frac{k \cdot d}{y} \right\rceil \cdot \frac{y + k}{d} = y + k + \left\lceil \frac{k \cdot d}{y} \right\rceil \cdot \frac{y + k}{d}
     \]
   - Simplifying the right-hand side:
     \[
     \left\lceil \left(\sqrt{y} + 1\right)^2 \right\rceil = y + 1 + \lceil 2\sqrt{y} \rceil
     \]

5. **Further Simplification:**
   - Equating both sides:
     \[
     y + k + \left\lceil \frac{k \cdot d}{y} \right\rceil \cdot \frac{y + k}{d} = y + 1 + \lceil 2\sqrt{y} \rceil
     \]
     \[
     k + \left\lceil \frac{k \cdot d}{y} \right\rceil \cdot \frac{y + k}{d} = 1 + \lceil 2\sqrt{y} \rceil
     \]

6. **Subcase Analysis:**
   - **Subcase 1: \(d = k\):**
     - Then \(d\) divides \(y\). Let \(y = ky'\). Since \(y > (k-1)^2\), \(y' \geq k-1\).
     - If \(y' \geq k\), then \(\left\lceil \frac{k \cdot d}{y} \right\rceil = 1\), so:
       \[
       k + y' + 1 = 1 + \lceil 2\sqrt{ky'} \rceil
       \]
     - We can check that \(y'\) such that \(k \leq y' < k + 2\sqrt{k} + 1\) is possible, so there are \(\lceil 2\sqrt{k} + 1 \rceil\) solutions.
     - If \(y' = k-1\), then \(\left\lceil \frac{k \cdot d}{y} \right\rceil = 2\), so the equation becomes \(3k = 2k\), which is a contradiction.

   - **Subcase 2: \(d < k\):**
     - Since \(d\) is a divisor of \(k\), \(d \leq \frac{k}{2}\), so \(d \leq k-2\).
     - Therefore, \(y > (k-1)^2 > k(k-2) \geq kd\), so the equation becomes:
       \[
       k + \frac{k + y}{d} = 1 + \lceil 2\sqrt{y} \rceil
       \]
     - Since \(y > k(k-2)\), \(\frac{y}{d} \geq \frac{y}{k-2} \geq \frac{y}{k} + 2\). Also, \(\frac{k}{d} \geq 1\). Therefore:
       \[
       k + \frac{k + y}{d} \geq 3 + k + \frac{y}{k} \geq 3 + 2\sqrt{y} > 1 + \lceil 2\sqrt{y} \rceil
       \]
     - This leads to a contradiction.

7. **Conclusion:**
   - From all cases, we get \(S(k) = \lceil 2\sqrt{k} + 1 \rceil\).

The final answer is \(\boxed{\lceil 2\sqrt{k} + 1 \rceil}\).