Planning Public Transportation with Raku

Bergen Route 1

by Arne Sommer

Bergen Route 1

[159.4.1] Published 15. December 2021.

[ Introduction | Oslo Metro | Oslo Tram | Bergen | Misc. ]
[ Bergen Introduction | Route 1 | Route 2 ]

Bergen Light Rail Route 1

The Bergen Light Rail (or «Bybanen» in Norwegian) is a single line, with all the departures doing the full route, from Byparken (in the city centre) to the airport and vice versa.

The route can be summarised like this:

The trams use platform B (my designation) at Byparken if vacant, and A if not. At the airport the trams turn back after the station, so arriving trams use platform B and departing trams use platform A.

We start with the route definition file:

File: bergen-bybanen/01.def
#
# 1 Byparken - Bergen lufthavn
# --------------------------------------------------
BB001 B   B   Byparken 
BB002 B   A   Nonneseter
BB003 B   A:2 Bystasjonen
BB004 B:2 A:2 Nygård
BB005 B   A:2 Florida
BB006 B:3 A:2 Danmarks plass
BB007 B   A   Kronstad
BB008 B:2 A   Brann stadion
BB009 B   A:3 Wergeland
BB010 B:2 A   Sletten
BB011 B:2 A:2 Slettebakken
BB012 B:2 A:2 Fantoft
BB013 B:2 A:2 Paradis
BB014 B:2 A:2 Hop
BB015 B   A   Nesttun terminal
BB016 B:2 A:2 Nesttun sentrum
BB017 B   A   Skjoldskiftet
BB018 B   A:2 Mårdalen
BB019 B:2 A   Skjold
BB020 B:2 A:3 Lagunen
BB021 B:2 A:2 Råstølen
BB022 B:2 A:2 Sandslivegen
BB023 B:2 A   Kokstad
BB024 B   A:2 Birkelandsskiftet
BB025 B:2 A:2 Kokstadflaten
BB026 B:2 A   Bergen lufthavn

Rows staring with # are ignored. Use them to add comments for humans reading the file.

The first column is a unique stop identifier. It consists of two uppercase letters and three digits. The chosen letters «BB» stand for «Bergen Bybanen».

The second column is the platform in the Down direction (towards «Bergen lufthavn» in this case). The travel time from the previous stop is 1 minute, unless another value is specified after a colon.

The third column is the platform in the Up direction (towards «Byparken» in this case). See above.

The fourth column is the stop name. It can contain spaces, and some of them do.

See the Oslo Metro » Route 1 article for the full explanation of the syntax of this file.

File: bergen-bybanen-1a.setup
## Networkplanner ##

route set 1 file:01.def down:0 up:1 interval:5

summary 

Use the «down» argument to set the starting time of the first departure in the Down direction, and «up» argument to do the same for the Up direction. The default is 0. Use «interval» to set the interval (between departures). The default value is 10.

Running it:

$ networkplanner bergen-bybanen/bergen-bybanen-1a.setup

This gives the following summary:

