Traffic Flow Calculator
Calculate traffic flow rate, density, and speed using the fundamental traffic flow equation. Enter values for instant results with step-by-step formulas.
Calculator
Adjust values & calculateFormula
Where q is flow rate (veh/hr), k is density (veh/mi), u is speed (mph), uf is free-flow speed, and kj is jam density. The Greenshields model assumes a linear speed-density relationship and yields a parabolic flow-density curve with maximum capacity at half the jam density.
Last reviewed: December 2025
Worked Examples
Example 1: Freeway Segment Analysis
Example 2: Two-Lane Highway Capacity Check
Background & Theory
The Traffic Flow Calculator applies the following established principles and formulas. Structural and construction engineering is governed by fundamental load analysis, material science, and regulatory standards that ensure the safety and durability of built structures. The primary distinction in load analysis is between dead loads โ the permanent self-weight of structural elements, finishes, and fixed equipment โ and live loads, which represent variable occupancy, furniture, and environmental forces such as wind and snow. These are combined using factored load equations, such as the ASCE 7 formula U = 1.2D + 1.6L, where D is dead load and L is live load. Concrete mix design is governed by the water-cement (w/c) ratio, which is the primary determinant of compressive strength and durability. A w/c ratio of 0.40โ0.45 typically yields concrete with 28-day compressive strengths of 30โ40 MPa. Common mix ratios by weight for structural concrete are approximately 1 part cement : 1.5โ2 parts sand : 3 parts coarse aggregate. Structural steel is characterized by its yield strength (the stress at which permanent deformation begins, typically 250โ350 MPa for mild steel) and ultimate tensile strength (typically 400โ500 MPa). Mid-span deflection of a simply supported beam under a central point load is given by ฮด = FLยณ / (48EI), where F is force, L is span length, E is Young's modulus, and I is the second moment of area. Building insulation is rated by R-value, a measure of thermal resistance in units of mยฒยทK/W (SI) or ftยฒยทยฐFยทh/BTU (imperial). Higher R-values indicate greater resistance to heat flow. Foundation design depends on the allowable bearing capacity of the underlying soil, which ranges from approximately 75 kPa for soft clay to over 10,000 kPa for bedrock. Drainage gradients for surface water are typically specified as a minimum of 1โ2% slope away from building foundations to prevent hydrostatic pressure and water infiltration.
History
The history behind the Traffic Flow Calculator traces back through the following developments. The history of construction engineering spans thousands of years of accumulated empirical knowledge and, more recently, rigorous scientific analysis. The ancient Egyptians built the Great Pyramid of Giza around 2560 BCE using an estimated 2.3 million stone blocks, demonstrating sophisticated logistics, geometry, and workforce organization. Roman engineers advanced the field dramatically through the use of pozzolanic concrete โ a mixture of volcanic ash, lime, and seawater โ enabling the construction of the Pantheon dome (43.3 m diameter, completed around 125 CE) and a vast network of aqueducts and roads across the empire. Cast iron emerged as a structural material during the Industrial Revolution, first used prominently in the Iron Bridge at Coalbrookdale, England, completed in 1779. Wrought iron and later steel allowed far greater spans and heights. The Eiffel Tower, completed in 1889, demonstrated the structural possibilities of wrought iron at scale and influenced the development of steel-frame skyscraper construction in Chicago and New York. Reinforced concrete was systematically developed by Joseph Monier, a French gardener, who patented iron-reinforced concrete pots and panels in the 1860s, and later by engineers including Franรงois Hennebique who created the first comprehensive reinforced concrete framing system in the 1890s. The 1906 San Francisco earthquake caused widespread devastation and galvanized the engineering profession to develop seismic design provisions. Subsequent earthquakes โ including the 1971 San Fernando and 1994 Northridge events โ drove successive improvements in seismic codes, base isolation technology, and ductile detailing of reinforced concrete and steel frames. Building codes became increasingly standardized in the twentieth century, with the International Building Code (IBC) first published in 2000 providing a unified model code adopted across much of the United States. Building Information Modeling (BIM) emerged in the 2000s as a digital workflow integrating architectural, structural, and MEP design into a unified three-dimensional model, fundamentally changing coordination practices across the industry.
Frequently Asked Questions
Formula
q = k x u | Capacity = uf x kj / 4
Where q is flow rate (veh/hr), k is density (veh/mi), u is speed (mph), uf is free-flow speed, and kj is jam density. The Greenshields model assumes a linear speed-density relationship and yields a parabolic flow-density curve with maximum capacity at half the jam density.
Worked Examples
Example 1: Freeway Segment Analysis
Problem: A 3-lane freeway carries 5,400 vehicles per hour at a mean speed of 58 mph. Free-flow speed is 70 mph and jam density is 240 veh/mi. Determine LOS and v/c ratio.
Solution: Flow per lane = 5400 / 3 = 1800 veh/hr/ln\nDensity k = q / u = 5400 / 58 = 93.1 veh/mi total = 31.0 veh/mi/ln\nCapacity = uf x kj / 4 = 70 x 240 / 4 = 4200 veh/hr per lane\nTotal capacity = 4200 x 3 = 12,600 veh/hr\nV/C ratio = 5400 / 12600 = 0.429\nLOS based on density of 31.0 pc/mi/ln = LOS D (26-35 range)
Result: Density: 31.0 veh/mi/ln | V/C: 0.429 | LOS D (Approaching unstable flow)
Example 2: Two-Lane Highway Capacity Check
Problem: A two-lane highway has a volume of 1,200 veh/hr with average speed of 48 mph. Free-flow speed is 55 mph, jam density is 200 veh/mi. Is this near capacity?
Solution: Density = 1200 / 48 = 25.0 veh/mi total = 12.5 veh/mi/ln\nCapacity = uf x kj / 4 = 55 x 200 / 4 = 2750 veh/hr total\nV/C ratio = 1200 / 2750 = 0.436\nDensity per lane = 12.5, which is LOS B (11-18 range)\nHeadway = 3600 / (1200/2) = 6.0 seconds
Result: Density: 12.5 veh/mi/ln | V/C: 0.436 | LOS B (Reasonably free flow) | 6.0s headway
Frequently Asked Questions
What is the fundamental traffic flow equation and what does it describe?
The fundamental traffic flow equation is q = k x u, where q is the flow rate (vehicles per hour), k is the density (vehicles per mile), and u is the space mean speed (miles per hour). This deceptively simple equation describes the macroscopic relationship between the three fundamental traffic stream variables. It forms the basis of all traffic flow theory and is used in highway capacity analysis, traffic simulation, and congestion management. The equation tells us that traffic flow is the product of how many vehicles occupy a stretch of road and how fast they are moving. Understanding this relationship is essential because increasing density beyond a critical point actually reduces flow, which is the fundamental mechanism of traffic congestion and breakdown.
What is the Greenshields traffic flow model and its assumptions?
The Greenshields model, proposed by Bruce Greenshields in 1935, was the first mathematical model relating speed and density in traffic streams. It assumes a linear relationship: u = uf x (1 - k/kj), where uf is the free-flow speed and kj is the jam density. This leads to a parabolic flow-density relationship with maximum flow (capacity) occurring at the critical density kc = kj/2 and capacity speed uc = uf/2. While simple, this model captures the fundamental behavior that speed decreases as density increases. Its main limitation is that it assumes the speed-density relationship is linear across all densities, which field data shows is not exactly true. Real traffic data typically shows that speed remains near free-flow until density reaches a threshold, then drops more rapidly. Despite this, Greenshields remains widely used for its mathematical simplicity and reasonable approximations.
What is the difference between flow rate and volume in traffic engineering?
Volume is the total number of vehicles passing a point during a specified time period, typically one hour, while flow rate is the equivalent hourly rate at which vehicles pass a point during a sub-hourly period, typically the peak 15 minutes. The relationship is: flow rate = volume / PHF, where PHF is the Peak Hour Factor. For example, if 3,600 vehicles pass in one hour but 1,080 pass during the busiest 15 minutes, the hourly volume is 3,600 veh/hr but the peak flow rate is 1,080 x 4 = 4,320 veh/hr. The PHF = 3,600/4,320 = 0.833. This distinction matters because capacity analysis uses peak flow rates, not hourly volumes, since congestion occurs during the peak period within the peak hour. A PHF of 1.0 means perfectly uniform flow, while values below 0.80 indicate highly peaked demand.
How does traffic density relate to congestion and what is jam density?
Traffic density is the number of vehicles occupying a given length of road at an instant in time, measured in vehicles per mile (or per kilometer). As density increases from zero, flow initially increases because more vehicles are present. However, beyond the critical density, vehicles begin interfering with each other, speeds drop, and flow actually decreases despite more vehicles being present. This is the mechanism of congestion. Jam density (kj) is the theoretical maximum density when traffic comes to a complete standstill, typically 180-250 vehicles per mile per lane depending on vehicle mix and spacing. At jam density, speed and flow are both zero. The critical density (kc) where maximum flow occurs is approximately half the jam density in the Greenshields model. Traffic management strategies like ramp metering aim to keep density below the critical value to prevent breakdown.
What is the concept of traffic wave theory and shock waves?
Traffic wave theory, developed by Lighthill, Whitham, and Richards (LWR theory), describes how disturbances propagate through traffic streams as waves. When a vehicle brakes, the deceleration propagates backward through the traffic stream as a shock wave. The speed of this shock wave is calculated as w = (q2 - q1) / (k2 - k1), where the subscripts represent conditions upstream and downstream of the wave. Backward-moving shock waves (negative speed) create the familiar stop-and-go pattern in congested traffic. A vehicle at the back of a queue may have to stop long after the original disturbance has cleared. Understanding shock waves is essential for designing ramp metering systems, variable speed limits, and incident management strategies. Shock waves can persist for hours after the initial cause has been resolved, which is why traffic jams seem to appear without any visible reason.
How is traffic flow data collected and what technologies are used?
Traffic flow data is collected using a variety of technologies, each with different capabilities and accuracy levels. Inductive loop detectors embedded in the pavement are the most established method, counting vehicles and measuring speed and occupancy. Video detection systems use cameras with image processing algorithms to count vehicles and classify them by type. Radar and microwave sensors can measure speed and count vehicles without being embedded in the pavement. Bluetooth and Wi-Fi sensors detect electronic devices in passing vehicles to estimate travel times and origin-destination patterns. Modern connected vehicle data from GPS-equipped vehicles provides speed and travel time information across entire road networks. Crowdsourced data from smartphone apps like Google Maps and Waze provides real-time speed information. Each method has tradeoffs in cost, accuracy, maintenance requirements, and the types of data collected.
References
Reviewed by Daniel Agrici, Founder & Lead Developer ยท Editorial policy