logo
Formal Ledger Specification
Properties
Initializing search
    GitHub
    • Navigation
    GitHub
      • Home
      • Guide for Contributors
        • Notation
      • Ledger
        • Prelude
        • Introduction
          • Base
            • HSTypes
            • Util
          • HasCoin
          • Instances
          • Numeric
            • PositiveNat
            • UnitInterval
            • Address
            • Crypto
            • Epoch
        • Conway
          • Specification
            • Abstract
            • Certs
              • Properties
                • PoV
                • PoVLemmas
                • VoteDelegsVDeleg
            • Chain
              • Properties
                • CredDepsEqualDomRwds
                • EpochStep
                • GovDepsMatch
                • PParamsWellFormed
            • Enact
              • Properties
            • Epoch
              • Properties
                • ConstRwds
                • GovDepsMatch
                • NoPropSameDReps
            • Fees
            • Gov
              • Base
              • Actions
              • Properties
                • ChangePPGroup
            • Ledger.Ledger
              • Properties
                • GovDepsMatch
                • PoV
            • PParams
            • Properties
            • Ratify
              • Properties
            • Rewards
            • Script
              • Base
              • Timelock
              • Validation
              • Base
              • Coin
              • ValueSet
              • ValueVector
            • Transaction
            • Utxo
              • Properties
                • MinSpend
                • PoV
            • Utxow
              • Properties
              • Examples
                • HelloWorld
                • SucceedIfNumber
              • LedgerImplementation
              • Lib
              • Prelude
              • StructuredContracts
              • GovStructure
            • ConwayBootstrap
            • ConwayBootstrapEnact
            • ExternalFunctions
            • HSLedger
              • Address
              • BaseTypes
              • Cert
              • Certs
              • Chain
              • Core
              • Enact
              • Epoch
              • ExternalStructures
              • Gov
                • Core
                • Actions
              • Ledger
              • NewEpoch
              • PParams
              • Ratify
              • Transaction
              • Utxo
          • Conformance
            • Certs
              • Properties
            • Chain
              • Properties
            • Epoch
              • Properties
            • Equivalence
              • Bisimilarity
              • Certs
              • Convert
              • Deposits
              • Map
              • Utxo
            • Gov
            • Ledger
              • Properties
            • Properties
            • Script
            • Utxo
              • Properties
            • Utxow
              • Properties
        • PreConway
            • NewPP
              • Properties
            • PPUp
              • Properties
          • NewPP
            • Properties
          • PPUp
            • Properties
        • Convertible
          • Deriving
          • DerivingTest
        • HaskellTypes
          • Deriving
        • Agda Prelude
            • ComputationalRelation
            • HasSubset
            • HasSubtract
              • Instance
            • Hashable
            • STS
          • MyDebugOptions

    Properties

    {-# OPTIONS --safe #-}
    
    open import Relation.Nullary.Decidable
    
    open import Ledger.Prelude
    open import Ledger.Conway.Specification.Transaction
    
    module Ledger.PreConway.NewPP.Properties (txs : _) (open TransactionStructure txs) where
    
    open import Ledger.PreConway.PPUp txs
    open import Ledger.PreConway.NewPP txs
    
    instance
      Computational-NEWPP : Computational _⊢_⇀⦇_,NEWPP⦈_ String
      Computational-NEWPP = record {M} where module M Γ s (open NewPParamState s) where
        computeProof = λ where
          nothing → success (_ , NEWPP-Reject)
          (just upd) → let newpp = applyUpdate pparams upd in
            case ¿ viablePParams newpp ¿ of λ where
              (yes p) → success (_ , NEWPP-Accept p)
              (no _)  → failure "Failed in NEWPP"
    
        completeness : _
        completeness sig s' h with sig | h
        ... | nothing  | NEWPP-Reject   = refl
        ... | just upd | NEWPP-Accept p
          rewrite let newpp = applyUpdate pparams upd in
                  dec-yes (¿ viablePParams newpp ¿) p .proj₂
                  = refl
    
    Previous
    NewPP
    Next
    PPUp
    Made with Material for MkDocs