RSSAmplifier

Blog

Kim Morrison

Notes on Lean, tactics, and making the theorem prover do more work.

kim-em.github.ioRSS feed ↗5 posts

Latest posts

Certified integer polynomial factorization in Lean

I'm happy to announce the release of further packages for Hex, the computer algebra library for Lean. Today we have an integer polynomial factorization library, including tactics for factorizing and irreducibility. To get started, add to your lakefile.toml: [[require]] name = "hex" git = "https://github.com/leanprover/hex.git" rev = "main" and then:

Why Lean is faster than Rust

I can't possibly be serious, can I, claiming that Lean is faster than Rust? Let me show you something: # silesia.tar: the 212 MB standard corpus. Each tool compresses at level 6 # and prints the resulting size in bytes; `time` reports wall-clock. $ time deflate-rust silesia.tar # miniz_oxide (pure Rust, no 'unsafe') 68112144 real 0m5.77s $ time deflate-lean silesia.tar # lean-zip 68054183 real…

Lattice basis reduction using the Hex Lean library

We're starting work on a computational algebra library for Lean, called Hex. We've just released the first collection of packages, providing dense matrices, row reduction, Gram-Schmidt, and lattice basis reduction. These packages have a primarily computational focus (i.e. calculations on concrete inputs, rather than symbolic algebra), and are optimized first for runtime performance, and…

Verified linear programming

I've released leanprover/lp: verified linear programming in Lean 4. It's two things at once — a proof-carrying solver you can call from your own algorithms, and a tactic frontend that behaves a bit like linarith but reaches some goals linarith can't. The examples below are all elaborated by Lean when this page is built, using the actual tactic. Nothing here is a screenshot.

A sum of squares tactic

I've put together an sos tactic: a sum-of-squares decision procedure for nonlinear real arithmetic, closely following John Harrison's implementation in HOL Light. It closes a range of polynomial-inequality goals over the reals that we don't otherwise have good tactics for. Every example below is elaborated by Lean when this page is built — the tactic really runs, CSDP and all.