def METHOD_NAME(par, wc, meson):
    r"""Mixing amplitude $M_{12}$ of meson $K^0$, $B^0$, or $B_s$.
    Defined as
    $$M_{12}^M = \frac{\langle M | \mathcal H_{\mathrm{eff}}|\bar M\rangle}{2M_M}$$
    (Attention: $M_{12}$ is sometimes defined with the meson and anti-meson
    switched in the above definition, leading to a complex conjugation.)
    """
    me = matrixelements(par, meson)
    # new physics contributions to the mixing amplitude
    # the minus sign below stems from the fact that H_eff = -C_i O_i
    di_dj = meson_quark[meson]
    contribution_np = 0
    for me_name, me_value in me.items():
        wc_name = '{}_{}'.format(me_name, 2 * di_dj)
        contribution_np += -wc.get(wc_name, 0) * me_value
    # SM contribution
    if meson == 'D0':
        contribution_sm = M12_u_SM(par)
    else: # for B0, Bs, K0
        contribution_sm = M12_d_SM(par, meson)
    # new physics + SM
    return contribution_np + contribution_sm