Route 1: Byparken - Bergen lufthavn
----------------------------------------------------------------
00  | 00  05  10  15  20  25  30  35  40  45  50  55  Byparken [B]
01  | 01  06  11  16  21  26  31  36  41  46  51  56  Nonneseter [B]
02  | 02  07  12  17  22  27  32  37  42  47  52  57  Bystasjonen [B]
04  | 04  09  14  19  24  29  34  39  44  49  54  59  Nygård [B]
05  | 05  10  15  20  25  30  35  40  45  50  55  00  Florida [B]
08  | 08  13  18  23  28  33  38  43  48  53  58  03  Danmarks plass [B]
09  | 09  14  19  24  29  34  39  44  49  54  59  04  Kronstad [B]
11  | 11  16  21  26  31  36  41  46  51  56  01  06  Brann stadion [B]
12  | 12  17  22  27  32  37  42  47  52  57  02  07  Wergeland [B]
14  | 14  19  24  29  34  39  44  49  54  59  04  09  Sletten [B]
16  | 16  21  26  31  36  41  46  51  56  01  06  11  Slettebakken [B]
18  | 18  23  28  33  38  43  48  53  58  03  08  13  Fantoft [B]
20  | 20  25  30  35  40  45  50  55  00  05  10  15  Paradis [B]
22  | 22  27  32  37  42  47  52  57  02  07  12  17  Hop [B]
23  | 23  28  33  38  43  48  53  58  03  08  13  18  Nesttun terminal [B]
25  | 25  30  35  40  45  50  55  00  05  10  15  20  Nesttun sentrum [B]
26  | 26  31  36  41  46  51  56  01  06  11  16  21  Skjoldskiftet [B]
27  | 27  32  37  42  47  52  57  02  07  12  17  22  Mårdalen [B]
29  | 29  34  39  44  49  54  59  04  09  14  19  24  Skjold [B]
31  | 31  36  41  46  51  56  01  06  11  16  21  26  Lagunen [B]
33  | 33  38  43  48  53  58  03  08  13  18  23  28  Råstølen [B]
35  | 35  40  45  50  55  00  05  10  15  20  25  30  Sandslivegen [B]
37  | 37  42  47  52  57  02  07  12  17  22  27  32  Kokstad [B]
38  | 38  43  48  53  58  03  08  13  18  23  28  33  Birkelandsskiftet [B]
40  | 40  45  50  55  00  05  10  15  20  25  30  35  Kokstadflaten [B]
42  | 42  47  52  57  02  07  12  17  22  27  32  37  Bergen lufthavn [B]

Route 1: Bergen lufthavn - Byparken
----------------------------------------------------------------
00  | 01  06  11  16  21  26  31  36  41  46  51  56  Bergen lufthavn [A]
02  | 03  08  13  18  23  28  33  38  43  48  53  58  Kokstadflaten [A]
04  | 05  10  15  20  25  30  35  40  45  50  55  00  Birkelandsskiftet [A]
05  | 06  11  16  21  26  31  36  41  46  51  56  01  Kokstad [A]
07  | 08  13  18  23  28  33  38  43  48  53  58  03  Sandslivegen [A]
09  | 10  15  20  25  30  35  40  45  50  55  00  05  Råstølen [A]
12  | 13  18  23  28  33  38  43  48  53  58  03  08  Lagunen [A]
13  | 14  19  24  29  34  39  44  49  54  59  04  09  Skjold [A]
15  | 16  21  26  31  36  41  46  51  56  01  06  11  Mårdalen [A]
16  | 17  22  27  32  37  42  47  52  57  02  07  12  Skjoldskiftet [A]
18  | 19  24  29  34  39  44  49  54  59  04  09  14  Nesttun sentrum [A]
19  | 20  25  30  35  40  45  50  55  00  05  10  15  Nesttun terminal [A]
21  | 22  27  32  37  42  47  52  57  02  07  12  17  Hop [A]
23  | 24  29  34  39  44  49  54  59  04  09  14  19  Paradis [A]
25  | 26  31  36  41  46  51  56  01  06  11  16  21  Fantoft [A]
27  | 28  33  38  43  48  53  58  03  08  13  18  23  Slettebakken [A]
28  | 29  34  39  44  49  54  59  04  09  14  19  24  Sletten [A]
31  | 32  37  42  47  52  57  02  07  12  17  22  27  Wergeland [A]
32  | 33  38  43  48  53  58  03  08  13  18  23  28  Brann stadion [A]
33  | 34  39  44  49  54  59  04  09  14  19  24  29  Kronstad [A]
35  | 36  41  46  51  56  01  06  11  16  21  26  31  Danmarks plass [A]
37  | 38  43  48  53  58  03  08  13  18  23  28  33  Florida [A]
39  | 40  45  50  55  00  05  10  15  20  25  30  35  Nygård [A]
41  | 42  47  52  57  02  07  12  17  22  27  32  37  Bystasjonen [A]
42  | 43  48  53  58  03  08  13  18  23  28  33  38  Nonneseter [A]
43  | 44  49  54  59  04  09  14  19  24  29  34  39  Byparken [B]

