nus-yam/ex-repair huggingface dataset:
Program: 180314
Project: 180314
Buggy source:
@Override public <T extends Trajectory>SimulatedDataBlock<T> simulate(AdaptiveStepConfiguration configuration,DataBlock<T> data){
  SimulationEngine simulationEngine=simulationEngineFactory.simulationEngine(configuration.getMaxNumberOfIterations(),configuration.getPrecisionConfiguration().getMaxRelativeError());
  try {
    List<T> trajectories=new ArrayList<>(data.size());
    Status[] statuses=new Status[data.size()];
    for (int i=0; i < data.size(); i++) {
      Trajectory simulated=simulationEngine.simulate(data.getTrajectory(i).getLastPoint(),configuration.getOdeSystem(),configuration.getPrecisionConfiguration().getTimeStep(),configuration.getSpace().getMaxBounds().getTime());
      LinkedTrajectory trajectory=data.getTrajectory(i) instanceof LinkedTrajectory ? (LinkedTrajectory)data.getTrajectory(i) : (data.getTrajectory(i) instanceof TrajectoryWithNeighborhood ? LinkedTrajectory.createAndUpdateReferenceWithNeighborhood((TrajectoryWithNeighborhood)data.getTrajectory(i)) : LinkedTrajectory.createAndUpdateReference(data.getTrajectory(i)));
      trajectory.append(simulated);
      trajectories.add((T)trajectory);
      if (simulated.getLastPoint().getTime() < configuration.getSpace().getMaxBounds().getTime()) {
        statuses[i]=Status.TIMEOUT;
      }
 else {
        statuses[i]=Status.OK;
      }
    }
    return new ArraySimulatedDataBlock<>(new ListDataBlock<>(trajectories),statuses);
  }
  finally {
    simulationEngine.close();
  }
}

Fixed version (ground truth):
@Override public <T extends Trajectory>SimulatedDataBlock<T> simulate(AdaptiveStepConfiguration configuration,DataBlock<T> data){
  SimulationEngine simulationEngine=simulationEngineFactory.simulationEngine(configuration.getMaxNumberOfIterations(),configuration.getPrecisionConfiguration().getMaxRelativeError());
  try {
    List<T> trajectories=new ArrayList<>(data.size());
    Status[] statuses=new Status[data.size()];
    for (int i=0; i < data.size(); i++) {
      Trajectory simulated=simulationEngine.simulate(data.getTrajectory(i).getLastPoint(),configuration.getOdeSystem(),configuration.getSpace().getMaxBounds().getTime(),configuration.getPrecisionConfiguration());
      LinkedTrajectory trajectory=data.getTrajectory(i) instanceof LinkedTrajectory ? (LinkedTrajectory)data.getTrajectory(i) : (data.getTrajectory(i) instanceof TrajectoryWithNeighborhood ? LinkedTrajectory.createAndUpdateReferenceWithNeighborhood((TrajectoryWithNeighborhood)data.getTrajectory(i)) : LinkedTrajectory.createAndUpdateReference(data.getTrajectory(i)));
      trajectory.append(simulated);
      trajectories.add((T)trajectory);
      if (simulated.getLastPoint().getTime() < configuration.getSpace().getMaxBounds().getTime()) {
        statuses[i]=Status.TIMEOUT;
      }
 else {
        statuses[i]=Status.OK;
      }
    }
    return new ArraySimulatedDataBlock<>(new ListDataBlock<>(trajectories),statuses);
  }
  finally {
    simulationEngine.close();
  }
}
Program: 180315
Project: 180315
Buggy source:
Trajectory simulate(Point point,OdeSystem odeSystem,double timeStep,double timeLimit);

Fixed version (ground truth):
Trajectory simulate(Point point,OdeSystem odeSystem,double timeLimit,PrecisionConfiguration configuration);
Program: 180316
Project: 180316
Buggy source:
@Override protected OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,double timeStep){
  getOctave().eval(odeSystem.octaveString(false));
  getOctave().eval("String_Node_Str" + Arrays.toString(point.toArray(odeSystem.getVariables().size())) + "String_Node_Str");
  getOctave().eval("String_Node_Str" + point.getTime() + "String_Node_Str"+ numberOfIterations * timeStep + "String_Node_Str" + numberOfIterations + "String_Node_Str");
  getOctave().eval("String_Node_Str" + odeSystem.octaveName() + "String_Node_Str");
  return getOctave().get(OctaveDouble.class,"String_Node_Str");
}

Fixed version (ground truth):
@Override protected OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,PrecisionConfiguration precision){
  if (absoluteToleranceIsSet(precision)) {
    float[] tolerance=new float[precision.getDimension()];
    for (int i=0; i < tolerance.length; i++) {
      tolerance[i]=precision.getMaxAbsoluteError(i);
    }
    getOctave().eval("String_Node_Str" + Arrays.toString(tolerance) + "String_Node_Str");
  }
  getOctave().eval(odeSystem.octaveString(false));
  getOctave().eval("String_Node_Str" + Arrays.toString(point.toArray(odeSystem.getVariables().size())) + "String_Node_Str");
  getOctave().eval("String_Node_Str" + point.getTime() + "String_Node_Str"+ numberOfIterations * precision.getTimeStep() + "String_Node_Str" + numberOfIterations + "String_Node_Str");
  getOctave().eval("String_Node_Str" + odeSystem.octaveName() + "String_Node_Str");
  return getOctave().get(OctaveDouble.class,"String_Node_Str");
}
Program: 180317
Project: 180317
Buggy source:
protected abstract OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,double timeStep);

