From 77077c2560a12b115178d3ee8351d95978e98a38 Mon Sep 17 00:00:00 2001 From: Valentin Boettcher Date: Fri, 23 Aug 2024 12:17:50 -0400 Subject: [PATCH] include theoretical mode frequencies --- src/rabifun/plots.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/rabifun/plots.py b/src/rabifun/plots.py index 29f9ca4..d6639c9 100644 --- a/src/rabifun/plots.py +++ b/src/rabifun/plots.py @@ -279,7 +279,12 @@ def annotate_ringodown_mode_positions(params: Params, ax): ax_ticks = ax.twiny() ax_ticks.sharey(ax) ax_ticks.set_xticks(runtime.ringdown_frequencies) - ax_ticks.set_xticklabels([mode_name(i, params.N) for i in range(2 * params.N + 2)]) + ax_ticks.set_xticklabels( + [ + f"{mode_name(i, params.N)} = {freq:.2f}" + for i, freq in enumerate(runtime.ringdown_frequencies) + ] + ) ax_ticks.set_xlim(ax.get_xlim()) for pos, peak_freq in zip(runtime.ringdown_frequencies, runtime.Ωs):