Proof using.
move => h m.
elim => //=.
move => n ns IH.
case (adjacent_to_dec _ _) => H_dec /=.
case => n' m' H_in.
case: H_in => H_in.
by inversion H_in.
exact: IH.
exact: IH.
Qed.

Lemma tot_map_in_in :
forall n m l,
(forall nm, In nm l -> snd nm = m) ->
~ In (n, m) l ->
~ In (tot_map_name n, tot_map_msg m) (map (fun nm : name * msg => (tot_map_name (fst nm), tot_map_msg (snd nm))) l).