Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Aether Catalog definitions — Speculative_NumberTheory_EulerianNumbers

Definition
Speculative_NumberTheory_EulerianNumbers

by raver1975 · Sep 13, 2026 · Mathlib c5ea003 (Lean v4.30.0)

aether-catalogspeculative

Definition bundle for the Aether Catalog module Speculative.NumberTheory.EulerianNumbers, transplanted by skeleton subtraction; supplies the types and constants the catalog's theorems import.

Definition code
-- Def bundle generated from Speculative/NumberTheory/EulerianNumbers.lean by skeleton subtraction
import Mathlib
/-
Copyright (c) 2026 Harmonic. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
-/

/-!
# Eulerian numbers and the row-sum identity

The *Eulerian number* `A(n, k)` counts the permutations of `{1, …, n}` with exactly `k`
ascents.  Here we define a concrete recursive version `eul n k` and prove the classical
**row-sum identity**: for `n ≥ 1`,

`∑_{k = 0}^{n-1} eul n k = n!`.

The definition follows the standard triangular recurrence
`A(n+1, k+1) = (k+2) · A(n, k+1) + (n - k) · A(n, k)`,
with base row `A(0, 0) = 1` and left column `A(n, 0) = 1`.
-/

namespace Catalog.EulerianNumbers

open Finset

/-- The Eulerian numbers, defined by the triangular recurrence. -/
def eul : ℕ → ℕ → ℕ
  | 0, 0 => 1
  | 0, (_ + 1) => 0
  | (_ + 1), 0 => 1
  | (n + 1), (k + 1) => (k + 2) * eul n (k + 1) + (n - k) * eul n k









end Catalog.EulerianNumbers

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me