Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top


  • a website has $n$ concurrent users on average
  • each user makes on average $s$ searches per minute while on the site
  • the searches are distributed evenly (round-robin style) over $v$ servers

There is a threshold of $x$ searches per second per server; any more than this and strongly undesirable things happen.

If you know $n$ and $s$, what is the formula to find the minimum number of servers $v$ that keeps the searches per second below the threshold at a certain probability level (e.g. 90% certainty versus 99% certainty).

Is this even enough information? Or do you need to know something about the shape of the Gaussian(?) distributions for $n$ and $s$, say $\sigma_n$ and $\sigma_s$?

Real World Application

For the curious, my company is planning on proxying Google Search API requests through a local server. However, Google has automatic DOS detection that kicks in if the same public IP makes "too many" requests per second. If this happens, the IP gets blacklisted and search will stop working on the site until humans intervene and remove the blacklisting. So, while we don't know $n$ or $s$ for sure, we need to guess at them and pick a large enough $v$ to ensure that a spike in traffic probably won't stop our servers from working.

share|cite|improve this question

You need to know something about the shape of the distributions for $n$ and $s$, since those distributions are not necessarily Gaussian. $\:$ (For example, they are always non-negative.)
$n$ would probably have a Poisson distribution; I don't have such a good idea for $s$,
although I'd consider log-normal. $\:$ It will also make a (probably small) difference whether
or not the threshold is over a rolling one second period or over each distinct second.

non-mathematical points:

Google Search API will likely stop working in less than a year.
Google already sells custom search API queries.

share|cite|improve this answer
Thanks for the insight. FWIW the company has an enterprise account spending obscene amounts with Google for search support; the XML API is what we'll likely be using. Now...given those distributions, any answer to the question for the formula itself? ;) – Phrogz Nov 13 '12 at 21:59

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.