Skip to content

Commit

Permalink
removes sign from first order kick
Browse files Browse the repository at this point in the history
  • Loading branch information
oscarxblanco committed Dec 21, 2023
1 parent 560e7ba commit 8157d2b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion atmat/pubtools/create_elems/atidtable_dat.m
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
emassGeV = PhysConstant.electron_mass_energy_equivalent_in_MeV.value/1e3;

% energy scaling for 1st order kick-map
factor1 = -1 / (1e9*sqrt(Energy ^2 - emassGeV^2 )/ lightspeed);
factor1 = 1 / (1e9*sqrt(Energy ^2 - emassGeV^2 )/ lightspeed);
% energy scaling for 2st order kick-map
factor2 = (factor1) ^ 2;

Expand Down
2 changes: 1 addition & 1 deletion pyat/at/lattice/idtable_element.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ def sorted_table(table_in, sorted_index, order_axis):
xkick2 = factor2 * hkickmap2
ykick2 = factor2 * vkickmap2
# kick1 vars
factor1 = -1.0/(Brho)
factor1 = 1.0/(Brho)
xkick1 = factor1 * hkickmap1
ykick1 = factor1 * vkickmap1
# axes
Expand Down

0 comments on commit 8157d2b

Please sign in to comment.