As mentioned in the comments, at $T\to\infty, f=\frac{FS}{N}$ for $N>S$ and for $N\leq S$ your code will start double pulsing periodically.
However, that's the the limit. If you aren't looking at long term behavior, this is what you'll follow:
Define $r\equiv N\pmod{S}$. (i.e. $r$ is the remainder after dividing $N$ by $S$.) The number generation will be cyclic over $S$ pulses. So every $S$ pulses, you have the same pattern again. However, in this cycle, some of the pulses will be $F$ longer than the rest. Denote $P=\lfloor \frac{N}{S}\rfloor$. You will have $S-r$ pulses of length $\frac{P}{F}$ and $r$ pulses of length $\frac{P+1}{F}$. However, the longer pulses will be evenly spaced out in the cycle.
For example: take $N=30$ and $S=7$. We know $r=2$ and $P=4$.
Here is the cycle:
$$7,14,21,28,35$$
$$12,19,26,33$$
$$10,17,24,31$$
$$8,15,22,29,36$$
$$13,20,27,34$$
$$11,18,25,32$$
$$9,16,23,30$$
$$\vdots$$
You have a cycle of length $7$ where $7-2=5$ of them are of length $P$ and $r=2$ of them of length $P+1$.
However, for fast enough $F$, it will be hard to notice the difference between this "varying" frequency pulse pattern and a pulse sequence of frequency $\frac{FS}{N}$.