The required number of vehicles

We need a file specifying how to set up the routes (or route, in this case):

File: bergen-bybanen/vehicles-1.def
=0100
1 D Byp/1;Byp   5
1 U Fle/1;Fle  10

The first row gives the number series for the vehicles.

The second row specifies the departure on route 1 in the Down (D) direction. The third field is the name to use in the vehicle list. If a second name is specified after a ;, that will be used on the arrival rows. («Fle» is short for Flesland, the name of the airport.) The fourth field is the minimum layover time (in minutes).

The modified setup file:

File: bergen-bybanen/bergen-bybanen-1b.setup
## Networkplanner ##

route set 1 file:01.def down:0 up:1 interval:5

summary

vehicles vehicles-1.def

Running it:

$ networkplanner bergen-bybanen/bergen-bybanen-1b.setup

The vehicles part of the output:

	      0101  0102  0103  0104  0105  0106  0107  0108  0109  0110  0111  0112  0113  0114  0115  0116  0117  0118  0119  0120  0121
-------------------------------------------------------------------------------------------------------------------------------------------
Byp/1	dep   0000  0005  0010  0015  0020  0025  0030  0035  0040  0045  0050  0055  0100  0105  0110  0115  0120  0125  0130  0135  0140 
Fle	arr   0042  0047  0052  0057  0102  0107  0112  0117  0122  0127  0132  0137  0142  0147  0152  0157  0202  0207  0212  0217  0222 
Fle/1	dep   0056  0101  0106  0111  0116  0121  0126  0131  0136  0141  0146  0151  0156  0201  0206  0211  0216  0221  0226  0231  0236 
Byp	arr   0139  0144  0149  0154  0159  0204  0209  0214  0219  0224  0229  0234  0239  0244  0249  0254  0259  0304  0309  0314  0319 
Byp/1	dep   0145  0150  0155  0200  0205  0210  0215  0220  0225  0230  0235  0240  0245  0250  0255  0300  0305  0310  0315  0320  0325 

0100: Number of vehicles: 21
---------------------------------------
Total number of vehicles: 21

It is easy to read out the layover times; 6 minutes at Byparken, and 14 minutes at the airport.

Saving Money

Let us see if we can save some money by reducing the number of vehicles. Let us try reducing the frequency from a tram every five minutes to one very six minutes:

File: bergen-bybanen/bergen-bybanen-1c.setup
## Networkplanner ##

route set 1 file:01.def down:0 up:1 interval:6

vehicles vehicles-1.def

Running it shows that we have reduced the number of required trams from 21 to 18. That is almost a 15% reduction.

	      0101  0102  0103  0104  0105  0106  0107  0108  0109  0110  0111  0112  0113  0114  0115  0116  0117  0118
-------------------------------------------------------------------------------------------------------------------------
Byp/1	dep   0000  0006  0012  0018  0024  0030  0036  0042  0048  0054  0100  0106  0112  0118  0124  0130  0136  0142 
Fle	arr   0042  0048  0054  0100  0106  0112  0118  0124  0130  0136  0142  0148  0154  0200  0206  0212  0218  0224 
Fle/1	dep   0055  0101  0107  0113  0119  0125  0131  0137  0143  0149  0155  0201  0207  0213  0219  0225  0231  0237 
Byp	arr   0138  0144  0150  0156  0202  0208  0214  0220  0226  0232  0238  0244  0250  0256  0302  0308  0314  0320 
Byp/1	dep   0148  0154  0200  0206  0212  0218  0224  0230  0236  0242  0248  0254  0300  0306  0312  0318  0324  0330 

0100: Number of vehicles: 18
---------------------------------------
Total number of vehicles: 18

The layover time at Byparken has increased to 10 minutes. We can reduce that by adjusting the departure times in one or both directions. Let us do it at the airport end:

File: bergen-bybanen-1d.setup
## Networkplanner ##

route set 1 file:01.def down:0 up:4 interval:6

vehicles vehicles-1.def