Fixed version (ground truth):
protected abstract OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,PrecisionConfiguration precision);
Program: 180318
Project: 180318
Buggy source:
@Override public Trajectory simulate(Point point,OdeSystem odeSystem,double timeStep,double timeLimit){
  List<ParameterValue> paramValues=loadParameterValues(point,odeSystem);
  OctaveOdeSystem octaveOdeSystem=paramValues.isEmpty() ? new OctaveOdeSystem(odeSystem) : new OctaveOdeSystem(odeSystem.substitute(paramValues));
  long numOfIterations=Math.min(Math.round((timeLimit - point.getTime()) / timeStep),getStepLimit());
  double[] loadedData=rawSimulation(point,octaveOdeSystem,numOfIterations,timeStep).getData();
  float[] data=new float[loadedData.length];
  for (int dim=0; dim < octaveOdeSystem.dimension(); dim++) {
    for (int i=0; i < loadedData.length / octaveOdeSystem.dimension(); i++) {
      data[dim + i * octaveOdeSystem.dimension()]=(float)loadedData[dim * (loadedData.length / octaveOdeSystem.dimension()) + i];
    }
  }
  float[] times=new float[loadedData.length / octaveOdeSystem.dimension()];
  float time=point.getTime();
  for (int i=0; i < times.length; i++) {
    time+=timeStep;
    times[i]=time;
  }
  if (paramValues.isEmpty()) {
    return new ArrayTrajectory(data,times,point.getDimension());
  }
 else {
    return new ArrayTrajectory(point,data,times,octaveOdeSystem.dimension());
  }
}

Fixed version (ground truth):
@Override public Trajectory simulate(Point point,OdeSystem odeSystem,double timeLimit,PrecisionConfiguration precision){
  List<ParameterValue> paramValues=loadParameterValues(point,odeSystem);
  OctaveOdeSystem octaveOdeSystem=paramValues.isEmpty() ? new OctaveOdeSystem(odeSystem) : new OctaveOdeSystem(odeSystem.substitute(paramValues));
  long numOfIterations=Math.min(Math.round((timeLimit - point.getTime()) / precision.getTimeStep()),getStepLimit());
  double[] loadedData=rawSimulation(point,octaveOdeSystem,numOfIterations,precision).getData();
  float[] data=new float[loadedData.length];
  for (int dim=0; dim < octaveOdeSystem.dimension(); dim++) {
    for (int i=0; i < loadedData.length / octaveOdeSystem.dimension(); i++) {
      data[dim + i * octaveOdeSystem.dimension()]=(float)loadedData[dim * (loadedData.length / octaveOdeSystem.dimension()) + i];
    }
  }
  float[] times=new float[loadedData.length / octaveOdeSystem.dimension()];
  float time=point.getTime();
  for (int i=0; i < times.length; i++) {
    time+=precision.getTimeStep();
    times[i]=time;
  }
  if (paramValues.isEmpty()) {
    return new ArrayTrajectory(data,times,point.getDimension());
  }
 else {
    return new ArrayTrajectory(point,data,times,octaveOdeSystem.dimension());
  }
}
Program: 180319
Project: 180319
Buggy source:
@Override protected OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,double timeStep){
  getOctave().eval(odeSystem.octaveString(true));
  getOctave().eval("String_Node_Str");
  getOctave().eval("String_Node_Str" + getRelativeTolerance() + "String_Node_Str"+ Long.MAX_VALUE+ "String_Node_Str"+ timeStep+ "String_Node_Str"+ timeStep+ "String_Node_Str");
  getOctave().eval("String_Node_Str" + function + "String_Node_Str"+ point.getTime()+ "String_Node_Str"+ (numberOfIterations * timeStep)+ "String_Node_Str"+ Arrays.toString(point.toArray(odeSystem.getVariables().size()))+ "String_Node_Str");
  getOctave().eval("String_Node_Str");
  return getOctave().get(OctaveDouble.class,"String_Node_Str");
}

Fixed version (ground truth):
@Override protected OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,PrecisionConfiguration precision){
  getOctave().eval(odeSystem.octaveString(true));
  getOctave().eval("String_Node_Str");
  getOctave().eval("String_Node_Str" + getRelativeTolerance() + "String_Node_Str"+ Long.MAX_VALUE+ "String_Node_Str"+ precision.getTimeStep()+ "String_Node_Str"+ precision.getTimeStep()+ "String_Node_Str");
  getOctave().eval("String_Node_Str" + function + "String_Node_Str"+ point.getTime()+ "String_Node_Str"+ (numberOfIterations * precision.getTimeStep())+ "String_Node_Str"+ Arrays.toString(point.toArray(odeSystem.getVariables().size()))+ "String_Node_Str");
  getOctave().eval("String_Node_Str");
  return getOctave().get(OctaveDouble.class,"String_Node_Str");
}
Program: 180320
Project: 180320
Buggy source:
@Override public Parameter release(Collection<Expression> expressions){
  int indexBefore=0;
  boolean release=false;
  for (  Expression e : expressions) {
    if (!(e instanceof Parameter)) {
      if (e instanceof Indexable && ((Indexable)e).getIndex() < originalIndex) {
        indexBefore++;
      }
    }
    if (e.equals(this)) {
      release=true;
    }
  }
  if (release && isSubstituted()) {
    return new Parameter(name,index + indexBefore,originalIndex);
  }
 else   if (indexBefore != 0) {
    if (substitution == null) {
      return new Parameter(name,index + indexBefore,originalIndex);
    }
 else {
      return new Parameter(name,index + indexBefore,originalIndex,substitution);
    }
  }
 else {
    return this;
  }
}

Fixed version (ground truth):
@Override public Parameter release(Collection<Expression> expressions){
  int indexBefore=0;
  boolean release=false;
  for (  Expression e : expressions) {
    if (e instanceof Indexable && ((Indexable)e).getOriginalIndex() < originalIndex) {
      indexBefore++;
    }
    if (e.equals(this)) {
      release=true;
    }
  }
  if (release && isSubstituted()) {
    return new Parameter(name,index + indexBefore,originalIndex);
  }
 else   if (indexBefore != 0) {
    if (substitution == null) {
      return new Parameter(name,index + indexBefore,originalIndex);
    }
 else {
      return new Parameter(name,index + indexBefore,originalIndex,substitution);
    }
  }
 else {
    return this;
  }
}
Program: 180321
Project: 180321
Buggy source:
@Override public Variable release(Collection<Expression> expressions){
  int indexBefore=0;
  boolean release=false;
  for (  Expression e : expressions) {
    if (!(e instanceof Variable)) {
      if (e instanceof Indexable && ((Indexable)e).getIndex() < originalIndex) {
        indexBefore++;
      }
    }
    if (e.equals(this)) {
      release=true;
    }
  }
  if ((release && isSubstituted()) || indexBefore != 0) {
    return new Variable(name,index + indexBefore,originalIndex);
  }
 else {
    return this;
  }
}

