Section FinContainer.
Variable spec : FinContainerSpec.
Definition finContainer (a:Type) := {x : shape spec & Vector (card x) a}.
Definition finContainer_traverse a b (F : Applicative) (f : a -> F b) (x : finContainer a) : F (finContainer b) :=
let (s, v) := x in map (existT _ s) (traverse f v).

Lemma finContainer_traverse_identity a (x : finContainer a) :
finContainer_traverse (F:=IdApplicative) (fun y => y) x = x.