A Data-Driven Approach to Enhancing Gravity Models for Trip Demand Prediction

Kamal Acharya, Mehul Lad, Liang Sun, Houbing SongCai 2025

Introduction

For over 50 years, urban planners have relied on the Gravity Model to predict travel flows between geographic zones. Inspired by Newton’s law of gravitation, this model assumes that the "flow" between two points is proportional to their "mass" (population) and inversely proportional to the distance between them. While elegant, this traditional approach is often too rigid for modern urban environments, failing to account for non-linear relationships and complex socio-economic variables like land use, economic health, and education levels.

Researchers have now addressed these limitations by augmenting the traditional gravity model with machine learning (ML) and high-resolution socio-economic data. This data-driven framework achieves significant performance gains, including up to a 63% reduction in prediction error and a 51% boost in explanatory power ($R^2$) in complex urban settings like New York.

Methodology

The study proposes a two-phase methodology to modernize trip prediction. First, a traditional gravity model was implemented as a performance benchmark. Second, the simple mathematical formula was replaced with three sophisticated machine learning architectures: Deep Neural Networks (DNN) for non-linear patterns, Random Forest (RF) for robustness with high-dimensional data, and Gradient Boosting Regressors (GBR) for iterative error optimization.

The research framework integrates socio-economic datasets with machine learning architectures to enhance trip demand prediction.

A critical innovation of this work is the feature engineering process. The researchers integrated 27 distinct features across eight categories, including land-use counts, points of interest (POI), road types, and economic indicators such as unemployment rates and median household income. The study utilized real-world data from Tennessee (TN) and New York (NY) to represent a spectrum of rural and high-density urban contexts, sourcing mobility flows from SafeGraph and routing data from the Open Source Routing Machine (OSRM).

Key Results and Insights

The machine learning-enhanced models consistently outperformed the traditional gravity model across all metrics and geographies. The improvements were most pronounced in high-density urban environments where data is dense and patterns are complex.

Performance comparison between traditional and data-driven gravity models across Tennessee (TN) and New York (NY).

Performance Highlights:

  • Explanatory Power ($R^2$): Improved by 51.48% in New York, indicating that ML models capture significantly more of the underlying drivers of travel.
  • Accuracy (MAE): Mean Absolute Error was reduced by 63.59% for Neural Networks in NY and 39.38% in TN.
  • Reliability (CPC): The Common Part of Commuters (measuring similarity between predicted and real flows) increased by 44.32% in NY.

Insights from the models reveal that while distance remains a primary "friction" for travel, socio-economic "attractors" like commerce and healthcare are essential for accurate modern modeling. Random Forest emerged as the most consistent "all-rounder," maintaining high accuracy across different trip lengths and states, while Neural Networks showed the highest peak performance in data-rich urban areas.

Conclusion and Future Work

This research demonstrates that integrating socio-economic features and machine learning can drastically improve the accuracy of transportation planning models. However, challenges remain regarding data sparsity in rural regions, where Neural Networks occasionally struggled. Future work will focus on integrating real-time data—such as live GPS feeds and weather conditions—to enable dynamic "now-casting" of trip demand and incorporating environmental impact metrics to support sustainable urban development.

Summary updated

BibTeX
@inproceedings{acharya2025data,
  author = {Kamal Acharya and Mehul Lad and Liang Sun and Houbing Song},
  title = {{A Data-Driven Approach to Enhancing Gravity Models for Trip Demand Prediction}},
  booktitle = {Cai},
  year = {2025},
}
Figure