forked from agda/agda-stdlib
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBinomial.agda
More file actions
24 lines (17 loc) · 839 Bytes
/
Copy pathBinomial.agda
File metadata and controls
24 lines (17 loc) · 839 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
------------------------------------------------------------------------
-- The Agda standard library
--
-- The Binomial Theorem for Commutative Semirings
------------------------------------------------------------------------
{-# OPTIONS --cubical-compatible --safe #-}
open import Algebra.Bundles
using (CommutativeSemiring)
module Algebra.Properties.CommutativeSemiring.Binomial {a ℓ} (S : CommutativeSemiring a ℓ) where
open CommutativeSemiring S
open import Algebra.Properties.Semiring.Exp semiring using (_^_)
import Algebra.Properties.Semiring.Binomial semiring as Binomial
open Binomial public hiding (theorem)
------------------------------------------------------------------------
-- Here it is
theorem : ∀ n x y → ((x + y) ^ n) ≈ Binomial.expansion x y n
theorem n x y = Binomial.theorem x y (*-comm x y) n