We have reduced the required number of trams by 1, and the layover time is still acceptable:

	      0101  0102  0103  0104  0105  0106  0107  0108  0109  0110  0111  0112  0113  0114  0115  0116  0117
-------------------------------------------------------------------------------------------------------------------
Byp/1	dep   0000  0006  0012  0018  0024  0030  0036  0042  0048  0054  0100  0106  0112  0118  0124  0130  0136 
Fle	arr   0042  0048  0054  0100  0106  0112  0118  0124  0130  0136  0142  0148  0154  0200  0206  0212  0218 
Fle/1	dep   0052  0058  0104  0110  0116  0122  0128  0134  0140  0146  0152  0158  0204  0210  0216  0222  0228 
Byp	arr   0135  0141  0147  0153  0159  0205  0211  0217  0223  0229  0235  0241  0247  0253  0259  0305  0311 
Byp/1	dep   0142  0148  0154  0200  0206  0212  0218  0224  0230  0236  0242  0248  0254  0300  0306  0312  0318 

0100: Number of vehicles: 17
---------------------------------------
Total number of vehicles: 17

Higher Frequency

Let us say that the demand (number of passengers) is higher on the part of the route nearest the city centre than towards the airport. Let us assume that it is possible to turn back at e.g. Lagunen, which has a siding.

We can set up a new route 9 for this, using the short running feature:

File: bergen-bybanen-9a.setup
## Networkplanner ##

route set 1 file:01.def down:0 up:1 interval:7.5
route set 9 file:01.def down:4 up:1 interval:7.5 end-at:BB020

summmary

vehicles vehicles-9a.def
File: bergen-bybanen/vehicles-9a.def
=0100
1 D Byp/1;Byp   5
1 U Fle/1;Fle  10

=0900
9 D Byp/1x;Byp   5
9 U Lag/1x;Lag  10

The whole output:

Route 1: Byparken - Bergen lufthavn
----------------------------------------------------------------
00  | 00  07' 15  22' 30  37' 45  52' Byparken [A]
01  | 01  08' 16  23' 31  38' 46  53' Nonneseter [A]
02  | 02  09' 17  24' 32  39' 47  54' Bystasjonen [A]
04  | 04  11' 19  26' 34  41' 49  56' Nygård [A]
05  | 05  12' 20  27' 35  42' 50  57' Florida [A]
08  | 08  15' 23  30' 38  45' 53  00' Danmarks plass [A]
09  | 09  16' 24  31' 39  46' 54  01' Kronstad [A]
11  | 11  18' 26  33' 41  48' 56  03' Brann stadion [A]
12  | 12  19' 27  34' 42  49' 57  04' Wergeland [A]
14  | 14  21' 29  36' 44  51' 59  06' Sletten [A]
16  | 16  23' 31  38' 46  53' 01  08' Slettebakken [A]
18  | 18  25' 33  40' 48  55' 03  10' Fantoft [A]
20  | 20  27' 35  42' 50  57' 05  12' Paradis [A]
22  | 22  29' 37  44' 52  59' 07  14' Hop [A]
23  | 23  30' 38  45' 53  00' 08  15' Nesttun terminal [A]
25  | 25  32' 40  47' 55  02' 10  17' Nesttun sentrum [A]
26  | 26  33' 41  48' 56  03' 11  18' Skjoldskiftet [A]
27  | 27  34' 42  49' 57  04' 12  19' Mårdalen [A]
29  | 29  36' 44  51' 59  06' 14  21' Skjold [A]
31  | 31  38' 46  53' 01  08' 16  23' Lagunen [A]
33  | 33  40' 48  55' 03  10' 18  25' Råstølen [A]
35  | 35  42' 50  57' 05  12' 20  27' Sandslivegen [A]
37  | 37  44' 52  59' 07  14' 22  29' Kokstad [A]
38  | 38  45' 53  00' 08  15' 23  30' Birkelandsskiftet [A]
40  | 40  47' 55  02' 10  17' 25  32' Kokstadflaten [A]
42  | 42  49' 57  04' 12  19' 27  34' Bergen lufthavn [A]

