SaverioMonaco / Agda-quantities

Type-safe physical computations in Agda.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Agda-quantities

Type-safe physical computations in Agda.


Physical Quantity as Agda type:

scheme


Tutorial:

Check out the two .agda files in /src/Quantities/Manuals/ on how to use this library:

  • Units.agda : with examples on how to use the Units type.
  • Physical.agda : with examples on how to use the Physical Quantities (PQ) type.

How to run it:

This library depends on the Agda-stdlib, in particular it was tested with agda-stdlib-1.7.1.

  1. Clone the repository to a directory $REPODIR
git clone https://github.com/SaverioMonaco/Agda-quantities.git $REPODIR
  1. Locate your $AGDA_DIR, which for unix systems defaults to ~/.agda

  2. Append to $AGDA_DIR/libraries the following content:

$REPODIR/Agda-quantities/Quantities.agda-lib
  1. Append to $AGDA_DIR/defaults the following content:
Quantities
  1. If everything has been linked correctly, you should be able to use the Quantities library anywhere, to test it load the following line in a .agda file:
open import Quantities.Quantities

For more information: package-system


Resources:

About

Type-safe physical computations in Agda.

License:MIT License


Languages

Language:Agda 100.0%