proposition: Lemma lagrange_basis_0 {R: comUnitRingType} (x1 x: R) (s: seq R): x \in s -> (lagrange_basis s x1).[x] = 0.
proof: Proof. rewrite /lagrange_basis. elim: s => [// | a s IHs]. rewrite in_cons big_cons hornerM hornerZ !horner_cons hornerC GRing.mul0r GRing.add0r GRing.mul1r. destruct (x == a) eqn:Heq. - move /eqP in Heq. by rewrite Heq GRing.subrr GRing.mulr0 GRing.mul0r. - move=> H. by rewrite IHs // GRing.mulr0. Qed.
imports: Relational(OrderEnrichedCategory GenericRulesSimple) mathcomp(all_ssreflect all_algebra reals distr realsum ssrnat ssreflect ssrfun ssrbool ssrnum eqtype choice seq) Mon(SPropBase) Crypt(Axioms ChoiceAsOrd SubDistr Couplings UniformDistrLemmas FreeProbProg Theta_dens RulesStateProb pkg_core_definition choice_type pkg_composition pkg_rhl Package Prelude) extructures(ord fset fmap) Equations(Equations)