frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

Open in hackernews

How to (actually) prove it – New Frontiers of Mathematics and Computing in Lean

https://kirancodes.me/posts/log-how-to-prove-it-maths.html
72•gopiandcode•3d ago

Comments

gnulinux•18h ago
I personally prefer Agda to Lean or Coq [1] to prove my theorems but this frontier is imho among the most exciting research in theoretical CS in many many decades. I really wish more programmers and mathematicians knew about automated theorem proving and automated reasoning. It's nothing short of revolutionary and I think next generation of pure mathematicians will use these as a crucial tool in their research.

[1] It's a personal preference but Agda is simply a much better language with almost limitless metaprogramming which allows me to write proofs close to as they'd appear in prose math papers. It has a smaller ecosystem though. I've never seen a proof in any other language I personally didn't think would be much more readable/simpler in Agda.

IngoBlechschmid•17h ago
I'm currently creating an interactive tutorial on Agda, with lots of embedded exercises (running purely in the browser/on a server, no installation required), perhaps it is useful to some:

https://lets-play-agda.quasicoherent.io/

gopiandcode•11h ago
Oh, really? I'm curious what exactly you mean by limitless metaprogramming. I've really been drawn into Lean specifically because of how easy to extend and malleable the language itself is, so if Agda is even more so then I'd be really eager to try that out.

e.g.:

- embedding a prolog/asp DSL: https://github.com/kiranandcode/cleango

- embedding a tex/latex DSL: https://github.com/kiranandcode/LeanTeX

yuppiemephisto•10h ago
I was surprised to hear their claim about Agda's metaprogramming, I say lean is better here
m_j_g•9h ago
Did you played with cubical flavor of Agda? here is fun project of mine related to it : https://github.com/marcinjangrzybowski/cubeViz2 :)
sega_sai•17h ago
Interesting. I always wanted to try Lean, and personally never found an easy way to do it, as it requires installing a plugin in vscode, create a project or reading the lean book. But following the links I've found this nice interactive tutorial for proving 2+2=4 in Peano arithmetic:

https://adam.math.hhu.de/#/g/leanprover-community/nng4/

It's quite instructive.

thechao•16h ago
Ironically, the website broke, and became stuck on the "rw[one_is_succ_zero]" rewrite rule, continually telling me that "rfl" isn't valid. Sigh.
gfaster•15h ago
Lean is more complex to develop in than most programming languages since it relies heavily on interactive programming, i.e. the context pane. The "easy way" is with a plugin.

If you're interested in learning more about Lean for writing proofs, I would recommend The Mechanics of Proof [0]. It strips out a lot of the convenience tactics in Mathlib to focus on the more primitive mechanisms Mathlib builds on.

[0]: https://hrmacbeth.github.io/math2001/index.html

sega_sai•9h ago
I've seen the book, but I've personally found it not very useful for a person who wants to first get the basics.

The natural number's game is actually quite fun, and I did understand much better the language. And it's also interactive, so you can try your solutions, and there are hints when stuck.

gopiandcode•10h ago
Fwiw there's also an Emacs plugin which is what I use and it works really well.

For using Lean as a theorem prover, this book is pretty good: https://github.com/lean-forward/logical_verification_2024

Also, Lean is also remarkably usable as a programming language itself, which might give an easier onboarding ramp: https://lean-lang.org/functional_programming_in_lean/

rtpg•11h ago
A thing that still stands out to me is that even in this work we're looking at Lean as a way of verifying a proof, but I do not know how much exploratory work is possible in Lean.

In Rocq/Coq, I've found myself often lost in the weeds when exploring a problem just through tactics mode (half expecting it to handle the more boring machinery), and really do have to think pretty hard about how I get from A to B.

Some of this is, quite simply, me just walking in the wrong direction (if you have multiple things you can induct on, the choice can greatly affect how easy it is to move forward!). I just wish that the computer would be a bit better at helping me realize I'm in the wrong direction.

Stuff like Quickchick[0] helps, but just generally I would love the computer to more actively give me counterexamples to some extent.

[0]: https://github.com/QuickChick/QuickChick

gopiandcode•10h ago
Ahh, that is a valid point; so it's not quite as clear as using something like quick check, but it does feel like there is increasing interest and activity in people trying out doing exploratory maths in Lean itself.

I mention it in the blog post, but one project in that direction is Terence Tao's equational_theories project (https://teorth.github.io/equational_theories/), where it seems like a bunch of hobbyists and mathematicians are working together using Lean to prove new mathematics enabled by Lean.

Tainnor•3h ago
I have a pet (undergraduate complex analysis) formalisation project in Lean, purely for didactic and recreational purposes. I find it rewarding in the same way others may find it rewarding to train for a triathlon - it's often extremely grueling work and it can take forever to make even modest progress. When I actually do get to a "big" result such as defining pi (from scratch) or Cauchy's integral theorem it feels rewarding, but there's a ton of torn out hairs along the way, when linarith is stupider than it should be, I need to spend forever to prove very obvious things, I can't find the tactic I need in mathlib or I realise there's barely anything about triangles in there. For somebody like me without a PhD it also doesn't help that mathlib almost always goes for full generality which makes it hard to use it effectively (although I do understand the reason for it).