Route 1: Bergen lufthavn - Byparken
----------------------------------------------------------------
00  | 01  08' 16  23' 31  38' 46  53' Bergen lufthavn [B]
02  | 03  10' 18  25' 33  40' 48  55' Kokstadflaten [B]
04  | 05  12' 20  27' 35  42' 50  57' Birkelandsskiftet [B]
05  | 06  13' 21  28' 36  43' 51  58' Kokstad [B]
07  | 08  15' 23  30' 38  45' 53  00' Sandslivegen [B]
09  | 10  17' 25  32' 40  47' 55  02' Råstølen [B]
12  | 13  20' 28  35' 43  50' 58  05' Lagunen [B]
13  | 14  21' 29  36' 44  51' 59  06' Skjold [B]
15  | 16  23' 31  38' 46  53' 01  08' Mårdalen [B]
16  | 17  24' 32  39' 47  54' 02  09' Skjoldskiftet [B]
18  | 19  26' 34  41' 49  56' 04  11' Nesttun sentrum [B]
19  | 20  27' 35  42' 50  57' 05  12' Nesttun terminal [B]
21  | 22  29' 37  44' 52  59' 07  14' Hop [B]
23  | 24  31' 39  46' 54  01' 09  16' Paradis [B]
25  | 26  33' 41  48' 56  03' 11  18' Fantoft [B]
27  | 28  35' 43  50' 58  05' 13  20' Slettebakken [B]
28  | 29  36' 44  51' 59  06' 14  21' Sletten [B]
31  | 32  39' 47  54' 02  09' 17  24' Wergeland [B]
32  | 33  40' 48  55' 03  10' 18  25' Brann stadion [B]
33  | 34  41' 49  56' 04  11' 19  26' Kronstad [B]
35  | 36  43' 51  58' 06  13' 21  28' Danmarks plass [B]
37  | 38  45' 53  00' 08  15' 23  30' Florida [B]
39  | 40  47' 55  02' 10  17' 25  32' Nygård [B]
41  | 42  49' 57  04' 12  19' 27  34' Bystasjonen [B]
42  | 43  50' 58  05' 13  20' 28  35' Nonneseter [B]
43  | 44  51' 59  06' 14  21' 29  36' Byparken [A]

Route 9: Byparken - Lagunen
----------------------------------------------------------------
00  | 04  11' 19  26' 34  41' 49  56' Byparken [A]
01  | 05  12' 20  27' 35  42' 50  57' Nonneseter [A]
02  | 06  13' 21  28' 36  43' 51  58' Bystasjonen [A]
04  | 08  15' 23  30' 38  45' 53  00' Nygård [A]
05  | 09  16' 24  31' 39  46' 54  01' Florida [A]
08  | 12  19' 27  34' 42  49' 57  04' Danmarks plass [A]
09  | 13  20' 28  35' 43  50' 58  05' Kronstad [A]
11  | 15  22' 30  37' 45  52' 00  07' Brann stadion [A]
12  | 16  23' 31  38' 46  53' 01  08' Wergeland [A]
14  | 18  25' 33  40' 48  55' 03  10' Sletten [A]
16  | 20  27' 35  42' 50  57' 05  12' Slettebakken [A]
18  | 22  29' 37  44' 52  59' 07  14' Fantoft [A]
20  | 24  31' 39  46' 54  01' 09  16' Paradis [A]
22  | 26  33' 41  48' 56  03' 11  18' Hop [A]
23  | 27  34' 42  49' 57  04' 12  19' Nesttun terminal [A]
25  | 29  36' 44  51' 59  06' 14  21' Nesttun sentrum [A]
26  | 30  37' 45  52' 00  07' 15  22' Skjoldskiftet [A]
27  | 31  38' 46  53' 01  08' 16  23' Mårdalen [A]
29  | 33  40' 48  55' 03  10' 18  25' Skjold [A]
31  | 35  42' 50  57' 05  12' 20  27' Lagunen [A]

