Skip to content

Commit

Permalink
Remove phase jump correction
Browse files Browse the repository at this point in the history
  • Loading branch information
AngelFP committed Nov 15, 2023
1 parent 70d3ef2 commit 7fcf23d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 20 deletions.
10 changes: 0 additions & 10 deletions wake_t/physics_models/laser/envelope_solver.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,16 +102,6 @@ def evolve_envelope(
d_theta1 = phases[j + 1] - phases[j]
d_theta2 = phases[j + 2] - phases[j + 1]

# Prevent phase jumps bigger than 1.5*pi.
if d_theta1 < -1.5 * np.pi:
d_theta1 += 2 * np.pi
if d_theta2 < -1.5 * np.pi:
d_theta2 += 2 * np.pi
if d_theta1 > 1.5 * np.pi:
d_theta1 -= 2 * np.pi
if d_theta2 > 1.5 * np.pi:
d_theta2 -= 2 * np.pi

# Calculate D factor [Eq. (6)].
D_jkn = (1.5 * d_theta1 - 0.5 * d_theta2) * inv_dz

Expand Down
10 changes: 0 additions & 10 deletions wake_t/physics_models/laser/envelope_solver_non_centered.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,16 +102,6 @@ def evolve_envelope_non_centered(
d_theta1 = phases[j + 1] - phases[j]
d_theta2 = phases[j + 2] - phases[j + 1]

# Prevent phase jumps bigger than 1.5*pi.
if d_theta1 < -1.5 * np.pi:
d_theta1 += 2 * np.pi
if d_theta2 < -1.5 * np.pi:
d_theta2 += 2 * np.pi
if d_theta1 > 1.5 * np.pi:
d_theta1 -= 2 * np.pi
if d_theta2 > 1.5 * np.pi:
d_theta2 -= 2 * np.pi

# Calculate D factor [Eq. (6)].
D_jkn = (1.5 * d_theta1 - 0.5 * d_theta2) * inv_dz

Expand Down

0 comments on commit 7fcf23d

Please sign in to comment.