Fixed version (ground truth):
@Override public Variable release(Collection<Expression> expressions){
  int indexBefore=0;
  boolean release=false;
  for (  Expression e : expressions) {
    if (e instanceof Indexable && ((Indexable)e).getOriginalIndex() < originalIndex) {
      indexBefore++;
    }
    if (e.equals(this)) {
      release=true;
    }
  }
  if ((release && isSubstituted()) || indexBefore != 0) {
    return new Variable(name,index + indexBefore,originalIndex);
  }
 else {
    return this;
  }
}
Program: 180322
Project: 180322
Buggy source:
@Override public Integer getKey(String variableName){
  return odeSystem.getVariables().get(variableName).getIndex();
}

Fixed version (ground truth):
@Override public Integer getKey(String variableName){
  if (!odeSystem.getVariables().containsKey(variableName)) {
    throw new IllegalArgumentException("String_Node_Str" + variableName + "String_Node_Str");
  }
  return odeSystem.getVariables().get(variableName).getIndex();
}
Program: 180324
Project: 180324
Buggy source:
private List<Robustness> precomputeRobustness(Monitor subMonitor,FormulaInterval interval){
  Deque<Robustness> lemireDeque=new LemireDeque<>(createComparator());
  List<Robustness> precomputed=new ArrayList<>();
  Iterator<Robustness> window=subMonitor.iterator();
  Iterator<Robustness> current=subMonitor.iterator();
  int currentIndex=0;
  float currentTime=current.next().getTime();
  while (window.hasNext()) {
    Robustness memory=null;
    boolean windowEndReached=false;
    while (window.hasNext() && !windowEndReached) {
      memory=window.next();
      if (memory.getTime() < currentTime + interval.getUpperBound()) {
        lemireDeque.offer(memory);
        memory=null;
      }
 else       if (memory.getTime() == currentTime + interval.getUpperBound()) {
        lemireDeque.offer(memory);
        memory=null;
        windowEndReached=true;
      }
 else {
        windowEndReached=true;
      }
    }
    if (!windowEndReached) {
      return precomputed;
    }
    while (!lemireDeque.isEmpty() && lemireDeque.peekFirst().getTime() < currentTime + interval.getLowerBound()) {
      lemireDeque.remove();
    }
    precomputed.add(lemireDeque.removeFirst());
    currentIndex++;
    currentTime=current.next().getTime();
    if (memory != null) {
      lemireDeque.offer(memory);
      memory=null;
    }
  }
  return precomputed;
}

Fixed version (ground truth):
private List<Robustness> precomputeRobustness(Monitor subMonitor,FormulaInterval interval){
  Deque<Robustness> lemireDeque=new LemireDeque<>(createComparator());
  List<Robustness> precomputed=new ArrayList<>();
  Iterator<Robustness> window=subMonitor.iterator();
  Iterator<Robustness> current=subMonitor.iterator();
  int currentIndex=0;
  float currentTime=current.next().getTime();
  while (window.hasNext()) {
    Robustness memory=null;
    boolean windowEndReached=false;
    while (window.hasNext() && !windowEndReached) {
      memory=window.next();
      if (memory.getTime() < currentTime + interval.getUpperBound()) {
        lemireDeque.offer(memory);
        memory=null;
      }
 else       if (memory.getTime() == currentTime + interval.getUpperBound()) {
        lemireDeque.offer(memory);
        memory=null;
        windowEndReached=true;
      }
 else {
        windowEndReached=true;
      }
    }
    if (!windowEndReached) {
      return precomputed;
    }
    while (!lemireDeque.isEmpty() && lemireDeque.peekFirst().getTime() < currentTime + interval.getLowerBound()) {
      lemireDeque.remove();
    }
    Robustness found=lemireDeque.peekFirst();
    precomputed.add(new SimpleRobustness(found.getValue(),currentTime,consideredDimensions));
    currentIndex++;
    currentTime=current.next().getTime();
    if (memory != null) {
      lemireDeque.offer(memory);
      memory=null;
    }
  }
  return precomputed;
}
Program: 180325
Project: 180325
Buggy source:
public AbstractUnaryTemporalMonitor(Property property,Monitor subMonitor,FormulaInterval interval){
  super(property);
  Validate.notNull(interval);
  Validate.notNull(subMonitor);
  this.suMonitor=subMonitor;
  this.robustnesses=precomputeRobustness(subMonitor,interval);
}

Fixed version (ground truth):
public AbstractUnaryTemporalMonitor(Property property,Monitor subMonitor,FormulaInterval interval,Collection<Integer> consideredDimensions){
  super(property);
  Validate.notNull(interval);
  Validate.notNull(subMonitor);
  Validate.notNull(consideredDimensions);
  this.suMonitor=subMonitor;
  this.robustnesses=precomputeRobustness(subMonitor,interval);
  this.consideredDimensions=consideredDimensions;
}
Program: 180326
Project: 180326
Buggy source:
public FutureMonitor(Property property,Monitor subMonitor,FormulaInterval interval){
  super(property,subMonitor,interval);
}

Fixed version (ground truth):
public FutureMonitor(Property property,Monitor subMonitor,FormulaInterval interval,Collection<Integer> consideredDimensions){
  super(property,subMonitor,interval,consideredDimensions);
}
Program: 180327
Project: 180327
Buggy source:
public GloballyMonitor(Property property,Monitor subMonitor,FormulaInterval interval){
  super(property,subMonitor,interval);
}

Fixed version (ground truth):
public GloballyMonitor(Property property,Monitor subMonitor,FormulaInterval interval,Collection<Integer> consideredDimensions){
  super(property,subMonitor,interval,consideredDimensions);
}
Program: 180329
Project: 180329
Buggy source:
@Test public void testFutureMonitorIncreasing(){
  Monitor subMonitor=createIncreasingTestMonitor(10,1);
  Monitor future=new FutureMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED));
  Monitor expected=createTestMonitor(4,5,6,7,8,9);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}

Fixed version (ground truth):
@Test public void testFutureMonitorIncreasing(){
  Monitor subMonitor=createIncreasingTestMonitor(10,1);
  Monitor future=new FutureMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED),Collections.EMPTY_LIST);
  Monitor expected=createTestMonitor(4,5,6,7,8,9);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}
