— A stochastic model of TCP is developed. Unlike many other models, this model accounts for variations in latency and loss probability. A major strength of this model is that it easily produces the probability distribution of the congestion window. Thus, the mean as well as the median and percentiles can be found. It is shown that the mean congestion window can be far larger than the median. Other new insights include the effect of the rate of change of the latency on the performance of TCP. Specifically, this model predicts the well-known TCP-friendly formula only if the round-trip time rapidly varies. However, if the round-trip time does not vary quickly, then the TCPfriendly formula may not hold. Both rapidly and slowly varying round-trip times have been observed in real networks. As an application of the model, the question as to when a video can be fairly transmitted is addressed. If it is possible to transmit the video, the model yields the distribution of the size of the rece...