-
Notifications
You must be signed in to change notification settings - Fork 181
faq 303759368
by Giulio Giorgione on 2018-07-19 09:41:36
Hello everyone,
I cannot find any class actively referring to the scoring evaluation for carsharing.
First of all it seems to me that modifying the parameters "timeFeeTwoWayCarsharing" and "distanceFeeTwoWayCarsharing" in config.xml doesn't lead to any change on the inVehicleTime, distance and percentage of rental.
I have tried to modifi the following parameters from the qsim module:
<module name="TwoWayCarsharing" >
<param name="vehiclelocationsTwoWayCarsharing" value="CarsharingStations.xml" />
<param name="travelingTwoWayCarsharing" value="-6.0" />
<param name="constantTwoWayCarsharing" value="-0.4" />
<param name="timeFeeTwoWayCarsharing" value="-0.0" />
<param name="distanceFeeTwoWayCarsharing" value="-0.0" />
<param name="useTwoWayCarsharing" value="true" />
<param name="searchDistanceTwoWayCarsharing" value="10000.0" />
And the following parameters from the planCalcScore module:
<param name="traveling_access_walk_tw" value="-6"/>
<param name="traveling_egress_walk_tw" value="-6"/>
<param name="traveling_twoway_vehicle" value="-6"/>
So my questions are:
Where and in Which class in MATSim does take care of the carsharing scoring?
Under which name the parameters βc,cs and βt,cs (from the MATSim book eq. 22.1 pag.143) are implemented in the carsharing scoring function (Strav,q,cs) in MATSim?
Thank you very much
by Milos Balac on 2018-07-23 19:36:31
Dear Giulio,
Unfortunately the book chapter about carsharing is a bit outdated. You can see how the scoring works here:
The fee structures for carsharing services have to be now implemented directly in the code. You can look at the current state of the example here:
basically you have to provide your own cost implementation if you do not want to use the one in the example.
As for the scoring parameters (travelling disutility, ASC..) they are taken from the modules specific to carsharing which you can find here:
If you try to change for instance these two parameters:
<param name="travelingTwoWayCarsharing" value="-6.0" />
<param name="constantTwoWayCarsharing" value="-0.4" />
it will have an effect on the results. But you are correct, the parameters you were changing are not in use anymore in the code and I will remove them from the config group as well as to not cause confusion anymore.
I hope this helps.
Milos
by Giulio Giorgione on 2018-07-26 10:41:57
Dear Milos,
Thank you very much for your answer. I Looked at the classes you advised me but I still feel there are some dark areas I'm trying lo clear up.
It appears that in CarsharingScoringFunctionFactory.java, they use both CarsharingLegScoringFunction and CharyparNagelLegScoring, are they related? I mean does one override the value of the other or they are dependent on each other.
In CharyparNagelLegScoring.java, in line 104 and 105 in "calcLegScore" function it looks like the dist variable is multiplied twice and I am not sure which part of the formula these 2 lines relate to. Is it, as you were saying, not related to the carsharing contrib since I should provide my own cost implementation?
In CarsharingLegScoringFunction.java, in the "calcLegScore" function, the code of the scoring is commented, I cannot figure out if that is an ecample or the actual scorin function of carsharing
and, one last thing, in finish() function agentRentals variable "line 64" is always null and I cannot understand the reason behind it.
Thank you very much in advance,
Giulio
You are viewing an archive of the previous MATSim Q&A site. The real site is now at https://matsim.org/faq