Route 9: Lagunen - Byparken
----------------------------------------------------------------
00  | 01  08' 16  23' 31  38' 46  53' Lagunen [B]
01  | 02  09' 17  24' 32  39' 47  54' Skjold [B]
03  | 04  11' 19  26' 34  41' 49  56' Mårdalen [B]
04  | 05  12' 20  27' 35  42' 50  57' Skjoldskiftet [B]
06  | 07  14' 22  29' 37  44' 52  59' Nesttun sentrum [B]
07  | 08  15' 23  30' 38  45' 53  00' Nesttun terminal [B]
09  | 10  17' 25  32' 40  47' 55  02' Hop [B]
11  | 12  19' 27  34' 42  49' 57  04' Paradis [B]
13  | 14  21' 29  36' 44  51' 59  06' Fantoft [B]
15  | 16  23' 31  38' 46  53' 01  08' Slettebakken [B]
16  | 17  24' 32  39' 47  54' 02  09' Sletten [B]
19  | 20  27' 35  42' 50  57' 05  12' Wergeland [B]
20  | 21  28' 36  43' 51  58' 06  13' Brann stadion [B]
21  | 22  29' 37  44' 52  59' 07  14' Kronstad [B]
23  | 24  31' 39  46' 54  01' 09  16' Danmarks plass [B]
25  | 26  33' 41  48' 56  03' 11  18' Florida [B]
27  | 28  35' 43  50' 58  05' 13  20' Nygård [B]
29  | 30  37' 45  52' 00  07' 15  22' Bystasjonen [B]
30  | 31  38' 46  53' 01  08' 16  23' Nonneseter [B]
31  | 32  39' 47  54' 02  09' 17  24' Byparken [A]



	      0101  0102  0103  0104  0105  0106  0107  0108  0109  0110  0111  0112  0113  0114
-------------------------------------------------------------------------------------------------
Byp/1	dep   0000  0007' 0015  0022' 0030  0037' 0045  0052' 0100  0107' 0115  0122' 0130  0137'
Fle	arr   0042  0049' 0057  0104' 0112  0119' 0127  0134' 0142  0149' 0157  0204' 0212  0219'
Fle/1	dep   0053' 0101  0108' 0116  0123' 0131  0138' 0146  0153' 0201  0208' 0216  0223' 0231 
Byp	arr   0136' 0144  0151' 0159  0206' 0214  0221' 0229  0236' 0244  0251' 0259  0306' 0314 
Byp/1	dep   0145  0152' 0200  0207' 0215  0222' 0230  0237' 0245  0252' 0300  0307' 0315  0322'

	      0901  0902  0903  0904  0905  0906  0907  0908  0909  0910  0911
-------------------------------------------------------------------------------
Byp/1x	dep   0004  0011' 0019  0026' 0034  0041' 0049  0056' 0104  0111' 0119 
Lag	arr   0035  0042' 0050  0057' 0105  0112' 0120  0127' 0135  0142' 0150 
Lag/1x	dep   0046  0053' 0101  0108' 0116  0123' 0131  0138' 0146  0153' 0201 
Byp	arr   0117  0124' 0132  0139' 0147  0154' 0202  0209' 0217  0224' 0232 
Byp/1x	dep   0126' 0134  0141' 0149  0156' 0204  0211' 0219  0226' 0234  0241'

0100: Number of vehicles: 14
0900: Number of vehicles: 11
---------------------------------------
Total number of vehicles: 25

We can combine the two routes at Byparken, so that trams arriving on one route departs on the other one:

File: bergen-bybanen-9b.setup
## Networkplanner ##

route set 1 file:01.def down:0 up:1 interval:7.5
route set 9 file:01.def down:4 up:1 interval:7.5 end-at:BB020

summary

vehicles vehicles-9b.def

Then we set up the route combination like this:

File: bergen-bybanen/vehicles-9b.def
=0100
1 D Byp/1;Byp   5
1 U Fle/1;Fle  10
9 D Byp/1x;Byp  5
9 U Lag/1x;Lag 10
	      0101  0102  0103  0104  0105  0106  0107  0108  0109  0110  0111  0112  0113  0114  0115  0116  0117  0118  0119  0120  0121  0122  0123  0124
