File: Mathlib/LinearAlgebra/Matrix/Circulant.lean

full_name: Matrix.circulant
code: /-- Given the condition `[Sub n]` and a vector `v : n → α`,
    we define `circulant v` to be the circulant matrix generated by `v` of type `Matrix n n α`.
    The `(i,j)`th entry is defined to be `v (i - j)`. -/
def circulant [Sub n] (v : n → α) : Matrix n n α 
goal: Matrix n n α

full_name: Matrix.circulant_apply
code: @[simp]
theorem circulant_apply [Sub n] (v : n → α) (i j) : circulant v i j = v (i - j) 
goal: Matrix.circulant v i j = v (i - j)

full_name: Matrix.circulant_col_zero_eq
code: theorem circulant_col_zero_eq [AddGroup n] (v : n → α) (i : n) : circulant v i 0 = v i 
goal: Matrix.circulant v i 0 = v i

full_name: Matrix.circulant_injective
code: theorem circulant_injective [AddGroup n] : Injective (circulant : (n → α) → Matrix n n α) 
goal: Function.Injective Matrix.circulant

full_name: Matrix.Fin.circulant_injective
code: theorem Fin.circulant_injective : ∀ n, Injective fun v : Fin n → α => circulant v
  
goal: Function.Injective fun v => Matrix.circulant v

full_name: Matrix.circulant_inj
code: @[simp]
theorem circulant_inj [AddGroup n] {v w : n → α} : circulant v = circulant w ↔ v = w 
goal: Matrix.circulant v = Matrix.circulant w ↔ v = w

full_name: Matrix.Fin.circulant_inj
code: @[simp]
theorem Fin.circulant_inj {n} {v w : Fin n → α} : circulant v = circulant w ↔ v = w 
goal: Matrix.circulant v = Matrix.circulant w ↔ v = w

full_name: Matrix.transpose_circulant
code: theorem transpose_circulant [AddGroup n] (v : n → α) :
    (circulant v)ᵀ = circulant fun i => v (-i) 
goal: (Matrix.circulant v).transpose = Matrix.circulant fun i => v (-i)

full_name: Matrix.conjTranspose_circulant
code: theorem conjTranspose_circulant [Star α] [AddGroup n] (v : n → α) :
    (circulant v)ᴴ = circulant (star fun i => v (-i)) 
goal: (Matrix.circulant v).conjTranspose = Matrix.circulant (star fun i => v (-i))

full_name: Matrix.Fin.transpose_circulant
code: theorem Fin.transpose_circulant : ∀ {n} (v : Fin n → α), (circulant v)ᵀ = circulant fun i => v (-i)
  
goal: (Matrix.circulant v).transpose = Matrix.circulant fun i => v (-i)

full_name: Matrix.Fin.conjTranspose_circulant
code: theorem Fin.conjTranspose_circulant [Star α] :
    ∀ {n} (v : Fin n → α), (circulant v)ᴴ = circulant (star fun i => v (-i))
  
goal: (Matrix.circulant v).conjTranspose = Matrix.circulant (star fun i => v (-i))

full_name: Matrix.map_circulant
code: theorem map_circulant [Sub n] (v : n → α) (f : α → β) :
    (circulant v).map f = circulant fun i => f (v i) 
goal: (Matrix.circulant v).map f = Matrix.circulant fun i => f (v i)

full_name: Matrix.circulant_neg
code: theorem circulant_neg [Neg α] [Sub n] (v : n → α) : circulant (-v) = -circulant v 
goal: Matrix.circulant (-v) = -Matrix.circulant v

full_name: Matrix.circulant_zero
code: @[simp]
theorem circulant_zero (α n) [Zero α] [Sub n] : circulant 0 = (0 : Matrix n n α) 
goal: Matrix.circulant 0 = 0

full_name: Matrix.circulant_add
code: theorem circulant_add [Add α] [Sub n] (v w : n → α) :
    circulant (v + w) = circulant v + circulant w 
goal: Matrix.circulant (v + w) = Matrix.circulant v + Matrix.circulant w

full_name: Matrix.circulant_sub
code: theorem circulant_sub [Sub α] [Sub n] (v w : n → α) :
    circulant (v - w) = circulant v - circulant w 
goal: Matrix.circulant (v - w) = Matrix.circulant v - Matrix.circulant w

full_name: Matrix.circulant_mul
code: /-- The product of two circulant matrices `circulant v` and `circulant w` is
    the circulant matrix generated by `circulant v *ᵥ w`. -/
