Skip to content

sergei-romanenko/agda-Pythagoras

 
 

Repository files navigation

Sqrt 2 is not rational

Written by: Ikegami Daisuke ikegami.da@gmail.com
Revised by: Sergei Romanenko sergei.romanenko@supercompilers.ru

The original proof (in Agda1/Alfa) is due to Thierry Coquand.

This version tries to exploit the the Agda standard library.

Links

Files

  • Cancellative.agda
    The definition of cancellative abelian monoid.

  • Theorem.agda
    The main theorem which is originally proved by Thierry Coquand: any prime cannot be a square of rational in cancellative abelian monoid.


  • 2Divides
    Some properties of natural numbers (with zero).

  • NatPlus.agda
    A set of natural numbers without zero.


  • Corollary.agda
    The set of the natural numbers without zero and multiplication forms a cancellative abelian monoid.
    Thus, the square root of two is irrational.

Miscellanea



About

Pythagorean theorem (sqrt 2 is not rational). Rewritten in Agda2 from the original proof by Thierry Coquand.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Agda 81.2%
  • Coq 18.8%