pith. sign in

arxiv: 1804.06398 · v1 · pith:TQKIJYHJnew · submitted 2018-04-17 · 💻 cs.CR

Modelling Bitcoin in Agda

classification 💻 cs.CR
keywords transactiontransactionsmodelagdamodelsoutputsaccountsbitcoin
0
0 comments X
read the original abstract

We present two models of the block chain of Bitcoin in the interactive theorem prover Agda. The first one is based on a simple model of bank accounts, while having transactions with multiple inputs and outputs. The second model models transactions, which refer directly to unspent transaction outputs, rather than user accounts. The resulting blockchain gives rise to a transaction tree. That model is formalised using an extended form of induction-recursion, one of the unique features of Agda. The set of transaction trees and transactions is defined inductively, while simultaneously recursively defining the list of unspent transaction outputs. Both structures model standard transactions, coinbase transactions, transaction fees, the exact message to be signed by those spending money in a transaction, block rewards, blocks, and the blockchain, and the second structure models as well maturation time for coinbase transactions and Merkle trees. Hashing and cryptographic operations and their correctness are dealt with abstractly by postulating corresponding operations. An indication is given how the correctness of this model could be specified and proven in Agda.

This paper has not been read by Pith yet.

discussion (0)

Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.

Forward citations

Cited by 1 Pith paper

Reviewed papers in the Pith corpus that reference this work. Sorted by Pith novelty score.

  1. IsabeLLM: Automated Theorem Proving Applied to Formally Verifying Consensus

    cs.AI 2026-06 unverdicted novelty 4.0

    Improved IsabeLLM adds RAG, error tracing, and Isabelle compatibility updates and is tested on verifying Bitcoin Proof of Work consensus.