The International Simutrans Forum

Development => Extension Requests => Topic started by: VS on November 26, 2008, 08:29:39 PM

Title: Boarding-only stops, intercity route settings, etc...
Post by: VS on November 26, 2008, 08:29:39 PM
I was asked to post this FR, since the original author can't/doesn't want/whatever.

In short: when loading things onto vehicle, cargo to farther locations should have higher priority, since it ensures higher profit. If cargo to near stations is loaded first, vehicle can unload it soon and complete the rest of route empty.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Tomas on November 26, 2008, 08:54:00 PM
+1 (I agree)
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Zeno on November 26, 2008, 08:56:23 PM
If possible, it would be great... but IMHO won't be very realistic.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: the almighty snark on November 26, 2008, 09:25:36 PM
Maby you should be able to set this as a option for a line or schedule.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Giziar on November 26, 2008, 10:23:22 PM
I can imagine the advantages/disadtvantages of both systems.

If you have a system where you have 2 schedules to the end destination, one of them skipping most stations while the other as stoptrain (AH vs ABCDEFGH) then it would be nasty if the stoptrain gets filled with ppl wanting to go to H

If you have a system where schedules share a part of the same route and then go their own way (ABCDEFGH vs ABCDIJKL) it would be most beneficial that the farthest destinations get filled first.

I generally tend to use the 2nd system more than the first one so I would be in favour of this.
However if it's something that could be set as an option of a line: support^2.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: yoshi on November 26, 2008, 10:24:24 PM
At least untill a few years ago, Simutrans had behaved so I think. But it was changed, because some people complained that express trains have few passengers.


For example, if you have two train routes as the following.

Express A - - - - - - - - - F
Local    A - B - C - D - E - F
And A and F are larger cities obviously (this is why express trains serve these stations).

In this case, if the local trains pick up long distance passengers first, then the local trains will be filled up with passengers going to F and are less likely to carry passengers to B. And the express trains will have less passengers.


But of course, if you don't have express routes, this would be more efficient.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: z9999 on November 27, 2008, 08:21:57 AM
As yoshi wrote, it was changed.
I like current behavior, so I don't support this idea.

history.txt
Quote
Release of 86.07

13-Jul-2005 (prissi)
   CHANGE: passengers and goods are first loaded for the nearest stations the convoi goes. This allows to built local and station skipping highspeed lines.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: yoshi on November 27, 2008, 10:46:56 AM
I don't support, either.
But you can change the behaviour for each convoi (or each line), then I would support.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: VS on November 27, 2008, 10:48:25 AM
Oh, now I understand.

Still, as a switch per schedule it sounds reasonable…?
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: prissi on November 27, 2008, 09:31:09 PM
Not really, the load first is way more efficent. The old system was load first waiting goods first. That way, if your stuff wait really long, it was almost never loaded, since new stuff was inserted at the list top.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: VS on November 27, 2008, 09:56:09 PM
Hm, but what we are discussing here is a system working exactly opposite to the current. When I can, I will look at code, maybe it can be as simple as iterating backwards from end? Let's hope :)
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: prissi on November 27, 2008, 10:19:44 PM
You must iterate twice: First make sure you are not passing the same station twice and then start from before that entry. Apart from that things woul dbe identical. But since it break the concept of express lines, I would rather say, that this is not the right place to fix problems which are the innermost incentive to gaming. Imho, it is the task of the player to upgrade capacity, that this problem is solved (and a direct line would solve it with the current system, while with the proposed system all intermediate stops will be clogged until there is overcapacity on the express route).
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: VS on November 27, 2008, 10:39:30 PM
Very well, now I see why this is important to always stay that way...
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: isidoro on November 28, 2008, 04:06:18 AM
Both ways (old and new) have problems, because both can lead to starvation (if there is a steady flow of high priority people/goods, low priority ones accumulate).  That's a known problem with static priorities.

A (somewhat) crazy idea just occurs to me:
  - Take passengers/goods of the group with higher number waiting

If a vehicle is at A and its route is A-B-C-D and the people waiting to go to B is 100, to C is 300, to D is 200, take people going to C.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: colonyan on November 28, 2008, 04:38:47 AM
That sounds reasonable isidoro!
support.+
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: yoshi on November 28, 2008, 04:57:37 PM
A (somewhat) crazy idea just occurs to me:
  - Take passengers/goods of the group with higher number waiting

If a vehicle is at A and its route is A-B-C-D and the people waiting to go to B is 100, to C is 300, to D is 200, take people going to C.

Then the route is likely to be filled up with passengers (or goods) going to the largest city (or largest consumer) among these. This cannot be a solution for this issue...
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: isidoro on November 29, 2008, 12:13:39 AM
This is a different problem, in my opinion.

If the total amount of generated pass/goods generated is over the capacity of the transport system to deliver it, pass/goods will accumulate, no matter what will be given priority.

The problem addressed is different. If priority is only based on distance to the station, it is easy that some vehicles steal pass/goods from other more specialized ones (express trains, quick connections, ...), no matter the way we give priority.  Giving priority to accumulating goods, those vehicles will steal pass/goods only if there is a lot.

Think the other way around: if we serve the smallest quantity, then all goods for the big city/consumer will not get completely through as well.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: yoshi on November 29, 2008, 01:55:27 AM
Unfortunately, I'm talking about the very problem addressed in this thread.

Take an example above.

Express A - - - - - - - - - F
Local    A - B - C - D - E - F

And let's assume A is the largest city, while F is the second largest.


With the current loading system, convois serving the local services take passengers going to B, C, D, and E first and they carry passengers to F if there is any spare capacity, but they don't need to. Therefore, the number convois seving the local line can be minimal. And the convois serving the express line simply need to carry the leftover of the local services. And the number of the "leftover" is relatively stable.

But with your proposed loading system, local services will be likely to be filled up with passengers going to F first, because the number of passengers going to F is simply larger than that of passengers going to other destinations. This means the number of convois serving the local line will be surely larger than the above case to carry all the passengers to B - E. In addition, express route will become less profitable, since the number of "leftover" will fluctuate, depending on which passengers the preceding local convois load first.


In short, your proposal will be likely to reduce the utilisation rate of the convois.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: isidoro on November 30, 2008, 05:28:33 AM
I'm not convinced about what you say.  For two reasons:
  • In your example, the main objective of the express line is to take care of that surplus.  So, if there is accumulation of those passengers, simply increase the number of vehicles of the express line.  Local line vehicles will help only when there is surplus for F.  If they keep helping too much and the number of vehicles are enough (that second clause is the difference between our positions, I think), the number of passengers to B, C, D, and E will grow and take precedence (aging mechanism)
  • The second reason is choosing another example in which C is the large city and the express line goes directly to C:  A --> C.  With the present system and following your same reasoning D, E, and F will not be served.  Am I right?
Though I may be wrong.  My intuition tells me that if I had a transportation office and packets for a certain destination accumulated, I would try to send them asap in whatever vehicle that could handle them.

I think the best way to test it is making a patch.  If I have time, I will try and see.  Just curious about if my intuition is right or wrong.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Fabio on November 30, 2008, 10:23:41 AM
But you can change the behaviour for each convoi (or each line), then I would support.

this would be great!
an option local/far distance line to be set for each line in line management...
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: yoshi on November 30, 2008, 10:25:47 AM
Quote
The second reason is choosing another example in which C is the large city and the express line goes directly to C:  A --> C.  With the present system and following your same reasoning D, E, and F will not be served.

If C is a large city, then I would have an express service which skips B like A---C-D-E-F and local service between A and C, because most passengers to D, E, & F originate from A and C and the number of passengers between A and C is large. I could add non-stop services only between A and C as well, if neccesary. Anyway, there is no point to operate long distance local services, if there is an express route, because it's a waste of money.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: The Hood on November 30, 2008, 01:10:27 PM
Quote from: yoshi on November 27, 2008, 11:46:56 AM
But you can change the behaviour for each convoi (or each line), then I would support.