Program: 180330
Project: 180330
Buggy source:
@Test public void testFutureMonitorDecreasing(){
  Monitor subMonitor=createDecreasingTestMonitor(10,1);
  Monitor future=new FutureMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED));
  Monitor expected=createTestMonitor(7,6,5,4,3,2);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}

Fixed version (ground truth):
@Test public void testFutureMonitorDecreasing(){
  Monitor subMonitor=createDecreasingTestMonitor(10,1);
  Monitor future=new FutureMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED),Collections.EMPTY_LIST);
  Monitor expected=createTestMonitor(7,6,5,4,3,2);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}
Program: 180331
Project: 180331
Buggy source:
@Test public void testGloballyMonitorDecreasing(){
  Monitor subMonitor=createDecreasingTestMonitor(10,1);
  Monitor future=new GloballyMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED));
  Monitor expected=createTestMonitor(5,4,3,2,1,0);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}

Fixed version (ground truth):
@Test public void testGloballyMonitorDecreasing(){
  Monitor subMonitor=createDecreasingTestMonitor(10,1);
  Monitor future=new GloballyMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED),Collections.EMPTY_LIST);
  Monitor expected=createTestMonitor(5,4,3,2,1,0);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}
Program: 180332
Project: 180332
Buggy source:
@Test public void testGloballyMonitorIncreasing(){
  Monitor subMonitor=createIncreasingTestMonitor(10,1);
  Monitor future=new GloballyMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED));
  Monitor expected=createTestMonitor(2,3,4,5,6,7);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}

Fixed version (ground truth):
@Test public void testGloballyMonitorIncreasing(){
  Monitor subMonitor=createIncreasingTestMonitor(10,1);
  Monitor future=new GloballyMonitor(EMPTY_PROPERTY,subMonitor,new TimeInterval(2,4,IntervalBoundaryType.CLOSED),Collections.EMPTY_LIST);
  Monitor expected=createTestMonitor(2,3,4,5,6,7);
  assertEquals(future.size(),expected.size(),"String_Node_Str");
  for (int i=0; i < expected.size(); i++) {
    assertEquals(future.getRobustness(i).getValue(),expected.getRobustness(i).getValue(),"String_Node_Str" + i + "String_Node_Str");
  }
}
Program: 180334
Project: 180334
Buggy source:
public void register(ExtensionBuilder builder){
  builder.extension(SimulatorRegistrar.class);
  builder.extension(ConfigurationRegistrar.class);
}

Fixed version (ground truth):
@Override public void register(ExtensionBuilder builder){
  builder.extension(SimulatorRegistrar.class);
  builder.extension(ConfigurationRegistrar.class);
}
Program: 180335
Project: 180335
Buggy source:
@Provide public AdaptiveStepSimulator registerAdaptiveStepSimulator(ComputationSimulationConfiguration configuration){
  return new SimpleAdaptiveStepSimulator(new LsodeEngineFactory());
}

Fixed version (ground truth):
@Provide public AdaptiveStepSimulator registerAdaptiveStepSimulator(ComputationSimulationConfiguration configuration){
  if (configuration.getOdepkgFunction() == null) {
    LOGGER.debug("String_Node_Str");
    return new SimpleAdaptiveStepSimulator(new LsodeEngineFactory(configuration.getLsodeIntegrationMethod()));
  }
 else {
    if (configuration.getOdepkgFunction().isAvailable()) {
      LOGGER.debug("String_Node_Str" + configuration.getOdepkgFunction().name() + "String_Node_Str");
      return new SimpleAdaptiveStepSimulator(configuration.getOdepkgFunction());
    }
 else {
      LOGGER.warn("String_Node_Str" + configuration.getOdepkgFunction().name() + "String_Node_Str");
      return new SimpleAdaptiveStepSimulator(new LsodeEngineFactory(configuration.getLsodeIntegrationMethod()));
    }
  }
}
Program: 180336
Project: 180336
Buggy source:
@Override public <T extends Trajectory>SimulatedDataBlock<T> simulate(AdaptiveStepConfiguration configuration,DataBlock<T> data){
  SimulationEngine simulationEngine=simulationEngineFactory.simulationEngine(configuration.getMaxNumberOfIterations(),configuration.getPrecisionConfiguration().getMaxRelativeError());
  List<T> trajectories=new ArrayList<>(data.size());
  Status[] statuses=new Status[data.size()];
  for (int i=0; i < data.size(); i++) {
    Trajectory simulated=simulationEngine.simulate(data.getTrajectory(i).getLastPoint(),configuration.getOdeSystem(),configuration.getPrecisionConfiguration().getTimeStep(),configuration.getSpace().getMaxBounds().getTime());
    LinkedTrajectory trajectory=data.getTrajectory(i) instanceof LinkedTrajectory ? (LinkedTrajectory)data.getTrajectory(i) : (data.getTrajectory(i) instanceof TrajectoryWithNeighborhood ? LinkedTrajectory.createAndUpdateReferenceWithNeighborhood((TrajectoryWithNeighborhood)data.getTrajectory(i)) : LinkedTrajectory.createAndUpdateReference(data.getTrajectory(i)));
    trajectory.append(simulated);
    trajectories.add((T)trajectory);
    if (simulated.getLastPoint().getTime() < configuration.getSpace().getMaxBounds().getTime()) {
      statuses[i]=Status.TIMEOUT;
    }
 else {
      statuses[i]=Status.OK;
    }
  }
  simulationEngine.close();
  return new ArraySimulatedDataBlock<>(new ListDataBlock<>(trajectories),statuses);
}

