Consider a popular sports news site. At a given moment, 20,000 concurrent users submit a request (a transaction. T) once every 2 minutes on average. Each transaction requires the webapp to download a new article that on average has 3k bytes in length. What is the throughput?
4 megabits per second
This problem asks us to calculate the throughput of a popular sports news site. Throughput is a measure of how much data is successfully transferred over a communication channel in a given amount of time. To find the throughput, we need to determine the total amount of data being requested by all users per second and then convert this to the required units (megabits per second).
We are given the following information:
Let's break down the calculation into steps:
Each of the 20,000 users makes one request every 2 minutes. First, let's find the total number of requests in 2 minutes:
Total requests in 2 minutes = \( \text{Number of users} \times \text{Requests per user} \)
Total requests in 2 minutes = \( 20,000 \times 1 = 20,000 \) requests
Now, let's find the total requests per minute:
Total requests per minute = \( \frac{\text{Total requests in 2 minutes}}{2 \text{ minutes}} = \frac{20,000}{2} = 10,000 \) requests per minute
To find the requests per second, we convert minutes to seconds (1 minute = 60 seconds):
Total requests per second = \( \frac{\text{Total requests per minute}}{60 \text{ seconds per minute}} = \frac{10,000}{60} \) requests per second
Total requests per second \( = \frac{1000}{6} = \frac{500}{3} \) requests per second (approximately 166.67 requests per second)
Each request downloads an article with an average size of 3k bytes. The 'k' in '3k bytes' typically means 1000 in the context of data transfer rates (kilobytes). So, 3k bytes = 3 \(\times\) 1000 bytes = 3000 bytes.
Total data per second = \( \text{Total requests per second} \times \text{Data size per request} \)
Total data per second = \( \frac{10,000}{60} \times 3000 \) bytes per second
Total data per second = \( \frac{10,000 \times 3000}{60} = \frac{30,000,000}{60} \) bytes per second
Total data per second = \( 500,000 \) bytes per second
Throughput is often measured in bits per second (bps) or multiples like kilobits per second (kbps), megabits per second (Mbps), etc. We need to convert bytes per second to bits per second.
1 byte = 8 bits
Total data per second in bits = \( \text{Total data per second in bytes} \times 8 \)
Total data per second in bits = \( 500,000 \times 8 = 4,000,000 \) bits per second
Now, we need to convert bits per second to megabits per second. In networking and telecommunications, 'mega' (M) usually means \(10^6\) (one million). So, 1 megabit (Mb) = 1,000,000 bits.
Throughput in Mbps = \( \frac{\text{Total data per second in bits}}{1,000,000 \text{ bits per Mb}} \)
Throughput in Mbps = \( \frac{4,000,000}{1,000,000} = 4 \) Mbps
Therefore, the throughput of the sports news site is 4 megabits per second.
| Metric | Value | Units |
|---|---|---|
| Concurrent Users | 20,000 | Users |
| Request Frequency per User | 1 per 2 mins | Transaction/User |
| Average Article Size | 3k | Bytes |
| Total Requests per 2 mins | 20,000 | Requests |
| Total Requests per min | 10,000 | Requests/min |
| Total Requests per sec | \( \frac{10000}{60} \) | Requests/sec |
| Article Size (Bytes) | 3000 | Bytes |
| Total Data per Sec (Bytes) | \( \frac{10000}{60} \times 3000 = 500,000 \) | Bytes/sec |
| Total Data per Sec (Bits) | \( 500,000 \times 8 = 4,000,000 \) | Bits/sec |
| Throughput (Mbps) | \( \frac{4,000,000}{1,000,000} = 4 \) | Mbps |
Based on the calculations, the throughput required for the sports news site under these conditions is 4 megabits per second.
| Term | Definition/Concept |
|---|---|
| Throughput | The rate at which data is successfully transmitted over a communication channel per unit of time. Usually measured in bits per second (bps). |
| Concurrent Users | The number of users actively using a system or application at the same time. |
| Transaction | A single unit of work or request made by a user to a system, like downloading an article. |
| Bytes vs Bits | A byte is a unit of digital information that most commonly consists of 8 bits. Network speeds (throughput) are typically measured in bits per second. |
| Prefixes (k, M, G) | In networking/telecom (and often in this context): kilo (k) means 103, mega (M) means 106, giga (G) means 109. For storage, they sometimes refer to powers of 1024. |
While our calculation provides a theoretical throughput requirement based on user activity and data size, actual throughput can be affected by many factors:
Understanding these factors is important for designing and managing high-traffic websites like a popular sports news site to ensure a good user experience even with many concurrent users and frequent transactions.
A stone is thrown horizontally from the top of a 20 m high building with a speed of 12 m/s. It hits the ground at a distance R from the building. Taking g = 10 m/s2 and neglecting air resistance will give :
A sphere of volume V is made of a material with lower density than water. While on Earth, it floats on water with its volume f1V (f1 < 1) submerged. On the other hand, on a spaceship accelerating with acceleration a < g (g is the acceleration due to gravity on Earth) in outer space, its submerged volume in water is f2V. Then:
A railway wagon (open at the top) of mass M1 is moving with speed v1 along a straight track. As a result of rain, after some time it gets partially filled with water so that the mass of the wagon becomes M2 and speed becomes v2. Taking the rain to be falling vertically and the water stationery inside the wagon, the relation between the two speeds v1 and v2 is :
Consider the following statements:
1. Distance between the longitudes becomes zero on North Pole and South Pole.
2. Distance between the longitudes is maximum on the Equator.
3. Number of longitudes is more than number of latitudes.
Which of the statements given above is/are correct?
One block of 2⋅0 kg mass is placed on top of another block of 3⋅0 kg mass. The coefficient of static friction between the two blocks is 0⋅2. The bottom block is pulled with a horizontal force F such that both the blocks move together without slipping. Taking acceleration due to gravity as 10 m/s2, the maximum value of the frictional force is :