Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. 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

I have to calculate the proper quantum of time for Round Robin process scheduling algorithm. As I read in Tanenbaum's book, the quantum of time should cover like 80% of the running time of all processes.

Is there a formula how to find the optimal quantum of time?

share|improve this question
Where did you found that 80% thing? Having a short look into the book, Tanenbaum gives a example where the quantum of time is about 80% of the total "quantum of time + context change time", as a demonstration for a wasteful decision (and how not to choose parameters). Did you mean that? – Doc Brown Jan 27 '13 at 7:20

You cannot choose an "optimal" quantum of time as long as you don't have any information beforehand about

  • how long each of your processes will run

  • how many new processes you have to expect within a given time frame

  • how quick each of your processes has to start / continue / respond

In a real system, you typically don't have those parameters beforehand, since this would mean to predict the future. Therefore, you will have typically have to make assumptions about those parameters, adapt the quantum dynamically to the environment, or choose a different kind of algorithm.

share|improve this answer

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.