Fixed version (ground truth):
@Override public <T extends Trajectory>SimulatedDataBlock<T> simulate(AdaptiveStepConfiguration configuration,DataBlock<T> data){
  SimulationEngine simulationEngine=simulationEngineFactory.simulationEngine(configuration.getMaxNumberOfIterations(),configuration.getPrecisionConfiguration().getMaxRelativeError());
  try {
    List<T> trajectories=new ArrayList<>(data.size());
    Status[] statuses=new Status[data.size()];
    for (int i=0; i < data.size(); i++) {
      Trajectory simulated=simulationEngine.simulate(data.getTrajectory(i).getLastPoint(),configuration.getOdeSystem(),configuration.getPrecisionConfiguration().getTimeStep(),configuration.getSpace().getMaxBounds().getTime());
      LinkedTrajectory trajectory=data.getTrajectory(i) instanceof LinkedTrajectory ? (LinkedTrajectory)data.getTrajectory(i) : (data.getTrajectory(i) instanceof TrajectoryWithNeighborhood ? LinkedTrajectory.createAndUpdateReferenceWithNeighborhood((TrajectoryWithNeighborhood)data.getTrajectory(i)) : LinkedTrajectory.createAndUpdateReference(data.getTrajectory(i)));
      trajectory.append(simulated);
      trajectories.add((T)trajectory);
      if (simulated.getLastPoint().getTime() < configuration.getSpace().getMaxBounds().getTime()) {
        statuses[i]=Status.TIMEOUT;
      }
 else {
        statuses[i]=Status.OK;
      }
    }
    return new ArraySimulatedDataBlock<>(new ListDataBlock<>(trajectories),statuses);
  }
  finally {
    simulationEngine.close();
  }
}
Program: 180337
Project: 180337
Buggy source:
@Override protected OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,double timeStep){
  getOctave().eval(odeSystem.octaveString());
  getOctave().eval("String_Node_Str" + Arrays.toString(point.toArray(odeSystem.dimension())) + "String_Node_Str");
  getOctave().eval("String_Node_Str" + point.getTime() + "String_Node_Str"+ numberOfIterations * timeStep + "String_Node_Str" + numberOfIterations + "String_Node_Str");
  getOctave().eval("String_Node_Str" + odeSystem.octaveName() + "String_Node_Str");
  return getOctave().get(OctaveDouble.class,"String_Node_Str");
}

Fixed version (ground truth):
@Override protected OctaveDouble rawSimulation(Point point,OctaveOdeSystem odeSystem,long numberOfIterations,double timeStep){
  getOctave().eval(odeSystem.octaveString(false));
  getOctave().eval("String_Node_Str" + Arrays.toString(point.toArray(odeSystem.getVariables().size())) + "String_Node_Str");
  getOctave().eval("String_Node_Str" + point.getTime() + "String_Node_Str"+ numberOfIterations * timeStep + "String_Node_Str" + numberOfIterations + "String_Node_Str");
  getOctave().eval("String_Node_Str" + odeSystem.octaveName() + "String_Node_Str");
  return getOctave().get(OctaveDouble.class,"String_Node_Str");
}
Program: 180338
Project: 180338
Buggy source:
@Override public SimulationEngine simulationEngine(long stepLimit,double relativeTolerance){
  return new LsodeEngine(new OctaveEngineFactory().getScriptEngine(),stepLimit,relativeTolerance);
}

Fixed version (ground truth):
@Override public SimulationEngine simulationEngine(long stepLimit,double relativeTolerance){
  return new LsodeEngine(new OctaveEngineFactory().getScriptEngine(),integrationMethod,stepLimit,relativeTolerance);
}
Program: 180339
Project: 180339
Buggy source:
public LsodeEngine(OctaveEngine octave,long stepLimit,double relativeTolerance){
  super(octave,stepLimit,relativeTolerance);
  getOctave().eval("String_Node_Str" + stepLimit + "String_Node_Str");
  if (relativeTolerance > 0) {
    getOctave().eval("String_Node_Str" + relativeTolerance + "String_Node_Str");
  }
}

Fixed version (ground truth):
public LsodeEngine(OctaveEngine octave,IntegrationMethod integrationMethod,long stepLimit,double relativeTolerance){
  super(octave,stepLimit,relativeTolerance);
  getOctave().eval("String_Node_Str" + stepLimit + "String_Node_Str");
  if (relativeTolerance > 0) {
    getOctave().eval("String_Node_Str" + relativeTolerance + "String_Node_Str");
  }
  getOctave().eval("String_Node_Str" + integrationMethod.getName() + "String_Node_Str");
}
Program: 180340
Project: 180340
Buggy source:
@Test public void testSimulatorLoaded(){
  assertNotNull(manager.resolve(AdaptiveStepSimulator.class,Default.class,manager.getRootContext()));
}

Fixed version (ground truth):
@Test public void testSimulatorLoaded(){
  Context context=new AbstractContext(){
    @Override public Class<? extends Annotation> getScope(){
      return ComputationInstanceScope.class;
    }
  }
;
  manager.initializeContext(context);
  assertNotNull(manager.resolve(AdaptiveStepSimulator.class,Default.class,context));
}
Program: 180341
Project: 180341
Buggy source:
@Test public void testConfigurationLoaded(){
  Context context=new AbstractContext(){
    public Class<? extends Annotation> getScope(){
      return ComputationInstanceScope.class;
    }
  }
;
  manager.initializeContext(context);
  assertNotNull(manager.resolve(AdaptiveStepConfiguration.class,Default.class,context));
}

Fixed version (ground truth):
@Test public void testConfigurationLoaded(){
  Context context=new AbstractContext(){
    @Override public Class<? extends Annotation> getScope(){
      return ComputationInstanceScope.class;
    }
  }
;
  manager.initializeContext(context);
  assertNotNull(manager.resolve(AdaptiveStepConfiguration.class,Default.class,context));
}
Program: 180342
Project: 180342
Buggy source:
public Class<? extends Annotation> getScope(){
  return ComputationInstanceScope.class;
}

Fixed version (ground truth):
@Override public Class<? extends Annotation> getScope(){
  return ComputationInstanceScope.class;
}
Program: 180343
Project: 180343
Buggy source:
@Override public FormulaInterval getObject(Node source) throws XMLFormatException {
  NodeList bounds=source.getChildNodes();
  float upper=0;
  float lower=0;
  IntervalBoundaryType upperType=null;
  IntervalBoundaryType lowerType=null;
  for (int index=0; index < bounds.getLength(); index++) {
    Node bound=bounds.item(index);
    if (bound.getNodeName().equals(LOWER_NAME)) {
      lower=FloatFactory.getObject(bound.getFirstChild());
      lowerType=getBoundaryType(bound);
    }
 else     if (bound.getNodeName().equals(UPPER_NAME)) {
      upper=FloatFactory.getObject(bound.getFirstChild());
      upperType=getBoundaryType(bound);
    }
 else {
      throw new XMLFormatException("String_Node_Str" + bound.getNodeName() + "String_Node_Str"+ UPPER_NAME+ "String_Node_Str"+ LOWER_NAME+ "String_Node_Str");
    }
  }
  if (upperType == null) {
    throw new XMLFormatException("String_Node_Str");
  }
  if (lowerType == null) {
    throw new XMLFormatException("String_Node_Str");
  }
  if (lower <= 0) {
    throw new XMLFormatException("String_Node_Str");
  }
  if (upper < lower) {
    throw new XMLFormatException("String_Node_Str");
  }
  return new TimeInterval(lower,upper,lowerType,upperType);
}

