Skip to content

Commit 3777663

Browse files
authored
Fix ohmienvelope with wigglers (#870)
* Typo in GWigSymplecticRadPass * Added EnergyLossRadPass * fix Matlab bug: string -> char array
1 parent 4a92361 commit 3777663

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

atmat/atphysics/Radiation/atdiffmat.m

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@
1515

1616
newmethods = {'BndMPoleSymplectic4RadPass', ...
1717
'StrMPoleSymplectic4RadPass', ...
18-
'ExactMultipoleRadPass'};
18+
'ExactMultipoleRadPass',...
19+
'GWigSymplecticRadPass',...
20+
'EnergyLossRadPass'};
1921

2022
NumElements=length(ring);
2123

@@ -62,7 +64,7 @@
6264

6365
function elem=substitute(elem)
6466
if ~any(strcmp(elem.PassMethod, newmethods))
65-
elem.PassMethod = "BndMPoleSymplectic4RadPass";
67+
elem.PassMethod = 'BndMPoleSymplectic4RadPass';
6668
end
6769
end
6870
end

pyat/at/physics/radiation.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@
3131
"BndMPoleSymplectic4RadPass",
3232
"StrMPoleSymplectic4RadPass",
3333
"ExactMultipoleRadPass",
34-
"GWigSymplectic4RadPass",
34+
"GWigSymplecticRadPass",
35+
"EnergyLossRadPass",
3536
}
3637

3738
_NSTEP = 60 # nb slices in a wiggler period

0 commit comments

Comments
 (0)