diff --git a/MOT Capture Process Simulation/@MOTSimulator/computeTimeSpentInInteractionRegion.m b/MOT Capture Process Simulation/@MOTSimulator/computeTimeSpentInInteractionRegion.m index b7d9705..4fae3f8 100644 --- a/MOT Capture Process Simulation/@MOTSimulator/computeTimeSpentInInteractionRegion.m +++ b/MOT Capture Process Simulation/@MOTSimulator/computeTimeSpentInInteractionRegion.m @@ -9,7 +9,7 @@ function T = computeTimeSpentInInteractionRegion(this, r) T = 0; NumberOfTimeSteps = int64(this.SimulationTime/this.TimeStep); for n = 1:(NumberOfTimeSteps - 1) - dr = Helper.calculateDistanceFromPointToLine(r(n+1, :), [0 0 0], [1 0 0]); + dr = Helper.calculateDistanceFromPointToLine(r(n+1, :), [0 0 0], [0 0 1]); if dr < this.CoolingBeamRadius A = 1; else