You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
}
However, the target is updated only the condition "IsAtTarget()" is satisfied. So, I suggest to put the computation of the turning angle into this branch. This will eliminate the unnecessary computation when this condition is not satisfied. We should have
else if(isInformed == true) {
Dear all,
We have the computation of the next informed search angle in the function of Searching.
else if(isInformed == true) {
size_t t = SearchTime++;
argos::Real twoPi = (argos::CRadians::TWO_PI).GetValue();
argos::Real pi = (argos::CRadians::PI).GetValue();
argos::Real isd = LoopFunctions->RateOfInformedSearchDecay;
argos::Real correlation = GetExponentialDecay((2.0 * twoPi) - LoopFunctions->UninformedSearchVariation.GetValue(), t, isd);
argos::Real rand = RNG->Gaussian(correlation + LoopFunctions->UninformedSearchVariation.GetValue());
argos::CRadians rotation(GetBound(rand, -pi, pi));
argos::CRadians angle1(rotation);
argos::CRadians angle2(GetHeading());
argos::CRadians turn_angle(angle2 + angle1);
argos::CVector2 turn_vector(SearchStepSize, turn_angle);
SetIsHeadingToNest(false);
}
However, the target is updated only the condition "IsAtTarget()" is satisfied. So, I suggest to put the computation of the turning angle into this branch. This will eliminate the unnecessary computation when this condition is not satisfied. We should have
else if(isInformed == true) {
}
The text was updated successfully, but these errors were encountered: