04 - Trip Distribution Modeling - TDBM

04 - Trip Distribution Modeling - TDBM

Trip Distribution is the second step in the modeling stage of the classic 4 stage framework.

In terms of an O/D matrix like the following, in this step we try to model each and every dij:

d11d12d1nP1d21d22d2nP2dijdn1dn2dnnPnA1A2An

where:

Along this note, the number of trips from TAZ i to TAZ j will sometime be indicated with the symbol tij

Introduction

Trip distribution models are conceptually simple but give a hard time when we try to integrate them with the other models in the 4 stage process (for example, often, the sum of the number of trips from one zone does not add app to the modelled marginal total).

assumptions
  • Production (Pi) and attraction (Aj) for each zone is known by purpose

Notation

Lower case letters indicate observations:

tij,oi,dj

trips, trips originated, trips attracted

Uppe rcase letters represent values we are trying to model:

If a subscript or superscript is omitted, we are impying a summation over that index:

Tijn=kTijknT=ijTijt=ijtij

Key principles

Here we list some key principle of trip distribution models:

Trip distribution models

Gravity models

Gravity models are #Trip distribution models inspired by [[Newton's law of gravitational attraction]]
the model for gravitational attraction between two masses.

basic trip distribution gravity model

The basic gravity model is:
tij=kOiDjCijθ
where:

  • k: a constant
  • Oi: all trips generated from zone i (= to marginal total Pi)
  • Dj: all trips attracted to zone j (= to marginal total Aj)
  • Cij: generalized cost from zone i to zone j
  • θ: another parameter (if θ=2 then we have exactly the same form of Newton's law)

Variations of this model exist:

{tij=kOiDjeθCijtij=kOiαDjβCijγCobb-Douglastij=kOiαDjβeθCij

As we can see, these models have several parameters that need to be calibrated. At first, this might look like a difficult task:

tij=kOiαDjβCijθ

But, if we apply a logarithmic transformation on both sides, we can simply the calibration process:

log(tij)=log(kOiαDjβCijθ)==log(k)+αlog(Oi)+βlog(Dj)+θlog(Cij)

As we can see, this has now become a simple linear model in the form:

Yij=β1+β2X2+β3X3+β4X4

that can be easily estimated as a linear regression model.

We considered Oi,Dj,Cij known and we have a sample for tij. so we can find estimates for α^,β^,γ^.

As anticipated before, the issue with these kind of models is that the sum of the estimated t^ij along i or j does not always give the marginal totals. What we expect is:

Oi=jt^ijDj=it^ij

but this often does not happen. When this is the case singly or doubly constrained [[#Growth factors]] must be applied.

In order to predict future demand, growth factors are usually used

Growth factors

Uniform growth factor

The uniform growth factor is a simple way to predict future trips. Given data for a base year, we simply apply a growth of a certain percentage to every O/D pair.

The following table shows the base year trips:

Schermata 2025-04-01 alle 15.34.46.png

A growth factor of 20% (f) is applied. We calculate the future trips Tij from the base trips tij as:

Tij=ftij

Schermata 2025-04-01 alle 15.36.20.png

Singly constrained growth factor

The Singly constrained growth factor is used when marginal totals of either production or attraction are not equal to the sum of the corresponding tij.

The following examples assumes that there is a difference in the origin totals (Oi).

The base OD matrix is shown:

Schermata 2025-04-01 alle 15.40.15.png

Notice how Oi=jtij difference from the theoretical marginal total (the target in the table). For example, for TAZ 1, the ration between target and estimated origins is a1=1.13. Notice also how the ratio is different for each TAZ.

Let ai be the ratio for origin i, then we apply the following transformation:

Tij=aitij

and we get:

Schermata 2025-04-01 alle 15.43.23.png

After the transformation we can see that Oi is now always equal to the target.

observation

Since the Tij are expectations, they do not need to be integer numbers.

Doubly constrained growth factor - Biproportional Fitting (BPF)

The Doubly constrained growth factor is used when marginal totals of both production and attraction are not equal to the sum of the corresponding tij.

This method is also known under the name: Bi-proportional fitting (BPF).

We start from the following base O/D matrix:

Schermata 2025-04-02 alle 16.57.24.png

In this case there is not a direct method to obtain a single growth factor. The same process described in [[#Singly constrained growth factor]] is applied several time alternatively for Origins and destinations until we get acceptable ratios between the marginal totals and the targets.

Schermata 2025-04-02 alle 17.00.27.png

Limitations

Sparse matrices can cause problems when applying this method. If 0s are present, often the method will not converge. In this case, it is suggested to change these zeros to a low number of trips and try again.

Be careful though. It's important to distinguish between zeros by chance (sampling error) and structural zeros (there are some trips that cannot physically be made).

Synthetic distribution models

Synthetic distribution models are a kind of [[#Trip distribution models]] that generilize [[#Gravity models]] and try to bring more robust internal consistency. In their most general form:

Tij=AiOiBjDjf(Cij)

where:

Several functionals are proposed for the cost:

Notice how each of these functionals has one or more parameters that need to be calibrated. This is one of the main problems in applying this model.

Apply a synthetic distribution models

In this section we will see how to use #Synthetic distribution models to fill in the cells of an O/D matrix (calculate Tij).

We will describe the process for a general functional f(Cij) but keep in mind that the tables shown are using the functional f(Cij)=eβCij (for some value of β).

We start from a cost matrix. This matrix contains the cost Cij in the yellow cells. In the blue cells, the marginal totals Oi and Dj are shown.

Schermata 2025-04-02 alle 17.32.56.png

Now we apply the functional to the whole matrix: take any cell and calculate f(Cij). Whatch out, now the blue cells contain the sums of the yellow cells:

Schermata 2025-04-02 alle 17.36.07.png

Now we need to apply the #Doubly constrained growth factor - Biproportional Fitting (BPF) method. To do so, we need a starting matrix containing trips. We can obtain it multiplying everything by an expansion factor calculated as:

f=iOiif(Cij)jOjjf(Cij)

In this case, it would be:

f=343.44=19625.7128

Yielding:

Schermata 2025-04-02 alle 17.39.29.png

from this, the BPF method is applied and we get the following matrix (now every cell contains a value that represents the number of trips):

Schermata 2025-04-02 alle 17.40.32.png

Entropy models

Entropy models are based on the law of entropy:

tij=AiOiBjDjekCij

❗❗❗❗❗❗❗❗❗❗❗❗
❗❗❗ COMPLETARE ❗❗❗
❗❗❗❗❗❗❗❗❗❗❗❗

Hyman's method

When we #Apply a synthetic distribution models, we need to know the parameter of the cost functional f(Cij). In the case of

f(Cij)=eβCij

we can use Hyman's method to find the appropriate value of β.

To apply this method we need:

Assumptions:

As for other sections in this note, example numbers are shown in tables.

Let's assume we start from the following condition:

Schermata 2025-04-02 alle 17.50.48.png

We have marginal totals but no tij and a cost matrix (Cij). We also have a Mean Travel Cost MTL=10 (min).

We have to start with some value of β. We can set β0=1. Then we calculate β1 as:

β1=1MTL=0.1

Now we have all the information needed to apply the #Synthetic distribution models. We get the following matrix:

Schermata 2025-04-02 alle 17.55.02.png

Let's now check the value of Mean Travel Time that we get from this: MTL1. The Mean Travel Time is a weighted average of the travel costs using trips as weights. In this case:

MTL1=1563+9911++5812+156+99++58+=8.7

The expected value of MTL is 10. They are too different, we need another iteration

Now we set β2:

β2=MTL1MTLβ1=0.087

Calculate again the trip matrix as before and again MTL2. If the difference with MTL is still too big, then keep going. For following iterations, set β as:

βn=(MTLMTLn2)βn1(MTLMTLn1)βn2MTLn1MTLn2

For the example used so far we get:

β=0.0586

Schermata 2025-04-02 alle 18.00.45.png

Let n be the iteration counter. The Hyman's method can be summarized in the following steps.
Let

MTLn=ijTij(nCijijTij(n

n=0

n=1

n=2

n>2