this would be great!
an option local/far distance line to be set for each line in line management...

I would definitely support this - you could make expresses load from farthest to nearest and locals from nearest to farthest.  It would add more flexibility and improve gameplay IMHO, so therefore a good idea.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: hradtom on November 30, 2008, 07:05:38 PM
Thank you for discussion. It would be great, if there will be a switch to load first farther/nearer destinations.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: z9999 on December 01, 2008, 08:05:15 AM
A (somewhat) crazy idea just occurs to me:
  - Take passengers/goods of the group with higher number waiting

I have a converse view about this.
IMHO, take lower number waiting fitst is more useful for goods and passengers.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Combuijs on December 01, 2008, 09:03:51 AM
Quote
take lower number waiting fitst is more useful for goods and passengers.

And that's version number four!

Is this just me, or is the solution to this problem really simple?

Presumptions:
1) Profits are for all passengers relatively the same (2*distance -> 2*profit)
2) Vehicle load percentages are (close to) 100%

Situations:
A) There is only one connection between two cities
B) There are two connections between cities: one express (no intermediate stops) and one with intermediate stops.

Conclusions
A) It absolutely does not matter whatever system you choose, every passenger needs to be transported. In which order you do that is irrelevant.
B) For the express-connection to work you need the current system (start loading with passengers for the nearest stop).

General conclusion:
The current system is the best of all the alternatives.

If the connections are not working well (passenger overflow at stations or vehicle load percentage way under 100%) tune the capacity of the connections. Fiddling with loading orders won't help you.

Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Sarrus on December 01, 2008, 10:07:40 AM

Still, as a switch per schedule it sounds reasonable…?
I think this is an idea, that can satisfy everyone.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: hradtom on December 01, 2008, 10:14:20 AM
to Combuijs:

You don't have right. There is situation C), usual in city local traffic:
there are two lines:
LONG: A-B-C
SHORT: A-B (because there is more passengers to be transported between A and B)

Then the problem is, that I could not influence the timetable. When comes the LONG line first, it loads passengers from A to B and is full between A and B, and empty between B and C. The SHORT line is then empty between A and B (because passengers used the LONG line).

Do you understand?
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Combuijs on December 01, 2008, 11:23:20 AM
Quote
Do you understand?

Yep, I do. It's a valid example. I personally would have solved this by making two lines:

A-B
B-C (or A-C, or even both)

which is far easier to configure in terms of capacity. But your example may have advantages as well (no extra hop for passengers).

So two solutions make sense: load nearest first and load farthest first. The other two (taking lowest/highest number of passengers for a destination first) are only useful when you are lacking capacity, so they can be better solved by increasing capacity.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: hradtom on December 01, 2008, 12:08:18 PM
Combuijs wrote: So two solutions make sense: load nearest first and load farthest first. The other two (taking lowest/highest number of passengers for a destination first) are only useful when you are lacking capacity, so they can be better solved by increasing capacity.

Agree. The switch to load nearest/farthest destination first should be useful. The switch should be defined for the line.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: colonyan on December 01, 2008, 01:22:41 PM
The best would be treating the passenger with their arrived order. I guess we don't have this because the program will have to remember more information.

The switch to load nearest/farthest destination first should be useful. The switch should be defined for the line.

I have to disagree with being able to switch the load nearest/farthest depending on the line. Passenger are to be served and not to be "ordered" to take or wait until which train.

I see this way.

We can not afford to treat passenger in their arriving order because of process power of cpu.
                                                           V
Then we've decided to treat from the nearest assuming that's passengers behavior as customer.
                                                           V
Forcing passengers behavior seems little odd from my view of this simutrans. I believe as one company,
they should treat customer evenly. Not prioritizing some of them to the interest of company.
Company should work to follow the customer's behavior.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Magic_Gorter on December 01, 2008, 04:03:00 PM
I agree with you colonyan. The game should behave as it would be in real life. So the passengers/goods who wait longest should be first on the train.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: wernieman on December 01, 2008, 04:16:02 PM
The problem is ....

At every time come passenger.

When there a passanger want to A, and some for A come, then all passenger to A will get a group ... so you don't know if they wait long ore not ....

I think, it is not good to change how simutrans load the trains ...
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: DirrrtyDirk on December 01, 2008, 04:21:32 PM
And you should consider the increase in memory and processing time any new method would probably generate on big and well developed maps with thousands and thousands of passengers. Some things just need to simplified quite a bit to be still playable and can't be done all that realistically.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Magic_Gorter on December 01, 2008, 04:35:39 PM
I do understand that's probably not possible to program. But to build those options (near/far) shouldn't be build in because it's far from realistic...so stay with the way it's right now..
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: VS on December 01, 2008, 04:55:40 PM
...except that now, it is set to "near"...
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: hradtom on December 01, 2008, 05:03:00 PM
Magic_Gorter wrote: But to build those options (near/far) shouldn't be build in because it's far from realistic so stay with the way it's right now..

DISAGREE! The current alghoritm is to load passengers to nearest stations and it's not realistic at some lines (see LONG line A-B-C and SHORT line A-B), although the other option (farther stations first) should be good.

On the other hand, there are lines, where current system (nearest stations first) is good (for example EXPRESS A-C and LOCAL A-B-C).

Why do you protest against the switch? If the switch will be programmed, you could switch all your lines to load nearest station first and that's what you want (stay with the way it's right now). But someone (like me) should improve his line system with using the other option (far station first) on some lines.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: joecz on December 01, 2008, 05:49:19 PM
To this subject I have two ideas:
1.  I think we could handle goods and passengers differently. The option to load goods to farthest destination first is more profitable. But it gets in conflict with express lines, so passengers' transportation could keep to loading nearest destination.
2.  I thought about the idea of loading the passengers who are in the largest group of destination. (100 to A, 10 to B -> load first passengers to A, then to B) My idea is, that the train (assuming capacity of 50) loads 100/110*50=45 passengers to A and 10/110*50=5 passengers to B. (The problem of exactly half passengers could be solved by rounding down x.5 and just loading another passenger to A.)
What do you think?
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: micslu on December 01, 2008, 06:52:19 PM
Windows GDI 99.18-1727 + Pak128 - free play option (no bankruptcy  ;))

