1 package org.opentrafficsim.road.gtu.lane.tactical.util.lmrs;
2
3 import org.opentrafficsim.base.parameters.ParameterException;
4 import org.opentrafficsim.base.parameters.Parameters;
5 import org.opentrafficsim.core.gtu.plan.operational.OperationalPlanException;
6 import org.opentrafficsim.road.gtu.lane.perception.LanePerception;
7 import org.opentrafficsim.road.gtu.lane.tactical.following.CarFollowingModel;
8
9 /**
10 * Interface for voluntary incentives.
11 * <p>
12 * Copyright (c) 2013-2023 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved. <br>
13 * BSD-style license. See <a href="https://opentrafficsim.org/docs/license.html">OpenTrafficSim License</a>.
14 * </p>
15 * @author <a href="https://github.com/averbraeck">Alexander Verbraeck</a>
16 * @author <a href="https://tudelft.nl/staff/p.knoppers-1">Peter Knoppers</a>
17 * @author <a href="https://dittlab.tudelft.nl">Wouter Schakel</a>
18 */
19 public interface VoluntaryIncentive extends Incentive
20 {
21
22 /**
23 * Determines level of lane change desire for a lane change incentive.
24 * @param parameters Parameters; parameters
25 * @param perception LanePerception; perception
26 * @param carFollowingModel CarFollowingModel; car-following model
27 * @param mandatoryDesire Desire; level of mandatory desire at current time
28 * @param voluntaryDesire Desire; level of voluntary desire at current time, of voluntary incentives calculated before
29 * @return level of lane change desire for this incentive
30 * @throws ParameterException if a parameter is not given or out of bounds
31 * @throws OperationalPlanException in case of a perception exception
32 */
33 Desire determineDesire(Parameters parameters, LanePerception perception, CarFollowingModel carFollowingModel,
34 Desire mandatoryDesire, Desire voluntaryDesire) throws ParameterException, OperationalPlanException;
35
36 }