Skip to content

Commit

Permalink
remove these calls
Browse files Browse the repository at this point in the history
  • Loading branch information
fsoubelet committed Aug 13, 2024
1 parent 7819df1 commit 8bac042
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions omc3/kmod/analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,17 +146,11 @@ def fit_prec(x, beta_av):
return dQ


np.vectorize(fit_prec) # does nothing if we don't store result!


def fit_approx(x, beta_av):
dQ = beta_av*x[0]/(4*np.pi)
return dQ


np.vectorize(fit_approx) # does nothing if we don't store result!


def average_beta_from_Tune(Q, TdQ, length, Dk):
"""Calculates average beta function in quadrupole from tune change ``TdQ`` and ``delta K``."""

Expand All @@ -177,9 +171,6 @@ def average_beta_focussing_quadrupole(b, w, L, K, Lstar):
return average_beta


np.vectorize(average_beta_focussing_quadrupole)


def average_beta_defocussing_quadrupole(b, w, L, K, Lstar):
beta0 = b + ((Lstar - w) ** 2 / b)
alpha0 = -(Lstar - w) / b
Expand All @@ -191,9 +182,6 @@ def average_beta_defocussing_quadrupole(b, w, L, K, Lstar):
return average_beta


np.vectorize(average_beta_defocussing_quadrupole)


def calc_tune(magnet_df):
for plane in PLANES:
magnet_df.headers[f"{TUNE}{plane}"] = np.average(magnet_df.where(
Expand Down

0 comments on commit 8bac042

Please sign in to comment.