I've experienced many times sudden surge of passengers to certain stops on bus/tram routes.
(Most likely because I wasn't paying attention to that terminal  ???)

A - B - C - D - E - F
where passengers waiting at A and also at B & C & D ... grow into hundreds and even thousands at A
for destination F and there are still numerous passengers from A to B - C - D - E as well.
With bus routes, easiest solution is adding more buses to the route until the queue stabilized.
But with tram route, running more trams on the same line require signal hassle (which I don't care for).

My solution turned out to build a separate tram line A to F (I have money!) with a separate tram stop
at A, make this Tram#2 express A - F, scheduled at A to wait for 100% load.
All new passengers generating at A going to F would load to Tram#2 while Tram#2 is at A
(and therefore will load onto the local stops Tram#1 when #2 is away).

Sorry to be long-winded but above seems to be one of the solutions to passenger loading sequence.
However, this is only easy with Tram that can share the stop with Buses. Otherwise, a dedicated
train platform or bus stop that will block any other train or bus is needed while waiting to fill
set capacity. Adding another rail line and platform can be a major redevelopment work in built up areas!

Ciao!
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: prissi on December 01, 2008, 07:54:07 PM
Switching is not easy (as is has to be stop and line dependent) and handling passenger different from other goods is not desirable, to keep overall consitency. As said before an overflowing line will overflow with any combination. Provide better service is the task of the player. Routing passengers is not.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: isidoro on December 02, 2008, 01:51:59 AM
How nice! What an interesting discussion! Here's a summary of possibilities:

Situation: a vehicle arrives and there's more cargo to be loaded than its capacity.
Variables to choose from: distance to destination, amount waiting (imagine if we add more)
Ideal possibility: choose the ones waiting more time (not feasible)
Possibilities:
  • Farthest destinations first (old method)
  • Nearest destinations first (present method)
  • Highest amount first
  • Lowest amount first
  • Proportional to the amount waiting

I'm against the first, the second and fourth because it can easily lead to starvation (pure priority, some destinations will never be served).  Third includes a feedback mechanism so that all can get a chance to be served.  That's more important, I think, for goods.  If one of the starvation destinations is a factory that is the head of a chain, all the chain will not produce.  For passengers, they will accumulate, but I think it is not so important.  Not to stop this beautiful thread (independently of if any method will or will not get to simutrans code), another possibility not too expensive which effectively avoids starvation:

At each station, there is a mark in the list saying from which destination it was extracted cargo last time.  We start our search on the following destination until we load our vehicle.

And a last one, cheaper still, choose it at random.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: z9999 on December 02, 2008, 09:01:15 AM
What an interesting discussion!

I don't think so.  ;D
Each player has each playing style. Your priority might not be the same for other player. And each situation is different, it is impossible to prioritize in accordance with distance or amount.

I'm dealing with current system, and don't need alternative.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: VS on December 02, 2008, 11:12:34 AM
I can see easily how Isidoro's #3 is the same as #4. In principle, if you assume the capacity of link is between the highest and lowest amount, it works. However, as soon as it is insufficient even for the lowest amount… I will do some simulations and come back.

Hm... just to add something less subjective to discussion: time-based, serving oldest, equals fifo, which is by nature unsorted, except by its function & design, so it might win performance-wise (even over random?). Just append as it comes and it's already sorted as you want.

And it was interesting... at least showed we are as a community capable of polite disagreement! :)



Well. The first simulation was helpful, but didn't cover all possibilities. I tested the "first largest amount" and "first smallest" variants, where all destinations with varying amount of passengers are served by one line. I can't attach any resulting data, as they would be a great number of charts - these show how the amounts progress, and interpreting them is "human only" - which lines rise steadily (no serving), if the highest one changes etc.

I tried to simulate "corner cases" when the transport capacity is more or less as much as needed. Of course with too many or too few vehicles it degenerates to all waiting or all transported :)

Smallest first leads to smaller serving of the fastest rising amounts, so there are a few destinations literally exploding, and the rest oscillates in negligible amounts, compared to these.

Largest first has exactly opposite effect - it equalizes amounts of waiting cargo, so the numbers visible in station are all the same. However, the smallest rising destinations never reach the top, and thus just rise with the rest, never transported.

I don't know what it means for the discussion...

MATLAB source:
Code: [Select]
¨% test for Simutrans - passenger transport

cycles = 20; % how many periods
dests = 5; % how many destinations
freq = 10; % how many "ticks" between transport arrives
capacity = 80; % how much can the transport take

data = zeros(dests, cycles * freq); % preallocate the stats

increase_var = rand(dests, 1) * 10; % coefficient, how much psg to different destinations

data(:, 1) = round(increase_var); % fill first row

for i = 2 : cycles * freq
    data(:, i) = data(:, i - 1) + round(rand(dests, 1) .* increase_var); % add more random psg
    if mod(i, freq) == 0 % transport has arrived
        remaining = capacity;
        j = dests;
        tmp = data(:, i);
        [foo, ind] = sort(tmp, 'descend'); % see below:
        % 'descend' -> smallest amount first (j iterating backwards!)
        % 'ascend' -> highest amount first
        % foo is redundant, only indexes are important
        while (remaining > 0) && (j > 0) % until vehicle full or station emptied completely
            k = ind(j); % true index in main data (and tmp, too)
            if tmp(k) >= remaining
                amt = remaining;
            else
                amt = tmp(k);
            end;
            data(k, i)= data(k, i) - amt;
            remaining = remaining - amt;
            j = j - 1;
        end;
    end;
end;

plot(data'); % oops, wrong direction of matrix... rotate

Next simulation... assign destinations distances and sort according to them.
EDIT: Hehe, no interesting results from this. Only that the last served stations have best chance to get crowded, which we knew before :-\

Maybe here the simulation should be different, more competing lines?
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Combuijs on December 02, 2008, 02:01:57 PM
Quote
Maybe here the simulation should be different, more competing lines?

Yes, because when there is only one line the loading order does not matter. The station gets overcrowded if vehicle capacity is too low, and if vehicle capacity is enough, then everyone will get transported.

The problems start with competing lines. If the vehicle capacity in total is enough, you still might get passenger starvation if you use the wrong loading order. Say you have two big cities B1 and B2 and one small city S (might be more than one).

Case 1:
B1 - S - B2 (train with intermediate stops)
B1 - B2 (express train)
In this case you want to load passengers in B1 for the first stop first in order to get an efficient express train

Case 2:
B1 - B2  - S
B1 - B2
In this case you want to load passengers in B1 for the last stop first in order to get an efficient intermediate stops train

Maybe you can simulate this. As I have said before, if vehicle capacity is sufficient then the variants with lowest or highest number of passengers first are not needed, as they can't be better.
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: prissi on December 02, 2008, 10:36:37 PM
well, but knowing, that first stop loading first, I can adjust my schedule appropriately ...
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: isidoro on December 03, 2008, 12:43:44 AM
Very interesting... we have some facts now...

Hm... just to add something less subjective to discussion: time-based, serving oldest, equals fifo, which is by nature unsorted, except by its function & design, so it might win performance-wise (even over random?). Just append as it comes and it's already sorted as you want.

Though it is quicker, it requires more memory and, with caches and paging, more memory can also mean slower.  In simutrans, when new cargo arrives at a station, it is accumulated to the equivalent cargo already waiting at the station.  This, in my opinion, should stay as is for performance reasons.

Largest first has exactly opposite effect - it equalizes amounts of waiting cargo, so the numbers visible in station are all the same. However, the smallest rising destinations never reach the top, and thus just rise with the rest, never transported.

Wonderful.  I didn't think about that.  So the aging mechanism doesn't really work in some configurations.

I think that variations (derivatives) may play an important role.  For each of your program's cycles, there has been a variation in amounts (difference between what quantity was at the end and what quantity was at the beginning).  We want a situation in which the addition of all that differences are more or less the capacity of the lines serving that station.  Should those differences be taken into account to give priorities?

There is a situation similar to this that used to make me make a mistake when beginning playing simutrans.  If you don't pay attention to a station for some time, maybe that station gets 100000 passengers waiting, for instance.  Then, I used to buy a lot of vehicles to transport all those passengers.  But that is an error because when that surplus is exhausted, there are way too many vehicles for the necessities.  The important thing is not the number of passengers waiting but the comparison in a given time of the passengers added to the station and the passengers transported by the vehicles in that same period...
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: Sarrus on December 03, 2008, 10:41:21 AM
Forcing passengers behavior seems little odd from my view of this simutrans. I believe as one company,
they should treat customer evenly. Not prioritizing some of them to the interest of company.
Company should work to follow the customer's behavior.
In real life we choose the train depends of hour departure or arrival, time to travel and costs. With no time schedule it is impossible to implements something simulating that.
BTW: time schedule would be great ;]
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: z9999 on December 03, 2008, 11:07:20 AM
One thing, what I said "take lower number waiting fitst" is like this.
Sorry, I have poor vocabulary in English, and couldn't explain well.

Think, why you made such a line instead of a direct line.
(But of cource, I don't need this.  :P )
Title: Re: Load first passengers (cargo) to farthest destinations
Post by: isidoro on December 04, 2008, 02:03:55 AM
Seems interesting.  So, the algorithm would be like this:

Repeat until there are no more waiting goods:
    perDestination:=1+int(freeCapacity/possibleDestinations)
    for each possible destination:
        load up to perDestination cargo (there can be less)
        if vehicle is full: exit Repeat


The problem I see is that there may be too many loops in some cases...

Title: Re: Load first passengers (cargo) to farthest destinations
Post by: jatypc on December 04, 2008, 09:02:44 AM
The problem I see is that there may be too many loops in some cases...

A reduction in the number of loops could be achieved if the number of destinations, for which there is some load is recorded: if you decrease possibleDestinations fast, thus increase perDestination fast, there are not many loops as the freeCapacity decreases fast. Of course, I do not know how complicated the directive "Count the number of destinations reachable by the train" is - if it is readily available, it is easy; if the goods are separated by their intermediate station (visible in the amount/via list of a station), it is also easy since one can consider only the list of intermediate stations. On the other hand, if it has to be recursively collected, it is too much work probably.


possibleDestinations = "Count the number of (intermediate) destinations reachable by the train, for which there is some load"

Repeat until there are no more waiting goods:
    perDestination:=1+int(freeCapacity/possibleDestinations)
    for each possible destination:
        load up to perDestination cargo (there can be less)
        if there is no more load to Destination: possibleDestinations = possibleDestinations - 1
        if vehicle is full: exit Repeat

Title: Re: Load first passengers (cargo) to farthest destinations
Post by: valten on March 29, 2009, 06:28:17 PM
in real life, if you have 1000 pass waiting at a station and a bus with 100 free arrives, 100 people will board which means each person whatever its destination gets a 10% chance of boarding the bus (i understand we don't have enough information to make a fifo decision) - that also means that the mix of people boarding the bus should reflect the mix of people waiting at the station

Proposal 1 : passenger should board following the proportion of passengers waiting per destination

Proposal 2 : if this is not possible computation-wise, maybe one solution would be to at least randomize the station which is considered as the first, what i mean is : on a ABCDE schedule at stop A you randomize which stop you load passengers to between stations B,C,D,E, if you draw B then you load passengers as today, if you draw C then you load passengers for C then D then E then B, if you draw D then you load passengers for D then E then B then C... this would greatly improve the situation in towns and mitigate the express lines problem


+ this algorithm can be a parameter in the conf file to accomodate the playing style and the hardware

Title: Re: Load first passengers (cargo) to farthest destinations
Post by: robofish on March 29, 2009, 06:55:40 PM
in real life, if you have 1000 pass waiting at a station and a bus with 100 free arrives, 100 people will board which means each person whatever its destination gets a 10% chance of boarding the bus (i understand we don't have enough information to make a fifo decision) - that also means that the mix of people boarding the bus should reflect the mix of people waiting at the station

Proposal 1 : passenger should board following the proportion of passengers waiting per destination
Support!
It would be great to have this implemented.
We won't have trains running empty only one station after an overcrowded main hub ...
Title: Boarding-only stops
Post by: dloddick on June 02, 2010, 03:19:56 PM
Hello I come from Hong Kong
and I would like to suggest something on route setting

As everybody knows that minimum load % can be set at designated stops
so that the vehicle would start when minimum load reaches.

How about introducing a function on setting an "All get off" function at a designated stop?

Example:
1. Stop A
2. Stop B
3. Stop C
4. Stop D ( All get off at this stop )

i.e. no matter a passenger going to which stop,they must first alight at Stop D and waiting for other route
buses

Though it sound impratical
but in some Hong Kong bus routes operate like that
so that buses can rush back to its original starting stop without any passengers
for high demand at that stop

I highly hope that Simutrans would hv this function as it helps to solve the problem of
passengers taking the bus all the time in circular rt

and faciltate the operation of high demand routes ...

I guess it's easy to hv this function as Simutrans hv full load for buses
so no load I guess is okay...

and then I don't need to manually press "no load" for the buses all the time ...

Thanks a lot
Title: Re: Route Setting
Post by: skreyola on June 02, 2010, 07:03:20 PM
I think this would be cool. I have had times in the past where I wanted this... it makes sense in ST for goods more than passengers: If I have two oil consumers and two oil producers, Rig A, Rig B, Plant C, and Plant D, and ships E, F, and G, with E going from A to C, F going from A to D, and G going from B to D, my network can get all fouled up with oil going from B to C, which I didn't want. A "Max 0" fill order would prevent snarling of interconnected networks like this.
And there are times when I have one stop that's generating more passengers than the rest of the line, and I want an extra bus to carry passengers only away from there, so this is a good idea, I think.
:support:
How hard would it be to implement?
Title: Re: Route Setting
Post by: prissi on June 02, 2010, 08:58:32 PM
It is easy in principle, just at the built up of the connection three this connection needs to be found only in one way.
Title: Re: Route Setting
Post by: skreyola on June 02, 2010, 09:44:02 PM
It is easy in principle, just at the built up of the connection three this connection needs to be found only in one way.
Are you saying this is possible currently?
Title: Re: Route Setting
Post by: prissi on June 02, 2010, 10:38:29 PM
The changes would not be very big; but personally I hate breaking the symmetric routing, since it will confuse poeple; I rather keep simutrans simple, as it is already challenging enough for most.
Title: Re: Route Setting
Post by: sdog on June 02, 2010, 10:56:31 PM
Something to the same effect already works in simutrans-experimental, without having to unload

I describe it with an example:
Stops A, B, C, D.
You want to get passengers get away from Stop A, as it tends to crowd. Delivering to B, C and D. The bus should return quickly to A, without passengers for B and C (this happens in standard i think)

Now have a line 1: A-B-C-D->A
And a line 2: A-B-C-D-C-B->A

If service on line 2 is frequent enough and stop A is crowded, passengers for B and C will get of the bus and take line 2 two back to B and C. So on the trip back from D to A only passengers for A should be on board, who should get off.
As soon as line 2 gets to slow however, passengers rather do the roundtrip in over A in line 1.


Please correct me if i'm wrong!
Title: Re: Route Setting
Post by: jamespetts on June 02, 2010, 11:31:54 PM
I must confess, it has been so long since I dealt with the machinations of routing that I cannot quite recall the circumstances in which passengers will disembark from their current ride even if it goes to their preferred destination directly to catch another mode of transport to get them there. Certainly, they will in sufficiently extreme circumstances, but I think that there is a general preference to remain with their present mode of transport if it will take them to their destination - just as in real life.
Title: Re: Route Setting
Post by: isidoro on June 03, 2010, 12:42:40 AM
In fact, I did something similar to this in one of my patches:
http://forum.simutrans.com/index.php?topic=1648.0

The patch provides a button to set the maximum load at a station besides the minimum load.  If you set the maximum load at a station to zero, you get the effect you are looking for.

Note that:
  • The patch is dated
  • The patch does other things in connection with QoS and overcrowding I was experimenting with at that time
Title: Re: Route Setting
Post by: dloddick on June 03, 2010, 07:01:56 AM
Something to the same effect already works in simutrans-experimental, without having to unload

I describe it with an example:
Stops A, B, C, D.
You want to get passengers get away from Stop A, as it tends to crowd. Delivering to B, C and D. The bus should return quickly to A, without passengers for B and C (this happens in standard i think)

Now have a line 1: A-B-C-D->A
And a line 2: A-B-C-D-C-B->A

If service on line 2 is frequent enough and stop A is crowded, passengers for B and C will get of the bus and take line 2 two back to B and C. So on the trip back from D to A only passengers for A should be on board, who should get off.
As soon as line 2 gets to slow however, passengers rather do the roundtrip in over A in line 1.


Please correct me if i'm wrong!
emm...
What I want is ...
Line 1 passengers must get off at Stop D and the bus will "no load" at Stop D
so that the bus can go back to Stop A again without passengers

In reality, no passenger is allowed to take a bus which is displayed as " Private " or " Not in service", isn't it ?

Though now we can manually press "no load" after the bus leaving Stop C
and according to the routing, all passengers will get off at Stop D

so I would like to have an option to be set in the line management instead of manually pressing the "no load" button all the time
Title: Re: Route Setting
Post by: dloddick on June 03, 2010, 07:15:38 AM
The changes would not be very big; but personally I hate breaking the symmetric routing, since it will confuse poeple; I rather keep simutrans simple, as it is already challenging enough for most.
I guess you misunderstand my point or I did not explain it clearly ...

I did want similar cases provided by sdog:
Now have a line 1: A-B-C-D->A
And a line 2: A-B-C-D-C-B->A

and I just want a "no load" button when setting stop D in line 1
so that no passengers would remain in the bus after stop D

and on the other hand
line 2 would carry passengers back to C, B and A

then line 1 buses can quickly back to stop A again without passengers
this enhance efficiency of operating these two routes

In reality,
bus company would have buses going back to its original destination
for high demand also

You would not get on a bus showing " Private " or " Not in service "
and it is not allowed for passengers to take those buses

actually I don't tend to break the symmetric routing of Simutrans
but enhancing this routing using a better method to prevent overcrowding of some stops

You know
Adding more and more buses does not surely solving the problem of overcrowding
but may lead to lower efficiency due to congestion of buses

by the "no load" function
bus can "escape" from its terminus without passengers to its orginial starting point
and that surely enhancing the efficiency

I understand the Simutrans is created for everyone
it is hard to meet the needs of all people in the world
but as you say it is currently possible and therotically okay,
I cordially hope that you can add this option in the next version

ya,
anybody hv its right to use the option or not
but I think it would be rather selfish if one say "no" only for him won't use the option

and this option would further improve the simulation
of most vehicle transportation system,even train service would have additional departures when it come to the station without carrying any passengers

so could you please re-consider it again?
Adding this option would not cause great harm to most players
but would give a better simulation for players to operate their routes
Title: Re: Route Setting
Post by: jamespetts on June 03, 2010, 08:45:33 AM
Perhaps a more straightforward option would be to have the ability to set some stops as "embarkation only" and others as "disembarkation only". This is a common practice in reality on both 'buses and trains.
Title: Re: Route Setting
Post by: prissi on June 03, 2010, 08:55:58 AM
He wants to have people change at said stop; thus disembarking only must be convoy specific.
Title: Re: Route Setting
Post by: jamespetts on June 03, 2010, 09:04:53 AM
He wants to have people change at said stop; thus disembarking only must be convoy specific.

I'm not sure that I follow - why can't the disembark only setting be applied to a schedule of a line? Or have I misunderstood...?
Title: Re: Route Setting
Post by: dloddick on June 03, 2010, 01:46:22 PM
He wants to have people change at said stop; thus disembarking only must be convoy specific.
Not really
Using the example again:
Line 1: A>B>C>D>A
Line 2: A>B>C>D>C>B>A

firstly line 2 operates in normal mode
passenger can travel from:
A > D , B > D , C > D
A > B , B > C , A > C ( and vice versa )

In line 1: ( Assume that there is "no load" option set at Stop D )
passenger can travel like the following:
A > D , B > D , C > D
A > B , B > C , A > C

For opposite direction like D > C , C > A,
they must take line 2
as all line 1 passengers must get off at stop D
and nobody could get on the bus at stop D

Passenger direction: ( Forwards only no backwards )
A > B > C > D

Hope other can get what I mean
Thanks
Title: Re: Route Setting
Post by: skreyola on June 03, 2010, 04:28:41 PM
The changes would not be very big; but personally I hate breaking the symmetric routing, since it will confuse poeple; I rather keep simutrans simple, as it is already challenging enough for most.
I see your point, and I agree that simplicity is important, but I think it could be implemented without causing confusion, that is, it would be like power lines: nobody has to build them or deal with them if they choose not to.
Most people, I think, if they can understand the minimum load function, would understand a maximum load box right near it, and if they didn't, they'd probably leave it alone (in 100% max position).

I'm not sure that I follow - why can't the disembark only setting be applied to a schedule of a line? Or have I misunderstood...?
Your wording could have been parsed to mean that the stop itself, not the stop in a schedule, was "embarkation only".

@dloddick: Okay, I understand, but why? Is it because you have one upstream line and one downstream line, or do you just not want passengers to go to those stops?
Title: Re: Route Setting
Post by: prissi on June 03, 2010, 08:06:20 PM
@skreyola
Maximum load was not, what was requested. It was a stop, where everybody must go off. It would be a station, that is connected by the other stations, but not connect to those.
Title: Re: Route Setting
Post by: skreyola on June 03, 2010, 10:11:49 PM
@skreyola
Maximum load was not, what was requested. It was a stop, where everybody must go off. It would be a station, that is connected by the other stations, but not connect to those.
In that case, I misunderstood the OP.
Title: Re: Route Setting
Post by: Lmallet on June 03, 2010, 11:01:55 PM
Are we talking here about having Transport Tycoon's "Unload" button?  For those not familiar with TT, when you add a station in a vehicule's line management, you could select "Full Load" (equivalent to 100% in Simutrans), you could put nothing (so stop, load whatever cargo there is, and leave), or "Unload" (unload all cargo, and leave empty).  

From my TT memories, I rarely used the Unload feature (I don't even know if I ever used it)...  but that being said, TT didn't keep track of destination the way Simutrans does.  In TT, when a bus arrives at a station and unloads, it will "consume" all the passengers, as it simply assumes all passengers are going to that station.  In ST, passengers and cargo need to go somewhere, and might have to transfer at stations, and will try everything it can to make that happen.  There has been quite a few times I've noticed truck lines sitting idle, yet the factory continuously gets supplied.  Then I realize that a train, which is running an unrelated service, is actually feeding it when it returns from its destination, because a new industry built itself next to the "destination" station.   An Unload feature would be helpful in a case like this, because I could simply tell the train not to pick anything up on its way back, and allowing the trucks to do their work as intended.

I don't think this would make things more complicated;  after all, this would not happen by default, it would have to be selected.
Title: Re: Route Setting
Post by: skreyola on June 04, 2010, 01:44:39 AM
@Lmallet: Can't tell you how many times that has happened to me. That's why I support the addition of a feature for "unload only at this stop" in schedule creation... I don't think it should necessarily be "unload all"... now that I think about it, because that would make the feature less useful.
So, perhaps not a maximum, now that I think about it, but just a button for each stop in the line that forbids any loading at that point?
Title: Re: Route Setting
Post by: Lmallet on June 04, 2010, 02:04:24 AM
I don't think it should necessarily be "unload all"... now that I think about it, because that would make the feature less useful.
So, perhaps not a maximum, now that I think about it, but just a button for each stop in the line that forbids any loading at that point?
That makes more sense.  After all, an unload all button would only really be useful for the last stop on a schedule, and not an intermediary stop.
Title: Re: Route Setting
Post by: dloddick on June 04, 2010, 04:53:44 AM
That makes more sense.  After all, an unload all button would only really be useful for the last stop on a schedule, and not an intermediary stop.
Great ! You got what I mean !

and skreyola got what I mean too !

what I request is having such "Unload all" button during schedule creation
ya likely at the last stop

My ideal thought is like this:

Line Management ( Line 1)

1. Stop A
2. Stop B
3. Stop C
4. Stop D ( Unload all )

emm... on the other hand
whether the button of " Loading only" should be added
I have no idea on it...
Title: Re: Route Setting
Post by: Lmallet on June 04, 2010, 12:46:22 PM
emm... on the other hand
whether the button of " Loading only" should be added
I have no idea on it...
I am not too sure this has any use.  Why would you have a station where people can get on, but not get off?
Title: Re: Route Setting
Post by: jamespetts on June 04, 2010, 01:19:24 PM
I am not too sure this has any use.  Why would you have a station where people can get on, but not get off?

It's quite common in reality. It's used, for example, at Watford Junction station on the West Coast Main Line, between London and Birmingham/Manchester/Preston/Liverpool/Glasgow. Watford Junction is a station about 30-40 miles North of London, served by slow stopping trains and regional semi-fast trains to London; the latter are medium density services that call at only one or two intermediate stations between Watford and London.

Also, however, some expresses to the North call at Watford: on the way out for pick up only, and on the way back for set down only. The idea is that the passengers from Watford to the North can get a direct fast train, without the fast train being burdened with the large numbers of regional passengers travelling between London and Watford.
Title: Re: Route Setting
Post by: Lmallet on June 04, 2010, 01:28:59 PM
It's quite common in reality. It's used, for example, at Watford Junction station on the West Coast Main Line, between London and Birmingham/Manchester/Preston/Liverpool/Glasgow. Watford Junction is a station about 30-40 miles North of London, served by slow stopping trains and regional semi-fast trains to London; the latter are medium density services that call at only one or two intermediate stations between Watford and London.

Also, however, some expresses to the North call at Watford: on the way out for pick up only, and on the way back for set down only. The idea is that the passengers from Watford to the North can get a direct fast train, without the fast train being burdened with the large numbers of regional passengers travelling between London and Watford.
I have to admit I am not familiar with British rail operations.  Do they physically prevent passengers from getting off at these stations?
Title: Re: Route Setting
Post by: jamespetts on June 04, 2010, 01:38:46 PM
I have to admit I am not familiar with British rail operations.  Do they physically prevent passengers from getting off at these stations?

I don't think that they stand guard at the doors saying "nobody may leave!", no. But they will not advertise the train from London as stopping at Watford, and, when the ticket inspector comes around, any tickets for Watford will not be accepted as valid on the train, the passengers having to pay for at least a single to the next stop, which might be as far away as Coventry or even Preston: orders of magnitude more expensive than a ticket to Watford.
Title: Re: Route Setting
Post by: Lmallet on June 04, 2010, 01:54:46 PM
I don't think that they stand guard at the doors saying "nobody may leave!", no.
I would not want that job.  :)

I have learned something today.  Thanks! 
Title: Re: Route Setting
Post by: wlindley on June 04, 2010, 02:23:41 PM
In the final days of "real" (private) American passenger trains, there arose a truly Byzantine set of rules, with a myriad timetable footnotes as: "g. Handles passengers only for St. Louis or beyond or from Albuquerque or beyond; checked baggage only for Kansas City or beyond or from Winslow or beyond, except Sundays" which effectively became a way of driving away, or at least extorting high ticket prices from almost all local travelers. Thank the ICC and over-regulation for helping spell the end of most passenger service in the USA!
Title: Re: Route Setting
Post by: dloddick on June 04, 2010, 03:36:04 PM
In short
there are different cases of "Unloading all" , "Loading Only" or even "Unloading Only"
in reality in different parts of the world

the questions comes along are
whether the Simutrans engine can operate these features
and whether the developers would add these features ..
Title: Re: Route Setting
Post by: Lmallet on June 04, 2010, 04:44:11 PM
In the final days of "real" (private) American passenger trains, there arose a truly Byzantine set of rules, with a myriad timetable footnotes as: "g. Handles passengers only for St. Louis or beyond or from Albuquerque or beyond; checked baggage only for Kansas City or beyond or from Winslow or beyond, except Sundays" which effectively became a way of driving away, or at least extorting high ticket prices from almost all local travelers. Thank the ICC and over-regulation for helping spell the end of most passenger service in the USA!
Similar techniques are still in use today, albeit usually applies to freight lines now that passenger service is somewhat rare.  Service abandonment usually requires government permission (it is that way in Canada, and I am pretty sure it is the same in the US), however the government usually refuses abandonment as long as a line is profitable or seen as necessary.  Railways will resort to minimal maintenance and reducing the number of trains on a line until it becomes so impractical to use, shippers will often simply opt to use trucks instead, and when the abandonment hearing comes, the railways will say the line is a poor performer, which is usually accepted.

the questions comes along are
whether the Simutrans engine can operate these features
and whether the developers would add these features ..

Well, Prissi mentionned it would be fairly easy to implement (unless I misunderstood his comment).  If he thinks it is worth adding the feature, well, only he can answer that, I am sure he already has enough on his plate as it is.  James could also see some value for ST-Exp.  :)

Edit: and yes, I would want such functionality.  :)
Title: Re: Route Setting
Post by: skreyola on June 04, 2010, 04:46:19 PM
I would like to see a feature for schedules of making a particular stop "No Load".
Title: Re: Route Setting
Post by: dloddick on June 05, 2010, 05:05:46 AM
I would like to see a feature for schedules of making a particular stop "No Load".
This sounds great also !
Title: Re: Route Setting
Post by: Brambo on June 05, 2010, 02:12:42 PM
In short
there are different cases of "Unloading all" , "Loading Only" or even "Unloading Only"
in reality in different parts of the world

the questions comes along are
whether the Simutrans engine can operate these features
and whether the developers would add these features ..

These 3 features would be great to have
Title: Re: Route Setting
Post by: stmaker on August 20, 2010, 04:38:51 AM
I like this feature that one bus goes to a few stops until the last stop where everyone has to get off. I know in my country they will do that on bus interchanges.
Title: Re: Route Setting
Post by: dloddick on March 07, 2011, 09:32:01 AM
Very sorry for putting up this thread ended long time ago

Recently, Simutrans 110.0 has been released.
As long as I remember, the developer said that some of the features suggested in this thread are easy to implement
so I wonder those features can appear in coming release ...

Feature discussed:
1. Unload all
2. Unload only
3. Load only

and to be wished to see them in line management of a line
as like as the minimum load and month wait time option ....

sorry for any inconvenience caused...
Title: Re: Route Setting
Post by: jamespetts on March 07, 2011, 11:45:50 PM
I like this feature that one bus goes to a few stops until the last stop where everyone has to get off. I know in my country they will do that on bus interchanges.

I've done some testing recently, and this is possible with the existing code (and works for trains, too). Just set the convoy to stop twice at the terminal stops, and then set a minimum load (possibly with a maximum weight or (in Experimental) a convoys/month setting) at the first of the terminal stops. The convoy will pull into the terminal, and, assuming that it's just going to go back the way that it's just come, let off all the passengers then wait for the appointed time. Once that time has elapsed, it will move to the next point on the schedule (the same stop), and let the passengers on. This has a particular advantage for Experimental, as the passengers will count the time that they spend waiting on a convoy that is reversing or waiting for a load, etc. as travelling time, reducing the average speed, whereas this method will instead increase the waiting time, which is halved to simulate the efficiencies in waiting times brought about by published timetables (fewer people will turn up for a 'bus or a train just after one has left than just before one is due to depart if they know the timetable).
Title: Boarding-only stops
Post by: Mattoon Pool on January 25, 2012, 10:17:21 PM
Hi,

Try to think about the following situation: the bus goes through the stations A, B and D. At D he waits and goes back - D, C,B and A, aka C is one-way stop. In the current version of Simutrans, it means all passengers from B to C now sits in the bus all the way to D (imagine more stops), take space.

As a solution I propose the 'Full Exit Mark' in the bus / line schedule window. At the marked stop, all passengers would have to leave. When planning a route for a passenger in a current version of Simutrans, the game doesn't look on the whole schedule - it skips the stops after the very same, aka waiting for the bus in reverse direction. The change would be, that the game would also not consider any stops after the Full exit marked stop.

In the proposed case, there would be no direct route between B and C (D would be the Full mark stop) and passengers wouldn't take up the space. It'd also make the game a bit more realistic.
Title: Re: Empty the Bus at Station
Post by: wlindley on January 26, 2012, 12:40:15 AM
This is the same situation as this (http://forum.simutrans.com/index.php?topic=8978.msg84459) -- except with passengers instead of coal.
Title: Re: Empty the Bus at Station
Post by: Ters on January 26, 2012, 05:23:47 AM
Since the bus doesn't stop at C on its way from A to D, passenger would have to go to all the way to D and back to C. I would even say it's realistic that they do so even if it wasn't allowed. As a loophole, they could buy a ticket from A to D, step off the bus, walk right on again and buy a ticket to C. The result is the same: they take space going from A to D.

Due to the way Simutrans loads passengers and cargo, I think passengers going to B and D will have higher priority than passengers going to C. So passengers going to C won't take up space in the bus unless there is free capacity. They will accumulate at the stops, though.
Title: Re: Empty the Bus at Station
Post by: wlindley on January 26, 2012, 10:32:03 AM
Yes the passenger may deboard at D, and ride back to C -- but he will pay two fares (A to D, and D to C).  Under the current system, he rides quite a ways for free, occupying space that would have been taken by additional fares.
Title: Re: Empty the Bus at Station
Post by: prissi on January 26, 2012, 04:19:04 PM
AT D passengers to C (the next stop) will be loaded first. Thus, even if the bus is fully emptied, the C would just get again onto the bus.
Title: Re: Empty the Bus at Station
Post by: isidoro on January 26, 2012, 11:37:28 PM
But as Matoon Pool suggested, passengers going to C wouldn't get on board in the first time, since the route is interrupted when unload is forced, isn't it?
Title: Re: Empty the Bus at Station
Post by: Ters on January 27, 2012, 05:43:18 AM
The route would be interrupted, yes, but realistically not broken. Passenger for C would just board as passengers for D. Only if we assume there is another line connecting A and C would anything change, as passengers going from A to C would then prefer that direct line to the one that forces them to exit and reenter the bus at D.
Title: Re: Empty the Bus at Station
Post by: isidoro on January 27, 2012, 12:26:02 PM
But then, as prissi says, nothing can be done, since once the passengers are unloaded they can't be distinguished from the ones already at the station and they will board again.

Line 1: A - B - D* - C - B...

Passengers from B to C cannot be routed through line 1.  Though line 1 can take passengers to C from D* arriving there by other means.  In the program route searching is interrupted when you reach the same station in a line, that mark would mean the same, as if D has been already visited, though not.

Title: Re: Empty the Bus at Station
Post by: AP on January 27, 2012, 04:58:14 PM
But then, as prissi says, nothing can be done, since once the passengers are unloaded they can't be distinguished from the ones already at the station and they will board again.
Would it not be that they would never have boarded at the first place, since there would be no connection to their destination via that vehicle route, because of the forced disembarkation order in the schedule?
Title: Re: Empty the Bus at Station
Post by: Ters on January 27, 2012, 07:09:55 PM
Would it not be that they would never have boarded at the first place, since there would be no connection to their destination via that vehicle route, because of the forced disembarkation order in the schedule?

Only if the bus does not allow boarding at D, and there is no route from any other stop on the schedule, except A, to C.
Title: Re: Empty the Bus at Station
Post by: DatDamnDom on April 19, 2012, 04:00:46 AM
Apologies for the late interest in the thread.

This is the same situation as this (http://forum.simutrans.com/index.php?topic=8978.msg84459) -- except with passengers instead of coal.

Respectfully, I doubt that these two threads describe the same problem, though I do agree that their symptoms and solutions may coincide.

There "exists" a route for pax bound for C-stop in this scenario, and if the route exists, the pax will generate according to other factors (population density and so forth.)  This will continue until and unless this possibility is either eliminated, or offered a rule-friendly alternative.  I tend to think of pax as ad-hoc freight contracts.  Coal deliveries and factory output contracts are essentially static, responding only to consumption and storage availability at the loading dock.  The traffic levels may fluctuate, but the endpoint routing itself is borderline immutable -- the player simply controls profitability and efficiency in between the two endpoints.

I'm experimenting with undergound-only pax infrastructure within cities, as I left my simulation running for a few hours while I slept and I built up a decent bank of capital to work with.  My idea is to convert to a complete hub-and-spoke system, eliminating all circles and pathing issues.  This may impact travel times, as I'm not sure if layover times are calculated for speed bonuses, and I anticipate that I will reveal numerous flaws within my own plan.  If you'd like, I will keep before-during-after savegames allowing others to help me determine outcomes and identify flaws.  Currently, I plan organic ad hoc pax loops and line routes within cities at 0% load thresholds, but the ebb and flow of pax demand is maddening.  As a result of low carriage densities, my local mail / pax loops tend to run heavily in the red.  However, I do daisy-chain intercity runs.  All cities get a "Hereville Terminus" station plopped at the edge of the initial development, such that city expansion will eventually envlope the stop and it becomes central.  I always load origin intercity runs at 100% threshold, so these runs tend to run consistent profits for me.  However, as this is daisy chain and not hub/spoke, backlogs and crowding is difficult to contend with.  I anticipate that true hub/spoke within cities, and at regional hubs between cities (eventually encompassing the entire map with perhaps 3-5 major hubs of 4-10 cities each) will generate "lower" profits, but that these profits will be sustainable and reliable.  With underground construction, I can place all runs with 100%'s at the hubs, adding to capacity as cities sprawl and climb with individual routes -- my own professional experience with real world logistics and freight / pax distribution leads me to guess that no single spoke in this setup will require more than two vehicles, one for pax and one for mail.  With consistent outbound 100% loads, my deadhead mileage costs will be as minimized as the game mechanic allows.  Potential problems will likely result from having to keep track of so many line schedules, however.  Isn't the limit 8000?  We'll see, as I don't itnend to lose focus on friehgt as well.

My hope is that, once fleshed, I can investigate the possibility of driving freight infrastructure undergound within cities as well.  This will still leave me within the 50kph speed limitations of city driving, but should all but eliminate topside congestion issues that are so notorious.  Again, I'm not so much anticipating monstrous profits as reliability within those profit margins, aiming to reduce or eliminate the boom/bust cycles.  With underground construction, I can also assure little to possibly no station coverage overlaps or gaps without relying on artificial extensions, which I find annoying to implement.  As queues increase, I'll simply replace these single vehicles with larger capacity ones instead of adding further vehicles or expanding tile coverage in the stop -- though I wouldn't be against upgrading the plot tiles themselves if the need arose.

One likely downfall to this idea I have, however, is that my maintenance costs could possibly become unsustainable, though I cannot confirm this without experimenting.

Ideas or thoughts would be appreciated.

In the event of multiple pathing options, pax and freight will favor the briefest and / or most direct route available.  Offer one.  Install a spur line (with 100% loads, if you prefer) taking from A to C.  This will interact with your existing route to specify that your primary route A-B-D-C-B-A will continue to offer exits for "downward" C-stop pax, but the direct "upward" spur line will prevent upward pax on the primary line.
Title: Boarding-only stops
Post by: MagnusA on September 30, 2012, 08:33:27 AM
Sometimes I want to use a stop as "loading only" or "unloading only" on the line/schedule level. Typically I have a intercity bus line and a local intracity bus line sharing stops in the city. I don't want the pax using the intercity line for local travels. There is a risk that the bus goes almost empty to the next city because the local pax' has got all the available seats, leaving the intercity pax' behind.

Therefore I would like to at least disallow unloading on the way out of the city. In the illustration below this would be the case for stops A2 and A3 for the intercity line (but not for the intracity line).

Intercity line: A1--A2--A3--------B1
Intracity line: A1--A2--A3

Is there a way to achieve this? If this is not possible in current release, this might be considered by the development team?
Title: Re: Boarding-only stops
Post by: Ters on September 30, 2012, 08:49:14 AM
This is a common question. As far as I remeber, the answer has always been "no". You can try searching for the previous discussions.
Title: Re: Boarding-only stops
Post by: Carl on September 30, 2012, 08:57:49 AM
There has been some inconclusive discussion of this (e.g. here: http://forum.simutrans.com/index.php?topic=2816.0). Can't recall it ever being flat out denied, though I may be wrong.

Pick-up only and set-down only are certainly useful features of real transport schedules, which it would be nice to have in-game -- but whether the benefits would outweigh the difficulty of implementation and other possible side-effects, I don't know.
Title: Re: Boarding-only stops
Post by: Roads on September 30, 2012, 09:04:26 AM
Transporting passengers is not my thing and neither are big cities, I'm a cargo guy but I do transport some passengers.  What works for me may not apply here at all but I try never to have a situation such as this:

A1--A2--A3 rather I always do: A1--A2, A1--A3, then I would do A1 to B

Maybe this does not apply since my cities are always pretty small.
Title: Re: Boarding-only stops
Post by: jk271 on September 30, 2012, 09:36:39 AM
I can imagine "unloading only" stops. For example line A1 (forest) - A2 (sawmill) - A3 (material's wholeseller) can use stop A3 as "unloading only" to avoid unintended routing of wood/logs. Furthermore "unloading only" stops could be marked as skippable - allow skipping "unloading only" station A3 in case of no cargo present in A2 having destination to A3.

I have not found any usage for "loading only" stops. The reason you are writing should be solved by modification of routing algorithm to prefer long-distance passengers/cargo. Preference can be optional and specific to particular stop in line schedule. It would be more difficult to implement than "unloading only" stops.

I can imagine me writing the path with "unloading stops" and "skippable unloading stops". I think, it is feasible. Detailed money stats had been said infeasible too but working patch exists today! Stop in line schedule (in source code) needs  field with flags. It would need one byte per station in line schedule.

But it is very hard for me to imagine the patch being incorporated in sim standard.
Title: Re: Boarding-only stops
Post by: Carl on September 30, 2012, 09:38:37 AM
"Loading only" and "unloading only" would have to go hand in hand on the same line. In MagnusA's example, you'd want A3 to be loading only in one direction, and unloading only in the other direction. This is what happens at (e.g.) Watford Junction on the UK West Coast Main Line: it's pickup only on express trains leaving London, and set-down only for express trains going towards London.
Title: Re: Boarding-only stops
Post by: jk271 on September 30, 2012, 09:50:46 AM
Implementation of "loading only" stops would be probably more simple than suggested change of routing algorithm to prefer long distance transport.
Title: Re: Boarding-only stops
Post by: kierongreen on September 30, 2012, 04:52:17 PM
It would be extremely easy to change routing so that long distance passengers had priority over short distance. Only problem is that you would then get queues of passengers waiting to travel to the next station. What generates this problem is a combination of line structure and lack of capacity.
Title: Re: Boarding-only stops
Post by: Ters on September 30, 2012, 05:36:41 PM
Ideally, long distance passengers should have priority on intercity lines, and short distance passenger should have priority on intracity lines. That should keep intercity lines from running full with short distance passengers, and intracity lines from running empty because the intercity train departed with all suitable passengers. The capacity is there, it's just used wrong.

But what is an intercity line and what is something else?
Title: Re: Boarding-only stops
Post by: Fabio on September 30, 2012, 06:06:33 PM
Ideally, long distance passengers should have priority on intercity lines, and short distance passenger should have priority on intracity lines. That should keep intercity lines from running full with short distance passengers, and intracity lines from running empty because the intercity train departed with all suitable passengers. The capacity is there, it's just used wrong.

This is a great idea.

But what is an intercity line and what is something else?

Some ideas:
1) Could a line route length be calculated? maybe simply as manhattan distance of A-B,  then B-C, and so on till A again.
Longer distance lines would give priority to long distance pax, shorter ones to short distance pax.

2) Urban and suburban lines are those which stops are located within twice (or n-times)  the city limits radius from the town hall. These lines give priority to short distance pax, the other to lond distance pax.
Title: Re: Boarding-only stops
Post by: greenling on September 30, 2012, 06:10:39 PM
Fabio
Those idea like i!
I must often riddle how i must be build a route.
Title: Re: Boarding-only stops
Post by: Ters on September 30, 2012, 07:23:41 PM
2) Urban and suburban lines are those which stops are located within twice (or n-times)  the city limits radius from the town hall. These lines give priority to short distance pax, the other to lond distance pax.

That won't work for me, as sometimes, the shorter line also runs between two towns. And the distances aren't equal across the map. A distance suitable in the more crowded areas won't work in more rural regions.
Title: Re: Boarding-only stops
Post by: Václav on September 30, 2012, 08:42:08 PM
I managed to create stations where people are boarding-only by following way (on tram - but it may be done also with trains) - and it is not needed to change code - but it can be used only somewhere:

1. circle stations: station with two or more platforms that are on separated ways
2. tram/train arrives to station on way 1 - and goes on circle exchange
3. tram/train leaves circle exchange - and arrives to station on way 2
4. on circle exchange cannot be else station

Result: tram/train will unload all passengers/post at first. Then it empty goes through circle exchange - and after, it will be loaded back.
Title: Re: Boarding-only stops
Post by: Fabio on September 30, 2012, 10:28:28 PM
But what is an intercity line and what is something else?

A much better idea: Intercity as a property stored within the line object (shown as a check box in Schedule dialog).

Intercity is ON by default for airplanes, ships, trains, and maglevs. It can be turned off manually by the player when creating or updating the line.

Intercity is OFF by default (i.e. current behavior) for busses & trucks, trams, monorails, and narrow gauge. It can be turned on manually by the player when creating or updating the line.
Title: Re: Boarding-only stops
Post by: Roads on September 30, 2012, 10:47:33 PM
I like your idea very much Fabio!  Hope it is implemented.
Title: Re: Boarding-only stops, intercity route settings, etc...
Post by: Fabio on September 30, 2012, 11:17:38 PM
By the way, I joined a handful of related discussions and moved the whole in extension requests.
Title: Re: Boarding-only stops, intercity route settings, etc...
Post by: rsdworker on October 01, 2012, 12:42:32 AM
the Unloading and Boarding - sounds good -  few examples when train reaches end of line - Norway Oslo south airport Departures (only Unloads all passengers going to airport then train goes in Loop to Arrivals station to load up then goes to Main station
in London - the docklands railway does have Unloading and loading platforms - Bank station features this
the trains arrive at platform 9 and unloads all passengers and train goes in sliding beyond the platform then enters Platform 10 to load train
Title: Re: Boarding-only stops
Post by: Bear789 on October 01, 2012, 07:58:48 AM
Some ideas:
1) Could a line route length be calculated? maybe simply as manhattan distance of A-B,  then B-C, and so on till A again.
Longer distance lines would give priority to long distance pax, shorter ones to short distance pax.

2) Urban and suburban lines are those which stops are located within twice (or n-times)  the city limits radius from the town hall. These lines give priority to short distance pax, the other to lond distance pax.

What about let the player manually setting lines to urban, interurban, local, express? That way you avoid the game randomly misunderstanding what you ment to do.
It's not artificial complexity if things are set up in such a way that without specification the routing works like it does currently, so that players that don't want to meddle with that can ignore it.
Title: Re: Boarding-only stops, intercity route settings, etc...
Post by: Carl on October 01, 2012, 08:14:03 AM
the Unloading and Boarding - sounds good -  few examples when train reaches end of line - Norway Oslo south airport Departures (only Unloads all passengers going to airport then train goes in Loop to Arrivals station to load up then goes to Main station
in London - the docklands railway does have Unloading and loading platforms - Bank station features this
the trains arrive at platform 9 and unloads all passengers and train goes in sliding beyond the platform then enters Platform 10 to load train

This is already achievable within Simutrans, I think. If you create two separate platforms for a station, and have a train stop at both of them, passengers should alight at the first platform and then load at the second platform -- in both cases since that will be the shortest route to their destination. Not sure I've explained that too well -- anybody have a better way of putting it...?
Title: Re: Boarding-only stops, intercity route settings, etc...
Post by: ӔO on October 01, 2012, 06:41:26 PM
Going on with the intercity idea, I think it might be simpler to understand and use if the game were to allow a reverse load priority.

Prioritize loads for nearby destination (current behaviour)
or
Prioritize loads for distant destination (new behaviour that can be flagged)

This way, you can still achieve the various usages, intercity, local, express, regional, etc. while not adding too much complexity.
Title: Re: Boarding-only stops, intercity route settings, etc...
Post by: Roads on October 01, 2012, 06:50:29 PM
Carl, I think you may have explained it as well as it can possibly be because there is a much broader concept here.  With multiple platforms, multiple trains and multiple tracks, you can solve almost any problem.  The trouble is paying for it. :)

AEO, I think your idea would solve most passenger and possibly mail problems.