theorem circulant_mul [Semiring α] [Fintype n] [AddGroup n] (v w : n → α) :
    circulant v * circulant w = circulant (circulant v *ᵥ w) 
goal: Matrix.circulant v * Matrix.circulant w = Matrix.circulant ((Matrix.circulant v).mulVec w)

full_name: Matrix.Fin.circulant_mul
code: theorem Fin.circulant_mul [Semiring α] :
    ∀ {n} (v w : Fin n → α), circulant v * circulant w = circulant (circulant v *ᵥ w)
  
goal: Matrix.circulant v * Matrix.circulant w = Matrix.circulant ((Matrix.circulant v).mulVec w)

full_name: Matrix.circulant_mul_comm
code: /-- Multiplication of circulant matrices commutes when the elements do. -/
theorem circulant_mul_comm [CommSemigroup α] [AddCommMonoid α] [Fintype n] [AddCommGroup n]
    (v w : n → α) : circulant v * circulant w = circulant w * circulant v 
goal: Matrix.circulant v * Matrix.circulant w = Matrix.circulant w * Matrix.circulant v

full_name: Matrix.Fin.circulant_mul_comm
code: theorem Fin.circulant_mul_comm [CommSemigroup α] [AddCommMonoid α] :
    ∀ {n} (v w : Fin n → α), circulant v * circulant w = circulant w * circulant v
  
goal: Matrix.circulant v * Matrix.circulant w = Matrix.circulant w * Matrix.circulant v

full_name: Matrix.circulant_smul
code: /-- `k • circulant v` is another circulant matrix `circulant (k • v)`. -/
theorem circulant_smul [Sub n] [SMul R α] (k : R) (v : n → α) :
    circulant (k • v) = k • circulant v 
goal: Matrix.circulant (k • v) = k • Matrix.circulant v

full_name: Matrix.circulant_single_one
code: @[simp]
theorem circulant_single_one (α n) [Zero α] [One α] [DecidableEq n] [AddGroup n] :
    circulant (Pi.single 0 1 : n → α) = (1 : Matrix n n α) 
goal: Matrix.circulant (Pi.single 0 1) = 1

full_name: Matrix.circulant_single
code: @[simp]
theorem circulant_single (n) [Semiring α] [DecidableEq n] [AddGroup n] [Fintype n] (a : α) :
    circulant (Pi.single 0 a : n → α) = scalar n a 
goal: Matrix.circulant (Pi.single 0 a) = (Matrix.scalar n) a

full_name: Matrix.Fin.circulant_ite
code: /-- Note we use `↑i = 0` instead of `i = 0` as `Fin 0` has no `0`.
This means that we cannot state this with `Pi.single` as we did with `Matrix.circulant_single`. -/
theorem Fin.circulant_ite (α) [Zero α] [One α] :
    ∀ n, circulant (fun i => ite (i.1 = 0) 1 0 : Fin n → α) = 1
  
goal: (Matrix.circulant fun i => if ↑i = 0 then 1 else 0) = 1

full_name: Matrix.circulant_isSymm_iff
code: /-- A circulant of `v` is symmetric iff `v` equals its reverse. -/
theorem circulant_isSymm_iff [AddGroup n] {v : n → α} :
    (circulant v).IsSymm ↔ ∀ i, v (-i) = v i 
goal: (Matrix.circulant v).IsSymm ↔ ∀ (i : n), v (-i) = v i

full_name: Matrix.Fin.circulant_isSymm_iff
code: theorem Fin.circulant_isSymm_iff : ∀ {n} {v : Fin n → α}, (circulant v).IsSymm ↔ ∀ i, v (-i) = v i
  
goal: (Matrix.circulant v).IsSymm ↔ ∀ (i : Fin n), v (-i) = v i

full_name: Matrix.circulant_isSymm_apply
code: /-- If `circulant v` is symmetric, `∀ i j : I, v (- i) = v i`. -/
theorem circulant_isSymm_apply [AddGroup n] {v : n → α} (h : (circulant v).IsSymm) (i : n) :
    v (-i) = v i 
goal: v (-i) = v i

full_name: Matrix.Fin.circulant_isSymm_apply
code: theorem Fin.circulant_isSymm_apply {n} {v : Fin n → α} (h : (circulant v).IsSymm) (i : Fin n) :
    v (-i) = v i 
goal: v (-i) = v i