{"id":13992804,"url":"https://github.com/fpvandoorn/carleson","last_synced_at":"2026-02-19T00:04:10.286Z","repository":{"id":203095771,"uuid":"707728768","full_name":"fpvandoorn/carleson","owner":"fpvandoorn","description":"A formalized proof of Carleson's theorem in Lean","archived":false,"fork":false,"pushed_at":"2026-02-02T14:31:16.000Z","size":5594,"stargazers_count":83,"open_issues_count":2,"forks_count":37,"subscribers_count":4,"default_branch":"master","last_synced_at":"2026-02-03T03:27:41.517Z","etag":null,"topics":["lean4"],"latest_commit_sha":null,"homepage":"http://florisvandoorn.com/carleson/","language":"Lean","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fpvandoorn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-10-20T14:24:32.000Z","updated_at":"2026-02-02T14:31:44.000Z","dependencies_parsed_at":null,"dependency_job_id":"121e11c6-f91a-46dd-bad7-6e4cdad49183","html_url":"https://github.com/fpvandoorn/carleson","commit_stats":null,"previous_names":["fpvandoorn/carleson"],"tags_count":31,"template":false,"template_full_name":null,"purl":"pkg:github/fpvandoorn/carleson","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fpvandoorn%2Fcarleson","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fpvandoorn%2Fcarleson/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fpvandoorn%2Fcarleson/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fpvandoorn%2Fcarleson/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fpvandoorn","download_url":"https://codeload.github.com/fpvandoorn/carleson/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fpvandoorn%2Fcarleson/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29599338,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T22:25:43.180Z","status":"ssl_error","status_checked_at":"2026-02-18T22:25:42.766Z","response_time":162,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["lean4"],"created_at":"2024-08-09T14:02:08.525Z","updated_at":"2026-02-19T00:04:10.274Z","avatar_url":"https://github.com/fpvandoorn.png","language":"Lean","funding_links":[],"categories":["Lean"],"sub_categories":[],"readme":"# Formalization of a generalized Carleson's theorem\nA formalized proof of a generalized Carleson's theorem in the [Lean interactive theorem prover](https://lean-lang.org/).\n\n## Links\n\n* [Zulip channel](https://leanprover.zulipchat.com/#narrow/stream/442935-Carleson) for coordination\n* [Webpage](https://florisvandoorn.com/carleson/)\n* [Blueprint](https://florisvandoorn.com/carleson/blueprint/)\n* [Blueprint as pdf](https://florisvandoorn.com/carleson/blueprint.pdf)\n* [Dependency graph](https://florisvandoorn.com/carleson/blueprint/dep_graph_document.html)\n* [Documentation pages for this repository](https://florisvandoorn.com/carleson/docs/)\n\n\n## What is Carleson's theorem?\n\nCarleson's theorem is a statement about Fourier analysis: given a continuous periodic function $f\\colon ℝ\\to ℝ$, its Fourier converges to $f$ point-wise at almost every point.\nMore precisely, let $f\\colon\\mathbb{R}\\to \\mathbb{C}$ be a $2\\pi$-periodic bounded Borel measurable function.\nFor each integer $n\\in\\mathbb{Z}$, define the $n$-th Fourier coefficient as\n```math\n\\widehat{f}_n := \\frac{1}{2\\pi} \\int_0^{2\\pi} f(x) e^{- i nx} dx.\n```\nFor $N\\geq 0$, define the partial Fourier sum as\n```math\ns_Nf(x):=\\sum_{n=-N}^N \\widehat{f}_n e^{i nx}.\n```\nThen Carleson's theorem states $\\lim_{N\\to\\infty} s_N f(x) = f(x)$ for almost all $x\\in\\mathbb{R}$.\n\nDespite being simple to state, its proof is very hard. (It is also quite subtle: for instance, asking for point-wise convergence *everywhere* makes this false.)\nThe precise English statement statement can be found [as Theorem 1.0.1](https://florisvandoorn.com/carleson/blueprint/sect0001.html#classical-carleson),\nthe corresponding Lean statement is [here](https://florisvandoorn.com/carleson/docs/find/?pattern=ClassicalCarleson#doc),\nand the Lean proof [here](https://florisvandoorn.com/carleson/docs/find/?pattern=classical_carleson#doc).\n\n### Metric space Carleson theorem\n\nIn this project, we deduce this statement from the boundedness of a certain linear operator, the so-called *Carleson operator*.\nThis boundedness holds in much greater generality: we formalise a new generalisation (due to the harmonic analysis group in Bonn) to [doubling metric measure spaces](Carleson/Defs.lean#L40).\nThe precise technical result we prove is the **metric spaces Carleson theorem** ([Theorem 1.1.1](https://florisvandoorn.com/carleson/blueprint/sect0001.html#metric-space-Carleson), [Lean statement](https://florisvandoorn.com/carleson/docs/find/?pattern=MetricSpaceCarleson#doc), [Lean proof](https://florisvandoorn.com/carleson/docs/find/?pattern=metric_carleson#doc)).\n\nWe also prove a **linearised metric space Carleson theorem** ([Theorem 1.1.2](https://florisvandoorn.com/carleson/blueprint/sect0001.html#linearised-metric-Carleson), [Lean statement](https://florisvandoorn.com/carleson/docs/find/?pattern=LinearizedMetricCarleson#doc), [Lean proof](https://florisvandoorn.com/carleson/docs/find/?pattern=linearized_metric_carleson#doc)),\nwhich allows proving a generalisation of Carleson's theorem to [Walsh functions](https://en.wikipedia.org/wiki/Walsh_function).\n\nThe new definitions needed to verify the *statements* of these theorems are in the file [`Carleson.Defs`](Carleson/Defs.lean)\n\n## Verifying the formalisation\n\nThis proof has been formalised in the Lean theorem prover.\nTo confirm the correctness and completeness yourself, follow these steps.\n1. Make sure you have [installed Lean](https://leanprover-community.github.io/get_started.html).\n2. Download the repository using `git clone https://github.com/fpvandoorn/carleson.git`.\n3. Open the directory where you downloaded the repository (but not any further sub-directory). Open a terminal in this directory and run `lake exe cache get!` to download built dependencies.\n4. Determine which Lean statement you want to verify: the Lean statements of the main theorems above are `classical_carleson`, `metric_carleson` and `linearized_metric_carleson`, respectively.\nOpen the file `Carleson.lean` in a text editor of your choice. Add the end of the file, add a line `#print axioms linearized_metric_carleson` (or similar). This will tell Lean to verify that the proof of this result was completed correctly.\n5. In the terminal from step 3, run `lake build` to build all files in this repository. This will likely take 5-30 minutes.\nWhen the process is complete, at the very end of the output, you will see a line `'linearized_metric_carleson' depends on axioms: [propext, Classical.choice, Quot.sound]` (followed by `Build completed successfully`).\nThis shows the proof is complete and correct. Had the build failed or the output included `sorryAx`, this would have indicated an error resp. an incomplete proof.\n(For the experts: this shows which axioms Lean used in the course of the proof. These three axioms are built into Lean's type theory.)\n\n## Contribute\n\n### Locally\n\n1. Make sure you have [installed Lean](https://leanprover-community.github.io/get_started.html).\n2. Download the repository using `git clone https://github.com/fpvandoorn/carleson.git`.\n3. Run `lake exe cache get!` to download built dependencies (this speeds up the build process).\n4. Run `lake build` to build all files in this repository.\n\nSee the README of [Floris van Doorn's course repository](https://github.com/fpvandoorn/LeanCourse24) for more detailed instructions.\n\n### In github codespaces\n\nIf you prefer, you can use online development environment:\n\n\u003ca href=\"https://codespaces.new/fpvandoorn/carleson\"\u003e\u003cimg src=\"https://github.com/codespaces/badge.svg\"/\u003e\u003c/a\u003e\n\nTo make changes to this repository, please make a pull request. There are more tips in the file [Contributing.md](https://github.com/fpvandoorn/carleson/blob/master/CONTRIBUTING.md). To push your changes, the easiest method is to use the `Source Control` panel in VSCode.\nFeel free to make pull requests with code that is work in progress, but make sure that the file(s)\nyou've worked have no errors (having `sorry`'s is fine of course).\n\n## Build the blueprint\n\nTo test the Blueprint locally, you can compile `print.tex` using XeLaTeX (i.e. `xelatex print.tex` in the folder `blueprint/src`). If you have the Python package `invoke` you can also run `inv bp` which puts the output in `blueprint/print/print.pdf`.\nIf you want to build the web version of the blueprint locally, you need to install some packages by following the instructions [here](https://pypi.org/project/leanblueprint/). But if the pdf builds locally, you can also just make a pull request and use the online blueprint.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffpvandoorn%2Fcarleson","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffpvandoorn%2Fcarleson","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffpvandoorn%2Fcarleson/lists"}