Section SumExpr.
(* The vector direct sum theory clones the interface types of the matrix     *)
(* direct sum theory (see mxalgebra for the technical details), but          *)
(* nevetheless reuses much of the matrix theory.                             *)
Structure addv_expr := Sumv {
addv_val :> wrapped {vspace vT};
addv_dim : wrapped nat;
_ : mxsum_spec (vs2mx (unwrap addv_val)) (unwrap addv_dim)
}.
(* Piggyback on mxalgebra theory. *)
Definition vs2mx_sum_expr_subproof (S : addv_expr) :
mxsum_spec (vs2mx (unwrap S)) (unwrap (addv_dim S)).

Lemma directv_addP {U V} : reflect (U :&: V = 0)%VS (directv (U + V)).
End BinaryDirect.