Co-Simulation/Sumo/sumo-1.7.0/src/microsim/cfmodels/MSCFModel_PWag2009.cpp
// uses the safe speed and preferred acceleration with the same NORMAL tau to compute stopSpeed
uses the safe speed and preferred acceleration with the same NORMAL tau to compute stopSpeed
uses the safe speed and preferred acceleration with the same NORMAL tau to compute stopSpeed
double
MSCFModel_PWag2009::stopSpeed(const MSVehicle* const , const double speed, double gap) const {
    if (gap < 0.01) {
        return 0.;
    }
    const double vsafe = -myTauDecel + sqrt(myTauDecel * myTauDecel +  2.0 * myDecel * gap);
    const double asafe = SPEED2ACCEL(vsafe - speed);
    double apref = myDecelDivTau * (gap  - 2 * speed * myHeadwayTime) / (speed + myTauDecel);
    if (apref <= asafe) {
        apref = MIN2(apref, myAccel);
        apref = MAX2(apref, -myDecel);
    } else {
        apref = asafe;
    }
    return MAX2(0., vsafe + ACCEL2SPEED(apref));
}
double MSCFModel_PWag2009 :: stopSpeed ( const MSVehicle * const , const double speed , double gap ) const { if ( gap < 0.01 ) { return 0. ; } const double vsafe = - myTauDecel + sqrt ( myTauDecel * myTauDecel + 2.0 * myDecel * gap ) ; const double asafe = SPEED2ACCEL ( vsafe - speed ) ; double apref = myDecelDivTau * ( gap - 2 * speed * myHeadwayTime ) / ( speed + myTauDecel ) ; if ( apref <= asafe ) { apref = MIN2 ( apref , myAccel ) ; apref = MAX2 ( apref , - myDecel ) ; } else { apref = asafe ; } return MAX2 ( 0. , vsafe + ACCEL2SPEED ( apref ) ) ; }
uses the safe speed and preferred acceleration with the same NORMAL tau to compute stopSpeed
uses the safe speed and preferred acceleration with the same NORMAL tau to compute stopSpeed
/* veh */ //    VehicleVariables* vars = (VehicleVariables*)veh->getCarFollowVariables();