-------------------------------------------------------------------------------------------------------------------------------------------------------------
Byp/1	dep   0000  0007' 0015  0022' 0030  0037' 0045  0052' 0100  0107' 0115  0122' 0130  0137' 0145  0152' 0200  0207' 0215  0222' 0230  0237' 0245  0252'
Fle	arr   0042  0049' 0057  0104' 0112  0119' 0127  0134' 0142  0149' 0157  0204' 0212  0219' 0227  0234' 0242  0249' 0257  0304' 0312  0319' 0327  0334'
Fle/1	dep   0053' 0101  0108' 0116  0123' 0131  0138' 0146  0153' 0201  0208' 0216  0223' 0231  0238' 0246  0253' 0301  0308' 0316  0323' 0331  0338' 0346 
Byp	arr   0136' 0144  0151' 0159  0206' 0214  0221' 0229  0236' 0244  0251' 0259  0306' 0314  0321' 0329  0336' 0344  0351' 0359  0406' 0414  0421' 0429 
Byp/1x	dep   0141' 0149  0156' 0204  0211' 0219  0226' 0234  0241' 0249  0256' 0304  0311' 0319  0326' 0334  0341' 0349  0356' 0404  0411' 0419  0426' 0434 
Lag	arr   0212' 0220  0227' 0235  0242' 0250  0257' 0305  0312' 0320  0327' 0335  0342' 0350  0357' 0405  0412' 0420  0427' 0435  0442' 0450  0457' 0505 
Lag/1x	dep   0223' 0231  0238' 0246  0253' 0301  0308' 0316  0323' 0331  0338' 0346  0353' 0401  0408' 0416  0423' 0431  0438' 0446  0453' 0501  0508' 0516 
Byp	arr   0254' 0302  0309' 0317  0324' 0332  0339' 0347  0354' 0402  0409' 0417  0424' 0432  0439' 0447  0454' 0502  0509' 0517  0524' 0532  0539' 0547 
Byp/1	dep   0300  0307' 0315  0322' 0330  0337' 0345  0352' 0400  0407' 0415  0422' 0430  0437' 0445  0452' 0500  0507' 0515  0522' 0530  0537' 0545  0552'

0100: Number of vehicles: 24
---------------------------------------
Total number of vehicles: 24

We saved one tram.

We can fix the problem with everything shown as using platform «B» at Byparken, as we now have two lines and can set them up to use one each:

File: bergen-bybanen-9c.setup
## Networkplanner ##

route set 1 file:01.def down:0 up:1 interval:7.5 start-at:BB001[A;B]
route set 9 file:01.def down:4 up:1 interval:7.5 start-at:BB001[B;A] end-at:BB020

summary

timingpoints timingpoints.def

vehicles vehicles-9b.def

The vehicle part has not changed:

	      0101  0102  0103  0104  0105  0106  0107  0108  0109  0110  0111  0112  0113  0114  0115  0116  0117  0118  0119  0120  0121  0122  0123  0124
-------------------------------------------------------------------------------------------------------------------------------------------------------------
BypA/1	dep   0000  0007' 0015  0022' 0030  0037' 0045  0052' 0100  0107' 0115  0122' 0130  0137' 0145  0152' 0200  0207' 0215  0222' 0230  0237' 0245  0252'
Fle	arr   0042  0049' 0057  0104' 0112  0119' 0127  0134' 0142  0149' 0157  0204' 0212  0219' 0227  0234' 0242  0249' 0257  0304' 0312  0319' 0327  0334'
Fle/1	dep   0053' 0101  0108' 0116  0123' 0131  0138' 0146  0153' 0201  0208' 0216  0223' 0231  0238' 0246  0253' 0301  0308' 0316  0323' 0331  0338' 0346 
BypB	arr   0136' 0144  0151' 0159  0206' 0214  0221' 0229  0236' 0244  0251' 0259  0306' 0314  0321' 0329  0336' 0344  0351' 0359  0406' 0414  0421' 0429 
BypB/1x	dep   0141' 0149  0156' 0204  0211' 0219  0226' 0234  0241' 0249  0256' 0304  0311' 0319  0326' 0334  0341' 0349  0356' 0404  0411' 0419  0426' 0434 
LagA	arr   0212' 0220  0227' 0235  0242' 0250  0257' 0305  0312' 0320  0327' 0335  0342' 0350  0357' 0405  0412' 0420  0427' 0435  0442' 0450  0457' 0505 
LagB/1x	dep   0223' 0231  0238' 0246  0253' 0301  0308' 0316  0323' 0331  0338' 0346  0353' 0401  0408' 0416  0423' 0431  0438' 0446  0453' 0501  0508' 0516 
BypA	arr   0254' 0302  0309' 0317  0324' 0332  0339' 0347  0354' 0402  0409' 0417  0424' 0432  0439' 0447  0454' 0502  0509' 0517  0524' 0532  0539' 0547 
BypA/1	dep   0300  0307' 0315  0322' 0330  0337' 0345  0352' 0400  0407' 0415  0422' 0430  0437' 0445  0452' 0500  0507' 0515  0522' 0530  0537' 0545  0552'

0100: Number of vehicles: 24
---------------------------------------
Total number of vehicles: 24
File: bergen-bybanen/timingpoints.def
Byparken
Lagunen
Bergen lufthavn

Note the use of stop names. You can also use stop IDs.

The timingpoint part of the output:

Bergen lufthavn [A]
 04' 12  19' 27  34' 42  49' 57   1 Bergen lufthavn

Bergen lufthavn [B]
 01  08' 16  23' 31  38' 46  53'  1 Byparken

Byparken [A]
 00  07' 15  22' 30  37' 45  52'  1 Bergen lufthavn
 02  09' 17  24' 32  39' 47  54'  9 Byparken

Byparken [B]
 04  11' 19  26' 34  41' 49  56'  9 Lagunen
 06' 14  21' 29  36' 44  51' 59   1 Byparken

Lagunen [A]
 01  08' 16  23' 31  38' 46  53'  1 Bergen lufthavn
 05  12' 20  27' 35  42' 50  57'  9 Lagunen

Lagunen [B]
 01  08' 16  23' 31  38' 46  53'  9 Byparken
 05' 13  20' 28  35' 43  50' 58   1 Byparken

The layover time at Byparken is 5 (route 9 ⇾ 1) and 5.5 (route 1 ⇾ 9) minutes.

The layover time at Lagunen is 11 minute.

Route 9 arrives at Lagunen platform B at 05 minutes past the hour. Route 1 departs from platform A 05,5 minutes. (The previous tram in route 9 departs from the siding at 06 minutes, and arrives at platform A at 07 minutes.) The current tram on route 9 departs from platform B at 07.5 minutes, and arrives in the siding at 08.5 minutes. Then route 1 arrives at platform B at 08.5 minutes.

The next thing that happens is that the next route 9 arrives at platform B at 12.5 minutes, and route 1 arrives at platform A at 13 minutes. Route 1 departes, the previous route 9 departs from the siding, and the current route 9 departs to the siding.

It works, theoretically.

Lagunen ⇆ Råstølen
The very next stop (Råstølen) has a much better layout, with a third track in the middle. This makes it possible to terminate without blocking both tracks when turning back (as at Lagunen).

The travel time between these two stops is 2 minutes, in both directions. Let us see how that turns out, for our route 9:

Route 9 arrives at platform C at 07 minutes, and departs at 14 minutes. 7 minutes should be ok. The next route 9 arrives at 14.5 minutes. That is tight, but much more robust than terminating at Lagunen.

I'll leave it as an excercise for the readers to amend the files so that route 9 terminates at Råstølen.

Bergen currently has 28 light rail vehicles, so my modified network is feasible. Until Route 2 opens in late 2022.

[ Introduction | Oslo Metro | Oslo Tram | Bergen | Misc. ]
[ Bergen Introduction | Route 1 | Route 2 ]