I think this is all very exciting but I also think ergonomics will probably need to improve quite a bit before Lean will become mainstream in mathematics.

A community-led fork of Organic Maps

https://www.comaps.app/news/2025-05-12/3/
67•maelito•1h ago•30 comments

University of Texas-Led Team Solves a Big Problem for Fusion Energy

https://news.utexas.edu/2025/05/05/university-of-texas-led-team-solves-a-big-problem-for-fusion-energy/
20•signa11•50m ago•2 comments

Spade Hardware Description Language

https://spade-lang.org/
15•spmcl•51m ago•2 comments

I ruined my vacation by reverse engineering WSC

https://blog.es3n1n.eu/posts/how-i-ruined-my-vacation/
248•todsacerdoti•9h ago•120 comments

Plain Vanilla Web

https://plainvanillaweb.com/index.html
1186•andrewrn•20h ago•556 comments

When Compiler Engineers Act as Judges, What Can Possibly Go Wrong?

https://seylaw.blogspot.com/2025/05/when-compiler-engineers-act-as-judges.html
6•meinersbur•1h ago•2 comments

Continuous Thought Machines

https://pub.sakana.ai/ctm/
221•hardmaru•10h ago•20 comments

Spark AI (YC W24) Is Hiring a Full Stack Engineer in San Francisco

https://www.ycombinator.com/companies/spark/jobs/kDeJlPK-software-engineer-full-stack
1•tk90•1h ago

Armbian Updates: OMV support, boot improvents, Rockchip optimizations

https://www.armbian.com/newsflash/armbian-updates-nas-support-lands-boot-systems-improve-and-rockchip-optimizations-arrive/
37•transpute•5h ago•1 comments

Intellect-2 Release: The First 32B Model Trained Through Globally Distributed RL

https://www.primeintellect.ai/blog/intellect-2-release
157•Philpax•11h ago•43 comments

US Copyright Office found AI companies breach copyright. Its boss was fired

https://www.theregister.com/2025/05/12/us_copyright_office_ai_copyright/
105•croes•3h ago•20 comments

Making PyPI's test suite 81% faster – The Trail of Bits Blog

https://blog.trailofbits.com/2025/05/01/making-pypis-test-suite-81-faster/
81•rbanffy•3d ago•23 comments

Implicit UVs: Real-time semi-global parameterization of implicit surfaces [pdf]

https://baptiste-genest.github.io/papers/implicit_uvs.pdf
8•ibobev•2h ago•0 comments

The Academic Pipeline Stall: Why Industry Must Stand for Academia

https://www.sigarch.org/the-academic-pipeline-stall-why-industry-must-stand-for-academia/
123•MaysonL•10h ago•87 comments

CrowdStrike CEO Cuts His Voting Power by 92% with Unexplained Gifts

https://www.bloomberg.com/news/articles/2025-05-12/billionaire-crowdstrike-ceo-cuts-voting-power-by-92-with-unexplained-gifts
21•wslh•41m ago•7 comments

Car companies are in a billion-dollar software war

https://insideevs.com/features/759153/car-companies-software-companies/
381•rntn•19h ago•656 comments

Why Bell Labs Worked

https://1517.substack.com/p/why-bell-labs-worked
247•areoform•16h ago•172 comments

A Typical Workday at a Japanese Hardware Tool Store [video]

https://www.youtube.com/watch?v=A98jyfB5mws
5•Erikun•2d ago•0 comments

Absolute Zero Reasoner

https://andrewzh112.github.io/absolute-zero-reasoner/
96•jonbaer•4d ago•17 comments

High-school shop students attract skilled-trades job offers

https://www.wsj.com/lifestyle/careers/skilled-trades-high-school-recruitment-fd9f8257
211•lxm•21h ago•358 comments

Scraperr – A Self Hosted Webscraper

https://github.com/jaypyles/Scraperr
208•jpyles•18h ago•72 comments

Writing an LLM from scratch, part 13 – attention heads are dumb

https://www.gilesthomas.com/2025/05/llm-from-scratch-13-taking-stock-part-1-attention-heads-are-dumb
304•gpjt•3d ago•60 comments

Ask HN: Cursor or Windsurf?

184•skarat•8h ago•256 comments

Title of work deciphered in sealed Herculaneum scroll via digital unwrapping

https://www.finebooksmagazine.com/fine-books-news/title-work-deciphered-sealed-herculaneum-scroll-digital-unwrapping
220•namanyayg•23h ago•105 comments

For better or for worse, the overload (2024)

https://consteval.ca/2024/07/25/overload/
12•HeliumHydride•3d ago•0 comments

How friction is being redistributed in today's economy

https://kyla.substack.com/p/the-most-valuable-commodity-in-the
225•walterbell•3d ago•107 comments

ToyDB rewritten: a distributed SQL database in Rust, for education

https://github.com/erikgrinaker/toydb
106•erikgrinaker•17h ago•13 comments

LSP client in Clojure in 200 lines of code

https://vlaaad.github.io/lsp-client-in-200-lines-of-code
150•vlaaad•19h ago•22 comments

Show HN: Vom Decision Platform (Cursor for Decision Analyst)

https://www.vomdecision.com
11•davidreisbr•3d ago•8 comments

Show HN: Codigo – The Programming Language Repository

https://codigolangs.com
51•adamjhf•2d ago•16 comments