A STOCHASTIC MODEL OF PASSENGER TRANSPORT
Klara Janglajew
Institute of Mathematics, University of Bialystok, 15-267 Bialystok, Poland
Olga Lavrenyk
Kiev National University of Economics, 252057 Kiev, Ukraine
Keywords:
Disctere stochastic system; Markov chain; Initial moments.
Abstract:
We develop a stochastic model in which a recursive formula is derived for computing the mean value of income
from sales of bus tickets. The model takes into consideration basic variable costs and the flow of passengers
is given by a Poisson process. The recursive formula for the mean income is in the form of a linear discrete
system with a random inhomogeneous part.
1 DESCRIPTION OF INITIAL
BOARDING OF THE BUS
We assume that the bus has q seats and that the num-
ber of passengers does not exceed q. Suppose that
the route consists of N segments and that the bus stop
only at the beginning of the route and at the stations
located at the end of each segment. Passengers board
the bus or get off from it only at the stations.
Let us denote by ξ
2n1
(n = 1, 2, . . . , N ) the num-
ber of passengers in the bus along the nth segment.
0 1
2
3
N-1
N
x1
x3
x5
x2N-1
In Fig. 1 we indicate the stops along the route on a line.
Let ξ
2n
(n = 1, 2, . . . , N) denote the number of
passengers remaining in the bus after some passen-
gers have left at the n th stop, but not counting the
new arrivals. Hence at the n th stop (ξ
2n+1
ξ
2n
)
new passengers board the bus. The random vari-
ables ξ
n
can assume (q + 1) different values θ
0
= 0,
θ
1
= 1, . . . , θ
q
= q with probabilities
p
k
(n) = P {ξ
n
= θ
k
} (k = 0, 1, . . . , q).
We introduce the vector of probabilities
P (n) = [p
0
(n), p
1
(n), . . . , p
q
(n)]
T
,
(n = 0, 1, 2, . . . , 2N ), dim P (n) = q + 1.
We assume that a stationary Poisson process de-
scribes the flow of passengers. If the bus waits at the
initial stop for a time t
1
and λ denotes the intensity
of the passenger flux then the number m passengers
boarding the bus during this time is given by the weel
— known formula (Ventcel, 1972)
P
m
=
a
m
m!
e
a
, a := λt
1
(m = 0, 1, 2, . . .).
Assume that the bus arrives at the initial stop with ξ
0
passengers. The probabilities of the different numbers
of passengers are given by the initial vector P (0) =
[p
0
(0), p
1
(0), . . . , p
q
(0)]
T
.
Let us introduce the stochastic matrix Π
0
(2) which
we will call the boarding matrix.
In the matrix Π
0
, to simplify the notation we have
γ
k
:=
k
X
s=0
a
s
s!
e
a
(k = 0, 1, . . . , q 1).
Then the equality
P (1) = Π
0
P (0) (1)
defines the vector P (1) = [p
0
(1), p
1
(1), . . . , p
q
(1)]
of probabilities of ξ
1
.
1
198
Janglajew K. and Lavrenyk O. (2004).
A STOCHASTIC MODEL OF PASSENGER TRANSPORT.
In Proceedings of the First International Conference on Informatics in Control, Automation and Robotics, pages 198-202
DOI: 10.5220/0001144601980202
Copyright
c
SciTePress
Π
0
=
e
a
0 0 . . . 0 0
ae
a
e
a
0 . . . 0 0
a
2
2!
e
a
ae
a
e
a
. . . 0 0
. . . . . . . . . . . . . . . . . .
a
q1
(q1)!
e
a
a
q2
(q2)!
e
a
a
q3
(q3)!
e
a
. . . e
a
0
1 γ
q1
1 γ
q2
1 γ
q3
. . . 1 γ
0
1
(2)
Π
1
(n) =
1 α
1
(n) α
2
(n) . . . α
q1
(n) α
q
(n)
0 1 α
1
(n) α
1
(n) . . . α
q2
(n) α
q1
(n)
0 0 1 α
1
(n) α
2
(n) . . . α
q3
(n) α
q2
(n)
. . . . . . . . . . . . . . . . . .
0 0 0 . . . 1
q1
X
s=1
α
s
(n) α
1
(n)
0 0 0 . . . 0 1
q
X
s=1
α
s
(n)
(3)
Π
2
(n) =
1
q
X
s=1
β
s
(n) 0 0 . . . 0 0
β
1
(n) 1
q1
X
s=1
β
s
(n) 0 . . . 0 0
β
2
(n) β
1
(n) 1
q2
X
s=1
β
s
(n) . . . 0 0
. . . . . . . . . . . . . . . . . .
β
q1
(n) β
q2
(n) β
q3
(n) . . . 1 β
1
(n) 0
β
q
(n) β
q1
(n) β
q2
(n) . . . β
1
(n) 1
(4)
Π(n) =
π
00
(n) π
01
(n) π
02
(n) . . . π
0q
(n)
π
10
(n) π
11
(n) π
12
(n) . . . π
1q
(n)
π
20
(n) π
21
(n) π
22
(n) . . . π
2q
(n)
. . . . . . . . . . . . . . .
π
q0
(n) π
q1
(n) π
q2
(n) . . . π
qq
(n)
(5)
A STOCHASTIC MODEL OF PASSENGER TRANSPORT
199
2 GETTING OFF AND
BOARDING AT THE STOP
There are ξ
2n1
passengers in the bus arriving at the
n th stop. Some of these passengers may get off.
The remaining member is denoted by ξ
2n
. Next some
new passengers board the bus and the total number
of passengers in the bus after boarding is denoted by
ξ
2n+1
. The time during which the bus waits be de-
noted by t
2n+1
. The probabilities for passengers leav-
ing the bus are related as
P (2n) = Π
1
(n)P (2n 1), (n = 1, . . . , N)
where the stochastic matrix Π
1
(n), for leaving the bus
has the form ( 3)
Here α
k
(n)denotes the probability of k passengers
getting off at the n th stop. Next we consider new
passengers boarding the bus at the n th stop. The
probability may be written by the vector equation
P (2n + 1) = Π
2
(n)P (2n), (n = 1, . . . , N ) (6)
where the stochastic matrix Π
2
(n) of boarding has the
form ( 4)
Here β
k
(n) denotes the probability of k passengers
boarding the bus at the n th stop.
It is clear that α
k
(n), β
k
(n) depend on the number
of the stop, since at some stops more passengers gett
off or board than at other stops. The coefficients
α
k
(n), β
k
(n), λ may be set by experiments
3 CALCULATION OF THE
INCOME FROM RUNNING THE
BUS
The waiting time of the bus at the n th stop will be
denoted by t
2n1
and the time for the run along the
n th segment of the route by t
2n
(n =
1, . . . , N).
We will take into account the expenses for paying
the driver. If the driver works for a time t, he is paid
p
1
= bt
where b is some coefficient.
If the bus runs for a time t, we assume that the cost of
the fuel consumed and other operating costs is given
by
p
2
= ct,
where c is some coefficient.
A passenger buy a ticket with the cost a.
The price of a ticket for a ride is assumed to be inde-
pendent of length of the ride.
If we denote by x
2n1
(n = 1, . . . , N) the income
derived from passenger transport at the beginning of
the n th segment of the route and by x
2n
the
income remaining at the end of the n th segment of
route, then we obtain the system of difference equa-
tions
x
1
= x
0
bt
1
+ a(ξ
1
ξ
0
), x
0
= 0
x
2
= x
1
(b + c)t
2
........................
x
2n1
= x
2n2
bt
2n1
+ a(ξ
2n1
ξ
2n2
)
x
2n
= x
2n1
(b + c)t
2n
, (n = 2, . . . , N )
(7)
with the random inhomogeneous part depending on
the Markov process ξ
n
.
4 OBTAINING THE MOMENT
EQUATIONS
Consider the system of difference equations (7) writ-
ten in general form by letting
x
n+1
= x
n
+ g(n, ξ
n+1
, ξ
n
) (n = 0, 1, 2, . . .) (8)
where ξ
n
is a Markov chain taking values θ
0
= 0,
θ
1
= 1, . . . , θ
q
= q.
Let
P (n + 1) = Π(n)P (n), dim P (n) = q + 1, (9)
where the stochastic matrix Π(n) has the form ( 5)
The density distribution of the system (x
n
, ξ
n
)
may be described by the generalised funktion
(K.G. Valeev, 1996)
f(n, x, ξ) =
q
X
k=0
f
k
(n, x)δ(ξ θ
k
). (10)
Funktions f
k
(n, x) (k = 0, . . . , q) are called the par-
ticular density disrtibutions. They may be defined by
the formula
P {x
n
< y, ξ
n
= θ
k
} =
Z
y
−∞
f
k
(n, x)dx (11)
(k = 0, 1, . . . , q).
We now obtain equations connecting particular den-
sity distributions (K. Janglajew, 2003)
P {x
n+1
< y, ξ
n+1
= θ
k
} =
Z
y
−∞
f
k
(n + 1, x)dx =
=
q
X
s=0
P {x
n+1
< y, ξ
n+1
= θ
k
, ξ
n
= θ
s
} =
=
q
X
s=0
P {ξ
n+1
= θ
k
|x
k+1
< y, ξ
n
= θ
s
} ×
× P {x
n
+ g(n, θ
k
, θ
s
) < y, ξ
n
= θ
s
} =
=
q
X
s=0
π
ks
(n)
Z
yg(n,θ
k
s
)
−∞
f
s
(n, x)dx.
ICINCO 2004 - SIGNAL PROCESSING, SYSTEMS MODELING AND CONTROL
200
By differentiating the following equation:
Z
y
−∞
f
k
(n + 1, x)dx =
=
q
X
s=0
π
ks
(n)
Z
yg(n,θ
k
s
)
−∞
f
s
(n, x)dx
with respect to y and replacing y by x we get the sys-
tem of equations
f
k
(n + 1, x) =
=
q
X
s=0
π
ks
(n)f
s
(n, x g(n, θ
k
, θ
s
)) (12)
(k = 0, 1, . . . , q).
Let us introduce the initial moments of a random vari-
able x
n
m(n) =
Z
−∞
xf(n, x)dx,
f(n, x) =
q
X
k=0
f
k
(n, x) (13)
d(n) =
Z
−∞
x
2
f(n, x)dx
and particular moments
m
k
(n) =
Z
−∞
xf
k
(n, x)dx (k = 0, 1, . . . , q),
m(n) =
q
X
k=0
m
k
(n)
d
k
(n) =
Z
−∞
x
2
f
k
(n, x)dx (k = 0, 1, . . . , q),
d(n) =
q
X
k=0
d
k
(n). (14)
Multiplying system (12) by x and integrating over in-
terval (−∞, ) we obtain the system
m
k
(n + 1) =
q
X
s=0
π
ks
(n)(m
s
(n) +
+ g(n, θ
k
, θ
s
)p
s
(n)) (15)
(k = 1, . . . , q; n = 0, 1, . . . , 2N). Similarly, we get
the system
d
k
(n + 1) =
=
q
X
s+0
π
ks
(n)(d
s
(n) + 2m
s
(n)g(n, θ
k
, θ
s
) +
+ g
2
(n, θ
k
, θ
s
)p
s
(n)) (16)
(k = 1, . . . , q; n = 0, 1, . . . , 2N). From system (15)
may be found the mean value m(2N ) of the income
variable x
2N
.
5 CALCULATION OF THE MEAN
VALUE OF THE INCOME
Consider the system (7) of difference equations with
random coefficient. The system of functional equa-
tions (12) for our model may be written in the form
f
k
(1, x) =
k
X
s=0
a
s
s!
e
a
f
ks
(0, x + bt
1
a(k s))
(k = 0, 1, . . . , q)
f
k
(2, x) =
=
³
1
k
X
j=1
α
j
(n)
´
f
k
(1, x + (b + c)t
2
) +
+
q
X
s=k+1
α
sk
(n)f
s
((1, x + (b + c)t
2
))
(k = 0, 1, . . . , q).
Analogously, we obtain
f
k
(2n 1, x) =
=
³
1
qk
X
j=1
β
s
(n)
´
f
k
(2n 2, x + bt
2n1
a(k s)) +
+
k
X
s=1
β
s
(n)f
ks
(2n 2, x + bt
2n1
a(k s)),
f
k
(2n, x) =
=
³
1
k
X
j=1
α
j
(n)
´
f
k
(2n 1, x + (b + c)t
2n
) +
+
q
X
s=k+1
α
sk
(n)f
s
(2n 1, x + (b + s)t
2n
)
(k = 0, 1, . . . , q; n = 2, . . . , N )
By using (14) we get
m(n) =
Z
−∞
xf(n, x)dx,
where f(n, x) =
q
X
k=0
f
k
(n, x),
m(n) =
q
X
k=0
m
k
(n).
Here the values m
k
(n) (k = 0, 1, . . . , q) are defined
by the system of difference equations
m
k
(1) =
k
X
s=0
a
s
s!
e
a
(m
ks
(0) +
+ (a(k s) bt
1
)p
ks
(0));
A STOCHASTIC MODEL OF PASSENGER TRANSPORT
201
m
k
(2) =
³
1
k
X
j=1
α
j
(n)
´
(m
k
(1)
(1 + c)t
2
p
k
(1)) +
+
q
X
s=k+1
α
sk
(n)(m
s
(1) (b + c)t
2
p
s
(1)),
m
k
(2n 1) =
³
1
qk
X
j=1
β
s
(n)
´
(m
k
(2n 2) +
+ (a(k s) bt
2n1
)p
k
(2n 2) +
+
k
X
s=1
β
s
(n)(m
ks
(2n 2) +
+ (a(k s) bt
2n1
)p
s
(2n 2));
m
k
(2n) =
³
1
k
X
j=1
α
j
(n)(f
k
(2n 1)
(b + c)t
2n
p
k
(2n 1)) +
+
q
X
s=k+1
α
sk
(n)(m
s
(2n 1)
(b + c)t
2n
p
s
(2n 1)) (17)
(n = 2, . . . , N ; k = 0, 1, . . . , q).
Using formulae (17) we may calculate the mean value
m(2N) for the income x
2M
. Similarly, it is possible
to calculate the second moment of the variable x
2N
by formulae of the form (16).
ACKNOWLEDGMENTS
We thank Prof. S.Twareque Ali ( Concordia Univer-
sity,Canada)for useful suggestions.
REFERENCES
K. Janglajew, K. V. (2003). Moments of solutions of lin-
ear difference equations. In ICDEA’03, 8th Interna-
tional Conference on Difference Equations and Ap-
plocations. To appear.
K.G. Valeev, O.L. Karelova, W. G. (1996). The Optimiza-
tion of Linear Systems with Random Coefficients. Rus-
sian University of Friendship of Nations, Moscow.
Ventcel, E. (1972). Operations Analysis. Soviet Radio,
Moscow.
ICINCO 2004 - SIGNAL PROCESSING, SYSTEMS MODELING AND CONTROL
202