Fixed version (ground truth):
@Override public FormulaInterval getObject(Node source) throws XMLFormatException {
  NodeList bounds=source.getChildNodes();
  float upper=0;
  float lower=0;
  IntervalBoundaryType upperType=null;
  IntervalBoundaryType lowerType=null;
  for (int index=0; index < bounds.getLength(); index++) {
    Node bound=bounds.item(index);
    if (bound.getNodeName().equals(LOWER_NAME)) {
      lower=FloatFactory.getObject(bound.getFirstChild());
      lowerType=getBoundaryType(bound);
    }
 else     if (bound.getNodeName().equals(UPPER_NAME)) {
      upper=FloatFactory.getObject(bound.getFirstChild());
      upperType=getBoundaryType(bound);
    }
 else {
      throw new XMLFormatException("String_Node_Str" + bound.getNodeName() + "String_Node_Str"+ UPPER_NAME+ "String_Node_Str"+ LOWER_NAME+ "String_Node_Str");
    }
  }
  if (upperType == null) {
    throw new XMLFormatException("String_Node_Str");
  }
  if (lowerType == null) {
    throw new XMLFormatException("String_Node_Str");
  }
  if (lower < 0) {
    throw new XMLFormatException("String_Node_Str");
  }
  if (upper < lower) {
    throw new XMLFormatException("String_Node_Str");
  }
  return new TimeInterval(lower,upper,lowerType,upperType);
}
Program: 180344
Project: 180344
Buggy source:
@Override public LimitedDistance distance(Point first,Point second){
  final Distance distance=EUCLIDEAN_METRIC.distance(first,second);
  return new LimitedDistance(){
    public boolean isValid(){
      return distance.value() >= Math.abs(value);
    }
    public float value(){
      return distance.value();
    }
  }
;
}

Fixed version (ground truth):
@Override public LimitedDistance distance(Point first,Point second){
  final Distance distance=EUCLIDEAN_METRIC.distance(first,second);
  return new LimitedDistance(){
    public boolean isValid(){
      return distance.value() <= Math.abs(value);
    }
    public float value(){
      return distance.value();
    }
  }
;
}
Program: 180345
Project: 180345
Buggy source:
public boolean isValid(){
  return distance.value() >= Math.abs(value);
}

Fixed version (ground truth):
public boolean isValid(){
  return distance.value() <= Math.abs(value);
}
Program: 180347
Project: 180347
Buggy source:
private void fireProcessing(ApplicationContext applicationContext) throws Exception {
  final Collection<Class<?>> newExtensions=new ArrayList<Class<?>>();
  final Collection<Class<? extends Context>> newContexts=new ArrayList<Class<? extends Context>>();
  fire(new ManagerProcessing(){
    public void extension(    Class<?> extension){
      if (extension == null) {
        throw new IllegalArgumentException("String_Node_Str");
      }
      newExtensions.add(extension);
    }
    public Manager getManager(){
      return ManagerImpl.this;
    }
  }
,applicationContext);
  Map<Class<? extends Annotation>,Collection<Class<?>>> newExtensionsByScope=getScopedExtensions(newExtensions);
  for (  Entry<Class<? extends Annotation>,Collection<Class<?>>> entry : newExtensionsByScope.entrySet()) {
    if (!extensionsByScope.containsKey(entry.getKey())) {
      extensionsByScope.put(entry.getKey(),new ArrayList<Class<?>>());
    }
    extensionsByScope.get(entry.getKey()).addAll(entry.getValue());
  }
  extensionsByContext.get(applicationContext).addAll(createExtensions(newExtensions,applicationContext));
}

Fixed version (ground truth):
private void fireProcessing(ApplicationContext applicationContext) throws Exception {
  final Collection<Class<?>> newExtensions=new ArrayList<Class<?>>();
  final Collection<Class<? extends Context>> newContexts=new ArrayList<Class<? extends Context>>();
  fire(new ManagerProcessing(){
    public void extension(    Class<?> extension){
      if (extension == null) {
        throw new IllegalArgumentException("String_Node_Str");
      }
      newExtensions.add(extension);
    }
    public Manager getManager(){
      return ManagerImpl.this;
    }
  }
,applicationContext);
  Map<Class<? extends Annotation>,Collection<Class<?>>> newExtensionsByScope=getScopedExtensions(newExtensions);
  for (  Entry<Class<? extends Annotation>,Collection<Class<?>>> entry : newExtensionsByScope.entrySet()) {
    if (!extensionsByScope.containsKey(entry.getKey())) {
      extensionsByScope.put(entry.getKey(),new ArrayList<Class<?>>());
    }
    extensionsByScope.get(entry.getKey()).addAll(entry.getValue());
  }
  if (newExtensionsByScope.get(ApplicationScope.class) != null) {
    extensionsByContext.get(applicationContext).addAll(createExtensions(newExtensionsByScope.get(ApplicationScope.class),applicationContext));
  }
}
Program: 180348
Project: 180348
Buggy source:
private void injectField(Object object,Field field,Context context){
  Class<? extends Annotation> qualifier=loadQualifier(field.getDeclaredAnnotations());
  Object service=null;
  if (qualifier != null) {
    service=getService(field.getType(),context,qualifier);
  }
 else {
    service=getService(field.getType(),context);
  }
  if (service == null) {
    throw new IllegalStateException("String_Node_Str" + field.getType().getName() + "String_Node_Str"+ object.getClass().getName()+ "String_Node_Str");
  }
  field.setAccessible(true);
  try {
    field.set(object,field.getType().cast(service));
  }
 catch (  Exception ex) {
    throw new IllegalStateException("String_Node_Str",ex);
  }
}

