feat: Mergesort Stability

未关闭
#438 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

@Robertboy18 已经在做这个了。

开始于 2026年11月3日。

  • #1 来自 @Digger-Rockwell —— 未关闭
  • #1193 来自 @Robertboy18 —— 未关闭
  • #1245 来自 @Digger-Rockwell —— 未关闭

评估

难度
4/5
预计耗时
3-5 天
新手友好度
35/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
停滞
领域
tooling

调研方向

从 issue #372 中引用的 MergeSort 实现开始,检查其求值结果如何使用 sortModelNat le。将提议的 mergeSort_stable 语句与该实现进行比较,并确定过滤后的等式是否捕获了预期的稳定性。完成的标准是定理在不使用 sorry 的情况下被接受,并且适用于 MergeSort 文件。

由索引模型根据 Issue 内容生成。

描述

I am working on a proof that the MergeSort implementation is stable, using the definition below. I am working off of the MergeSort implementation in #372. Would this be a welcome addition to the MergeSort file?

theorem mergeSort_stable
    (xs : List α) (le : α → α → Bool)
    [Std.Total (fun x y => le x y = true)]
    [IsTrans _ (fun x y => le x y = true)] [DecidableEq α] :
    let ys := (mergeSort xs).eval (sortModelNat le)
    ∀ k : α, ys.filter (fun x => le x k && le k x) = xs.filter (fun x => le x k && le k x) := by
  sorry
主要语言
Lean
星标
847
派生
234
平均合并
2 天 21 小时
30 天内合并 PR
49

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

leanprover/cslib 的其他 Issue

查看 leanprover/cslib 的全部 Issue

相似的 Issue

更多 DevTools Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。