add get_decay_chain for custom decay chain
support custom decay chain as
@register_decay_chain("custom_NR")
class MyDecayChain(AmpDecayChain):
def init_params(self, name=""):
self.a = self.add_var(name+"a", is_complex=True)
def get_amp(self, data_c, data_p, **kwargs):
p_map = {str(i): i for i in self.outs}
p1 = data_p[p_map["D"]]["p"]
p2 = data_p[p_map["pi"]]["p"]
p3 = data_p[p_map["D0"]]["p"]
eta = tf.constant([1, -1, -1, -1], dtype=tf.float64)
l_dot = lambda x, y: tf.reduce_sum(x*y*eta, axis=-1)
a = - l_dot(p1, p2) + l_dot(p1, p2+p3)*l_dot(p2+p3, p2)/l_dot(p2+p3, p2+p3)
zeros = tf.zeros_like(a)
return self.a() * tf.complex(a, zeros)
for the amplitude
a \hat{g}_{\mu \nu} p_K^{\mu} p_{pi}^{\nu}