Fixed version (ground truth):
private void injectField(Object object,Field field,Context context){
  Class<? extends Annotation> qualifier=loadQualifier(field.getDeclaredAnnotations());
  Object service=null;
  if (qualifier != null) {
    service=getService(field.getType(),context,qualifier);
  }
 else {
    service=getService(field.getType(),context);
  }
  if (service == null) {
    throw new IllegalStateException("String_Node_Str" + field.getType().getName() + "String_Node_Str"+ object.getClass().getName()+ "String_Node_Str"+ context+ "String_Node_Str");
  }
  field.setAccessible(true);
  try {
    field.set(object,field.getType().cast(service));
  }
 catch (  Exception ex) {
    throw new IllegalStateException("String_Node_Str",ex);
  }
}
Program: 180350
Project: 180350
Buggy source:
@Test public void testLoad() throws Exception {
  System.setProperty("String_Node_Str","String_Node_Str");
  Manager manager=ManagerImpl.create();
  manager.start();
  assertNotNull(manager.resolve(TrajectorySpawner.class,Default.class,manager.getRootContext()));
  assertNotNull(manager.resolve(DistanceChecker.class,Default.class,manager.getRootContext()));
}

Fixed version (ground truth):
@Test(enabled=false) public void testLoad() throws Exception {
  System.setProperty("String_Node_Str","String_Node_Str");
  Manager manager=ManagerImpl.create();
  manager.start();
  assertNotNull(manager.resolve(TrajectorySpawner.class,Default.class,manager.getRootContext()));
  assertNotNull(manager.resolve(DistanceChecker.class,Default.class,manager.getRootContext()));
}
Program: 180352
Project: 180352
Buggy source:
@Override public Point getPoint(int index){
  return data.getTrajectory(index).getFirstPoint();
}

