induction ls; intuition; simpl in *.
inversion H0. inversion H1. subst.
rewrite H2.
rewrite H3.
eapply leRat_trans.
eapply eqRat_impl_leRat.
eapply (ratIdentityIndiscernables 0).
intuition.
eapply rat0_le_all.
inversion H0; clear H0; subst.
inversion H1; clear H1; subst.
rewrite ratS_num.
eapply leRat_trans.
2:{
eapply eqRat_impl_leRat.
eapply eqRat_symm.
eapply ratMult_distrib.
}
rewrite H7.
rewrite H9.
rewrite rat_distance_of_sum.
eapply ratAdd_leRat_compat.
rewrite <- ratMult_1_r.
eapply ratMult_leRat_compat.
eapply H; eauto.
intuition.
eapply IHls; eauto.
Qed.

(* Specifications: *)
Lemma sumList_rel_all_0_inv : forall (A : Set)(ls : list A)(r  : Rat)(rel : A -> Rat -> Prop),
sumList_rel rel ls r ->
(forall a' v, In a' ls -> rel a' v -> v == 0) ->
r == 0.