// This function returns the configuration it received as parameter.
// Note that this is specific to LocalConfigMathService and that other implementations of
// IConfigMathService may behave differently.
public ITrajectory computeDeltaChange(ITrajectory trajectory, boolean yTrajectory,
double integrationTime) {
IRange2D range;
if (yTrajectory)
range = ((ITrajectory2DY) trajectory).getRange();
else
range = ((ITrajectory2DX) trajectory).getRange();
double beginPosition = trajectory.getBeginPosition();
double endPosition = trajectory.getEndPosition();
double delta = trajectory.getDelta();
int stepsNumber = (int) Math.abs(Math.round((endPosition - beginPosition) / delta));
range.setStepsNumber(stepsNumber);
this.subComputeStepsNumberChange(trajectory, yTrajectory, integrationTime);
return trajectory;
}