COE 558Lecture 01Part 07
The physics of latency
Latency to the cloud, the speed-of-light lower bound, geodesic distance, real measurements from Dammam, and the four delays that add up.
- Concepts
- 4
- Slides
- 51-55
- Reading
- 24 min
Why this part matters
Today’s default is to put the server in the cloud. This part prices that default in milliseconds. You will learn to turn a distance into the smallest delay physics allows, compare that floor with real measurements from Dammam, and break the gap into the four delays every packet pays.
The ideas build on each other. First, what latency is and the hard floor under it. Second, how to measure the distance that floor depends on. Third, how far above the floor real networks sit. Fourth, the four delays that explain the difference. For the exams, expect calculations: distance to bound, one way versus round trip, and the formulas L/R and d/s. For the research project and for real edge and cloud design, remember one thing above all: the d/s term is the one cost that no amount of cloud capacity removes. That is the physical argument for the edge, fog and cloud continuum in the next part.
By the end you can
- Define latency as transit time, and explain why a request-response exchange pays it twice.
- Compute the one-way and round-trip latency lower bound from a geodesic distance, and the fiber floor above it.
- Explain why latency must use geodesic rather than planar distance.
- Compare a measured RTT with the right bound, and account for the roughly threefold gap.
- Name the four packet delays, apply transmission = L/R and propagation = d/s, and predict which one dominates.
Picture a student in Dhahran opening an app whose backend runs in the AWS Frankfurt region. His phone sends a request that must physically cross about 4,400 km of Earth, and the answer must cross it again on the way back. Nothing useful can happen on his screen until both trips are done.
Latency is transit time, paid in both directions
That travel time is Latency: the time data spends in transit between two points. In the Request-response loop you met earlier, the Client always starts, so every exchange pays latency twice: once from client to Server, once from server back to client. Total network latency is the sum of the two one-way figures. They are often close, but they need not be equal, because Internet routes are not always the same in both directions.
Sends the request and waits.
Does its work. That time is processing, not latency.
Receives the answer after both transits.
Putting the server in the Cloud is the default because it is convenient, elastic and cheap to operate. The natural next question is how much time that choice costs at the very least, before any engineering detail enters the picture.
The smallest latency physics allows
Start with a number. A server 3,000 km away, reached at the speed of light, needs 3,000 ÷ 300,000 = 0.01 s, which is 10 ms one way. So every 1,000 km costs at least 3.3 ms one way, or 6.7 ms for a round trip.
Generalising this gives the Latency lower bound: divide the Geodesic distance by the speed of light . It is a lower bound for three reasons that stack. Nothing carries information faster than light. No cable between two cities can be shorter than the shortest path along the Earth. And the formula ignores every other delay a real packet meets. Because each simplification can only make the true figure larger, the result is a floor that no provider, protocol or hardware upgrade can break.
Real glass is slower than vacuum
“Speed of light” in the bound means light in a vacuum. Real links carry light through glass fiber with a refractive index of about 1.5, so the signal moves at roughly 200,000 km/s, about two thirds of (Grigorik, High Performance Browser Networking). Even a perfectly straight fiber therefore needs about 1.5× the bound. ITU-T G.114 plans 5 µs/km for optical fibre systems, which is 5 ms per 1,000 km, against 3.3 ms per 1,000 km at . Keep both numbers in mind: the vacuum bound is the absolute floor, and the fiber floor is the realistic best case for a cabled network.
Try the simulator. Pick the Frankfurt preset and read the one-way bound, then read the round-trip value to see the number doubled. The presets use the distances implied by the lecture’s own figures (for example 11,100 km for Oregon), a choice examined closely when we compare bounds with measurements below.
Light in fibre is slower than in vacuum, cables do not follow the geodesic, and routers add processing, queueing and transmission delay. The band above is only an illustration. Slide 55 notes real latency can reach up to 100× the lower bound.
Recall
What does the lower-bound formula leave out, and why is it still useful?
It leaves out the slower speed of light in fiber, cable routes longer than the geodesic, and the processing, queueing and transmission delays. It is still useful because no real network can beat it: if the bound alone already breaks your latency target, the only fix is to move the server closer.
The bound is only as good as the distance you feed it, so which distance is the right one? Stretch a string tight between London and Singapore on a real globe. It does not run across Arabia the way a ruler on a flat map suggests. It runs north, over Eastern Europe and Central Asia. Now flatten that globe into a rectangle: the string that was the shortest path turns into a curve.
Those are the two candidates. A straight line drawn on the flat map gives the planar distance. The curve that the string traces gives the Geodesic distance between the same two endpoints. Esri’s documentation defines planar distance as straight-line Euclidean distance in a 2D Cartesian coordinate system, and geodesic distance as distance across the curved surface of the world in 3D. Signals travel over the real Earth, not over a map, so latency lives in the second definition.
Map projections stretch the Earth, and the stretch grows with latitude and with the size of the area. Over a city block the two distances agree. Over continents they can disagree a lot, and near the equator they can be surprisingly close: Esri notes that for Singapore to Nairobi, about 7,440 km, the Web Mercator planar result is less than a metre longer. Because you cannot know in advance which case you are in, always use the geodesic when you compute a Latency lower bound. Using a planar distance that happens to be too short would even produce a “bound” that is not a bound at all.
| Aspect | Planar distance | Geodesic distance |
|---|---|---|
| Computed in | A flat 2D Cartesian plane (a projected map) | 3D space, across the curved surface of the Earth |
| Looks like on a flat map | A straight line | Usually a curve bending toward the pole |
| Accuracy over long range | Error grows with distance and latitude | Correct by definition (shortest surface path) |
| Use for latency | No, except for tiny local areas | Yes, always for intercity or intercontinental links |
Quick check
On a flat map, the straight London to Singapore line looks shorter than the curved one. Which path is shorter on the real Earth?
Recall
Why does the curved line on a flat map represent the shorter path?
The map projection distorts the sphere. The geodesic is the shortest path along the curved surface, and it only looks curved after the globe is flattened into a map.
With the right distance and the right formula in hand, the bound can finally meet reality. Put the client in Dammam and the server in three AWS regions: US West (Oregon, us-west-2), Europe (Frankfurt, eu-central-1) and Asia Pacific (Tokyo, ap-northeast-1). For each, compute the one-way Latency lower bound, then compare it with the Round-trip time (RTT) measured with aws-latency-test.com.
Worked example
Dammam to Frankfurt: bound against measurement
Get the distance
The geodesic from Dammam to Frankfurt is about 4,390 km. The lecture’s 14.7 ms implies about 4,410 km, which agrees.
One-way bound
4,390 ÷ 300,000 = 0.01463 s ≈ 14.6 ms.
Round-trip bound
2 × 14.6 ≈ 29.3 ms. This is the number to compare with an RTT.
Fiber floor
At 200,000 km/s the same path takes 21.9 ms one way and 43.9 ms round trip, even on a perfect cable laid exactly along the geodesic.
Compare
Measured RTT 100 ms ÷ 29.3 ms ≈ 3.4× the vacuum bound, and about 2.3× the fiber floor.
Result
Physics sets a floor of about 29 ms (vacuum) or 44 ms (fiber). The remaining ≈56 ms comes from longer cable routes, routers and queues. No provider can ever push this RTT below 29.3 ms.
The rule behind the example: compare like with like. An RTT is a round trip, so compare it with twice the one-way bound, never with the one-way figure itself. Doing that for all three regions tells the same story each time: the measurements sit about 2.9× to 3.4× above the vacuum round-trip bound. A ratio that stable across very different distances is a hint that the extra cost is systematic, not bad luck on one path.
| Region | Geodesic | Bound, one way / RTT | Fiber RTT floor | Measured RTT | Measured ÷ RTT bound |
|---|---|---|---|---|---|
| Frankfurt (eu-central-1) | ≈4,390 km | 14.6 ms / 29.3 ms | 43.9 ms | 100 ms | ≈3.4× |
| Tokyo (ap-northeast-1) | ≈8,300 km | 27.7 ms / 55.3 ms | 83.0 ms | 163 ms | ≈2.9× |
| Oregon (us-west-2) | ≈11,900 km | 39.7 ms / 79.4 ms | 119 ms | 243 ms | ≈3.1× |
Where the factor of three comes from
- About 1.5× comes from glass alone, because light in fiber moves at about two thirds of .
- Cables do not follow the geodesic. They follow coastlines and seabeds, land at a few stations, and backhaul over land to data centers.
- Each router on the way adds processing and queueing time, two of the four delays in the next concept.
Research agrees with this breakdown. Singla and colleagues measured Internet paths worldwide and found router paths about 2.3× the speed-of-light latency at the median. After removing the 1.5× fiber factor, path detours alone still leave about 1.53×.
Quick check
Dammam to Singapore is about 6,370 km along the geodesic. What is the round-trip lower bound at the speed of light in vacuum?
Quick check
The measured Dammam to Frankfurt RTT is 100 ms, about three times the 29 ms vacuum bound. What best explains the gap?
Recall
Dammam to London is about 5,020 km. Give the vacuum RTT bound and the fiber RTT floor.
5,020 ÷ 300,000 ≈ 16.7 ms one way, so 33.5 ms RTT. In fiber at 200,000 km/s it is 25.1 ms one way and 50.2 ms RTT.
Recall
The measured Dammam to Tokyo RTT is 163 ms. How much is left after perfect fiber along the geodesic?
About 83 ms is the fiber RTT floor, so roughly 80 ms comes from longer routes, router processing and queueing.
The factor of three needs a precise vocabulary. Follow one 1,500-byte packet across one router onto a 4,390 km fiber link running at 1 Gbps. Pushing its 12,000 bits onto the wire takes 12,000 ÷ 10⁹ s = 12 µs. Travelling the fiber takes about 22 ms. The router’s own work takes microseconds. Waiting behind other packets takes anything from nothing to a very long time. Now slow the link to 10 Mbps: pushing the bits out now takes 1.2 ms, and the fiber trip is still 22 ms.
Those four pieces are the four packet delays, and Kurose and Ross (section 1.4) add them up at every node a packet crosses. Processing delay happens inside switches and routers. Queueing delay happens in buffers when traffic piles up. Transmission delay happens at the network interface and depends on bandwidth. Propagation delay happens on the physical channel and depends on distance. Only the last one is the physics behind the lower bound; the other three are what real equipment and real traffic add on top.
End to end, you add the nodal delay over every hop on the path, and an RTT adds it again for the return direction. That sum is exactly the measured RTT from Dammam, which is why it sits so far above 2d/c. Hold on to the contrast that exams love: transmission depends on packet size and bandwidth and has nothing to do with distance, while propagation depends on distance and the medium and has nothing to do with bandwidth.
| Delay | Where it happens | Driven by | Formula or key factor | Shrinks when |
|---|---|---|---|---|
| Processing | Inside each router, switch or host | Header checks, bit-error checks, forwarding lookup | Device speed (usually microseconds) | Faster hardware, fewer hops |
| Queueing | In router and server buffers | Congestion: how many packets arrived ahead of yours | Traffic intensity, from zero to very large | Less traffic, more capacity, fewer hops |
| Transmission | At the network interface pushing bits onto the link | Packet size and link bandwidth | L / R | Bandwidth goes up or packets get smaller |
| Propagation | Along the physical channel (fiber, copper, radio) | Link length and the medium | d / s | The endpoints move closer |
Can it really be 100 times the bound?
The lecture claims Internet latency can reach 100× the Latency lower bound. For whole page loads, measurements support this. Singla and colleagues found that fetching just the HTML of popular web pages took 34× the round-trip speed-of-light latency at the median and 169× at the 90th percentile. Those fetches include more than the four per-hop delays: a DNS lookup, the TCP handshake and TCP’s slow start all add round trips. The lecture’s example of a 15 ms theoretical latency turning into 1,500 ms is best read the same way: an illustration of network delays stacked with protocol and application effects, not four delays on a single link.
Quick check
A file server moves from a 1 Gbps link to a 10 Mbps link on the same cable route. Which delay grows for every packet?
Recall
Which delay depends on bandwidth, and which on distance? Give both formulas.
Transmission, , depends on packet size and link rate. Propagation, , depends on link length and the signal speed in the medium.
Recap
If you remember nothing else
- Latency is time in transit. A request-response exchange pays it in both directions.
- Latency_LB = geodesic distance ÷ c (about 300,000 km/s). Double it for RTT. No network can beat it.
- Measure distance along the curved Earth (geodesic), not as a straight line on a flat map.
- Light in fiber travels at about 2/3 c, so even a perfect cable is about 1.5× the bound (about 5 ms per 1,000 km).
- Measured RTTs from Dammam (100, 163 and 243 ms) are about 3× the round-trip bound, because of slower fiber, cable detours, routers and queues.
- Total delay = processing + queueing + transmission (L/R) + propagation (d/s). Bandwidth shrinks only transmission. Only moving closer shrinks propagation.
- Full page fetches can be tens to over a hundred times the bound (Singla et al.: 34× median, 169× at the 90th percentile). This is why edge placement matters.
Sources
- Computer Networking: A Top-Down Approach, 9th edition (Kurose and Ross)BookPearsonSection 1.4, Delay, Loss, and Throughput in Packet-Switched Networks: the four delays, L/R and d/s.(opens in a new tab)
- Transmission versus Propagation Delay (interactive applet)DocsPearson, companion site for Kurose and RossPlay with packet size, rate and distance to see the two delays separate.(opens in a new tab)
- Speed of light in vacuum, CODATA valueDocsNISTExactly 299,792,458 m/s.(opens in a new tab)
- High Performance Browser Networking: Primer on Latency and Bandwidth (Ilya Grigorik)BookO’ReillyThe four delays; fiber refractive index about 1.5, signal speed about 200,000,000 m/s.(opens in a new tab)
- The Internet at the Speed of Light (Singla, Chandrasekaran, Godfrey, Maggs)PaperACM HotNets 2014HTML fetch 34× c-latency at the median, 169× at the 90th percentile; router paths 2.3×; fiber alone 1.5×.(opens in a new tab)
- ITU-T Recommendation G.114: One-way transmission timeDocsITU-TTable 1: optical fibre cable systems, 5 µs/km including repeaters and regenerators.(opens in a new tab)
- Geodesic versus planar distanceDocsEsri ArcGIS Pro documentationDefinitions of planar and geodesic distance, and the Singapore to Nairobi example.(opens in a new tab)
- Algorithms for geodesics (C. F. F. Karney)PaperJournal of Geodesy 87(1), 2013Accurate geodesics on the WGS84 ellipsoid.(opens in a new tab)
- AWS RegionsDocsAmazon Web ServicesRegion codes for Oregon, Frankfurt, Tokyo, Bahrain and UAE.(opens in a new tab)
- AWS Latency TestArticleIndependent, not an official AWS projectSource of the measured Dammam RTTs. Results vary per run and are for illustration only.(opens in a new tab)