Definition t_lookup (m : total_map) x := 
  let (m, d) := m in
  match lookup m x with
  | Some v => v
  | None => d
  end.

Theorem t_update_neq : forall v x1 x2 (m : total_map), x1 <> x2 -> t_lookup (t_update m x1 v) x2 = t_lookup m x2.