Skip to content

Commit f6cf7dc

Browse files
fscarlierawegsche
andauthored
Fix for larger errorst in first/last bpms (thx Andreas) (#430)
* Fix for larger errorst in first/last bpms (thx Andreas) * version bump and changelog update --------- Co-authored-by: awegsche <[email protected]>
1 parent 2ae8acb commit f6cf7dc

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# OMC3 Changelog
22

3+
#### 2023-09-20 - v0.11.3 - _fscarlier_, _awegsche_
4+
- Fixed:
5+
- bug in beta from phase (3BPM method) that calculated too high errors for first and last BPMs
6+
37
#### 2023-09-20 - v0.11.3 - _jdilly_, _awegsche_
48

59
- Fixed:

omc3/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
__title__ = "omc3"
1212
__description__ = "An accelerator physics tools package for the OMC team at CERN."
1313
__url__ = "https://github.com/pylhc/omc3"
14-
__version__ = "0.11.3"
14+
__version__ = "0.11.4"
1515
__author__ = "pylhc"
1616
__author_email__ = "[email protected]"
1717
__license__ = "MIT"

omc3/optics_measurements/beta_from_phase.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ def n_bpm_method(meas_input, phase, plane, meas_and_mdl_tunes):
8787
"were requested in N-BPM method. Using all available BPMs instead,"
8888
"the results will still be correct.")
8989
n_bpms = n_bpms_phases
90-
90+
9191
if n_bpms < 3:
9292
raise ValueError("At least 3 BPMs are required for N-BPM method!"
9393
f"Instead a range of {n_bpms} was requested.")
@@ -422,7 +422,7 @@ def three_bpm_method(meas_input, phase, plane, meas_and_mdl_tunes):
422422
# tilt phase advances in order to have the phase advances in a neighbourhood
423423
tilted_meas = _tilt_slice_matrix(phase["MEAS"].to_numpy(), 2, 5, tune) * PI2
424424
tilted_model = _tilt_slice_matrix(phase["MODEL"].to_numpy(), 2, 5, mdltune) * PI2
425-
tilted_errmeas = _tilt_slice_matrix(phase["ERRMEAS"].to_numpy(), 2, 5, mdltune) * PI2
425+
tilted_errmeas = _tilt_slice_matrix(phase["ERRMEAS"].to_numpy(), 2, 5, 0) * PI2
426426
betmdl = beta_df.loc[:, f"BET{plane}{MDL}"].to_numpy()
427427
alfmdl = beta_df.loc[:, f"ALF{plane}{MDL}"].to_numpy()
428428
with np.errstate(divide='ignore'):

0 commit comments

Comments
 (0)