Fixed version (ground truth):
@Override public Point getPoint(int index){
  return data.getTrajectory(index).getReference().getTrajectory().getFirstPoint();
}
Program: 180354
Project: 180354
Buggy source:
public VerificationResult merge(VerificationResult toMerge){
  if (toMerge == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  Robustness[] newRobustnesses=new Robustness[size() + toMerge.size()];
  Point[] newPoints=new Point[size() + size()];
  for (int i=0; i < size(); i++) {
    newPoints[i]=getPoint(i);
    newRobustnesses[i]=getRobustness(i);
  }
  for (int i=0; i < toMerge.size(); i++) {
    newPoints[size() + i]=toMerge.getPoint(i);
    newRobustnesses[size() + i]=toMerge.getRobustness(i);
  }
  return new ArrayVerificationResult(size() + size(),newPoints,newRobustnesses);
}

Fixed version (ground truth):
public VerificationResult merge(VerificationResult toMerge){
  if (toMerge == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  Robustness[] newRobustnesses=new Robustness[size() + toMerge.size()];
  Point[] newPoints=new Point[size() + toMerge.size()];
  for (int i=0; i < size(); i++) {
    newPoints[i]=getPoint(i);
    newRobustnesses[i]=getRobustness(i);
  }
  for (int i=0; i < toMerge.size(); i++) {
    newPoints[size() + i]=toMerge.getPoint(i);
    newRobustnesses[size() + i]=toMerge.getRobustness(i);
  }
  return new ArrayVerificationResult(size() + toMerge.size(),newPoints,newRobustnesses);
}
Program: 180355
Project: 180355
Buggy source:
public VerificationResult merge(VerificationResult toMerge){
  if (toMerge == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  Robustness[] newRobustnesses=new Robustness[size() + toMerge.size()];
  Point[] newPoints=new Point[size() + size()];
  System.arraycopy(points,0,newPoints,0,points.length);
  System.arraycopy(robustness,0,newRobustnesses,0,robustness.length);
  for (int i=0; i < toMerge.size(); i++) {
    newPoints[size() + i]=toMerge.getPoint(i);
    newRobustnesses[size() + i]=toMerge.getRobustness(i);
  }
  return new ArrayVerificationResult(size() + size(),newPoints,newRobustnesses);
}

Fixed version (ground truth):
public VerificationResult merge(VerificationResult toMerge){
  if (toMerge == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  Robustness[] newRobustnesses=new Robustness[size() + toMerge.size()];
  Point[] newPoints=new Point[size() + toMerge.size()];
  System.arraycopy(points,0,newPoints,0,points.length);
  System.arraycopy(robustness,0,newRobustnesses,0,robustness.length);
  for (int i=0; i < toMerge.size(); i++) {
    newPoints[size() + i]=toMerge.getPoint(i);
    newRobustnesses[size() + i]=toMerge.getRobustness(i);
  }
  return new ArrayVerificationResult(size() + toMerge.size(),newPoints,newRobustnesses);
}
Program: 180357
Project: 180357
Buggy source:
@Override public float getValue(Point p){
  float leftSide=getLeftSideValue(p);
  float diff=Math.abs(leftSide - constant);
  if (isValid(leftSide,constant)) {
    diff=-diff;
  }
  return diff;
}

Fixed version (ground truth):
@Override public float getValue(Point p){
  float leftSide=getLeftSideValue(p);
  float diff=Math.abs(leftSide - constant);
  if (!isValid(leftSide,constant)) {
    diff=-diff;
  }
  return diff;
}
Program: 180358
Project: 180358
Buggy source:
public <T>T get(Class<T> type,Class<? extends Annotation> qualifier){
  if (type == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  Map<Class<? extends Annotation>,Object> qualifiedInstances=instances.get(type);
  if (qualifiedInstances == null) {
    return null;
  }
  if (qualifier.equals(Any.class)) {
    if (qualifiedInstances.size() > 1) {
      throw new AmbigousException("String_Node_Str" + type.getName() + "String_Node_Str");
    }
    for (    Object o : qualifiedInstances.values()) {
      return type.cast(o);
    }
  }
 else {
    Class<? extends Annotation> toFind=qualifier;
    while (!toFind.equals(Empty.class)) {
      if (Proxy.isProxyClass(toFind)) {
        toFind=(Class<? extends Annotation>)toFind.getInterfaces()[0];
      }
      Qualifier qualified=toFind.getAnnotation(Qualifier.class);
      if (qualified == null) {
        throw new IllegalArgumentException("String_Node_Str" + toFind.getName() + "String_Node_Str"+ Qualifier.class.getName()+ "String_Node_Str"+ Arrays.toString(toFind.getAnnotations()));
      }
      Object o=qualifiedInstances.get(toFind);
      if (o != null) {
        return type.cast(o);
      }
 else {
        toFind=qualified.parent();
      }
    }
  }
  return type.cast(instances.get(type));
}

Fixed version (ground truth):
public <T>T get(Class<T> type,Class<? extends Annotation> qualifier){
  if (type == null) {
    throw new IllegalArgumentException("String_Node_Str");
  }
  Map<Class<? extends Annotation>,Object> qualifiedInstances=instances.get(type);
  if (qualifiedInstances == null) {
    return null;
  }
  if (qualifier.equals(Any.class)) {
    if (qualifiedInstances.size() > 1) {
      throw new AmbigousException("String_Node_Str" + type.getName() + "String_Node_Str");
    }
    for (    Object o : qualifiedInstances.values()) {
      return type.cast(o);
    }
  }
 else {
    Class<? extends Annotation> toFind=qualifier;
    while (!toFind.equals(Empty.class)) {
      if (Proxy.isProxyClass(toFind)) {
        toFind=(Class<? extends Annotation>)toFind.getInterfaces()[0];
      }
      Qualifier qualified=toFind.getAnnotation(Qualifier.class);
      if (qualified == null) {
        throw new IllegalArgumentException("String_Node_Str" + toFind.getName() + "String_Node_Str"+ Qualifier.class.getName()+ "String_Node_Str"+ Arrays.toString(toFind.getAnnotations()));
      }
      Object o=qualifiedInstances.get(toFind);
      if (o != null) {
        return type.cast(o);
      }
 else {
        toFind=qualified.parent();
      }
    }
  }
  throw new IllegalArgumentException("String_Node_Str" + type.getName() + "String_Node_Str"+ (Proxy.isProxyClass(qualifier) ? qualifier.getInterfaces()[0].getSimpleName() : qualifier.getSimpleName())+ "String_Node_Str");
}
Program: 180359
Project: 180359
Buggy source:
public Object value(){
  Object[] params=new Object[getMethod().getParameterTypes().length];
  for (int i=0; i < params.length; i++) {
    params[i]=context.resolve(getMethod().getParameterTypes()[i],loadQualifier(getMethod().getParameterTypes()[i].getDeclaredAnnotations()));
    if (params[i] == null) {
      throw new InvocationException("String_Node_Str" + getMethod().getParameterTypes()[i].getName() + "String_Node_Str");
    }
  }
  try {
    if (!getMethod().isAccessible()) {
      getMethod().setAccessible(true);
    }
    return getMethod().invoke(getTarget(),params);
  }
 catch (  IllegalAccessException ex) {
    throw new InvocationException(ex);
  }
catch (  IllegalArgumentException ex) {
    throw new InvocationException(ex);
  }
catch (  InvocationTargetException ex) {
    throw new InvocationException(ex);
  }
}

Fixed version (ground truth):
public Object value(){
  Object[] params=new Object[getMethod().getParameterTypes().length];
  for (int i=0; i < params.length; i++) {
    params[i]=context.resolve(getMethod().getParameterTypes()[i],loadQualifier(getMethod().getParameterAnnotations()[i]));
    if (params[i] == null) {
      throw new InvocationException("String_Node_Str" + getMethod().getParameterTypes()[i].getName() + "String_Node_Str");
    }
  }
  try {
    if (!getMethod().isAccessible()) {
      getMethod().setAccessible(true);
    }
    return getMethod().invoke(getTarget(),params);
  }
 catch (  IllegalAccessException ex) {
    throw new InvocationException(ex);
  }
catch (  IllegalArgumentException ex) {
    throw new InvocationException(ex);
  }
catch (  InvocationTargetException ex) {
    throw new InvocationException(ex);
  }
}
Program: 180360
Project: 180360
Buggy source:
public Monitor createMonitor(Trajectory trajectory,Formula property){
  if (trajectory.getLastPoint().getTime() < property.getTimeNeeded()) {
    throw new IllegalArgumentException("String_Node_Str" + property.getTimeNeeded() + "String_Node_Str"+ trajectory.getLastPoint().getTime()+ "String_Node_Str");
  }
switch (property.getType()) {
case AND:
    return new AndMonitor(createMonitor(trajectory,property.getSubformula(0)),createMonitor(trajectory,property.getSubformula(1)));
case FUTURE:
  return new FutureMonitor(createMonitor(trajectory,property.getSubformula(0)),((FutureFormula)property).getInterval());
case GLOBALLY:
return new GloballyMonitor(createMonitor(trajectory,property.getSubformula(0)),((FutureFormula)property).getInterval());
case NOT:
return new NotMonitor(createMonitor(trajectory,property.getSubformula(0)));
case OR:
return new OrMonitor(createMonitor(trajectory,property.getSubformula(0)),createMonitor(trajectory,property.getSubformula(1)));
case PREDICATE:
return new PredicateMonitor(trajectory,(Predicate)property);
default :
throw new UnsupportedOperationException("String_Node_Str" + property.getType() + "String_Node_Str");
}
}

Fixed version (ground truth):
public Monitor createMonitor(Trajectory trajectory,Formula property){
  if (trajectory.getLastPoint().getTime() < property.getTimeNeeded()) {
    throw new IllegalArgumentException("String_Node_Str" + property.getTimeNeeded() + "String_Node_Str"+ trajectory.getLastPoint().getTime()+ "String_Node_Str");
  }
switch (property.getType()) {
case AND:
    return new AndMonitor(createMonitor(trajectory,property.getSubformula(0)),createMonitor(trajectory,property.getSubformula(1)));
case FUTURE:
  return new FutureMonitor(createMonitor(trajectory,property.getSubformula(0)),((FutureFormula)property).getInterval());
case GLOBALLY:
return new GloballyMonitor(createMonitor(trajectory,property.getSubformula(0)),((GloballyFormula)property).getInterval());
case NOT:
return new NotMonitor(createMonitor(trajectory,property.getSubformula(0)));
case OR:
return new OrMonitor(createMonitor(trajectory,property.getSubformula(0)),createMonitor(trajectory,property.getSubformula(1)));
case PREDICATE:
return new PredicateMonitor(trajectory,(Predicate)property);
default :
throw new UnsupportedOperationException("String_Node_Str" + property.getType() + "String_Node_Str");
}
}