let rec has_one_MUX cycle tree =
    match cycle with
      x::tail -> if is_MUX x tree then not (has_MUX tail tree) else has_one_MUX tail tree
    | _->false