add common code to 11

This commit is contained in:
Valentin Boettcher 2022-07-25 11:43:49 +02:00
parent 361b15d43d
commit 9824ea029d

View file

@ -0,0 +1,23 @@
from plot_utils import *
@wrap_plot
def compare_models_with_analytic(ax=None):
for params, flow, ex_flow, keys in zip(
multi_params, flow_hops, exact_flows, model_keys
):
consistency = (-1 * flow).consistency(ex_flow)
pu.plot_with_σ(
params.IntP.t,
-1 * flow,
bath=0,
ax=ax,
label=rf"$α(0)={params.SysP.g[0].sum().real:.2f}$ $ω_c={keys['wc']}$ ${consistency}\%$",
)
ax.plot(params.IntP.t, ex_flow, linestyle="dotted", color="black")
ax.set_xlabel("$τ$")
ax.set_ylabel("$-J$")
# ax.plot(multi_params[-1].IntP.t, flow_τ, label="Analytic", linestyle="dotted", color="black")
ax.legend()