text
stringlengths
4
690k
------------------------------------------------------------------------ -- The Agda standard library -- -- Infinite merge operation for coinductive lists ------------------------------------------------------------------------ {-# OPTIONS --without-K --guardedness #-} module Codata.Musical.Colist.Infinite-merge wher...
------------------------------------------------------------------------ -- Order morphisms ------------------------------------------------------------------------ module Relation.Binary.OrderMorphism where open import Relation.Binary open Poset import Data.Function as F record _⇒-Poset_ (po₁ po₂ : Poset) : Set whe...
------------------------------------------------------------------------ -- An example: A non-terminating program that runs in bounded stack -- space ------------------------------------------------------------------------ module Lambda.Interpreter.Stack-sizes.Example where open import Equality.Propositional as E usi...
module Conway where open import Data.Bool renaming (_≟_ to _B≟_) open import Data.Nat renaming (_+_ to _ℕ+_ ; _*_ to _ℕ*_ ; _≟_ to _ℕ≟_) open import Data.Integer renaming (_+_ to _ℤ+_ ; _*_ to _ℤ*_ ; -_ to ℤ-_ ; _≟_ to _ℤ≟_) open import Data.Rational renaming (_≟_ to _ℚ≟_) open import Relation.Nullary.Core open imp...
module puzzle where ---- 仮定 -- 猫か犬を飼っている人は山羊を飼ってない -- 猫を飼ってない人は、犬かウサギを飼っている -- 猫も山羊も飼っていない人は、ウサギを飼っている -- ---- 問題 -- 山羊を飼っている人は、犬を飼っていない -- 山羊を飼っている人は、ウサギを飼っている -- ウサギを飼っていない人は、猫を飼っている module pet-research where open import logic open import Relation.Nullary open import Data.Empty postulate lem : (a : S...
{-# OPTIONS --without-K --safe #-} module Data.Binary where open import Data.Binary.Definitions using (𝔹) public open import Data.Binary.Operations.Semantics using (⟦_⇑⟧; ⟦_⇓⟧) public open import Data.Binary.Operations.Addition using (_+_) public open import Data.Binary.Operations.Multiplica...
{-# OPTIONS --without-K #-} module hott.level.closure.extra where open import level open import decidable open import sum open import level using (lsuc; ↑; lift) open import equality.core open import equality.calculus open import function.core using (_∘_; const) open import function.extensionality open import function...
module Cats.Category.Zero where open import Data.Empty using (⊥ ; ⊥-elim) open import Level open import Cats.Category Zero : ∀ lo la l≈ → Category lo la l≈ Zero lo la l≈ = record { Obj = Lift lo ⊥ ; _⇒_ = λ() ; _≈_ = λ {} ; id = λ{} ; _∘_ = λ{} ; equiv = λ{} ; ∘-resp = λ{} ; id-r = λ...
{- Some theory about Bi-Invertible Equivalences - BiInvEquiv to Iso - BiInvEquiv to Equiv - BiInvEquiv to HAEquiv - Iso to BiInvEquiv -} {-# OPTIONS --cubical --safe #-} module Cubical.Foundations.BiInvEquiv where open import Cubical.Core.Glue open import Cubical.Foundations.Prelude open import Cubical.Foundations...
------------------------------------------------------------------------ -- The Agda standard library -- -- Lists where every consecutative pair of elements is related. ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Data.List.Relation.Unary.Linked {a...
{-# OPTIONS --cubical --safe --postfix-projections #-} -- This file contains an implementation of the stack-based compiler for Hutton's -- razor, as from: -- -- P. Bahr and G. Hutton, “Calculating correct compilers,” Journal of -- Functional Programming, vol. 25, no. e14, Sep. 2015, -- doi: 10.1017/S095679681500...
open import Agda.Builtin.Equality postulate foo : (A : Set) → A ≡ A helper : {W : Set} (A : Set) → W → W ≡ A → (A → Set) → Set helper A w refl f = f w bar : (A : Set) → A → Set bar A a = let A≡A = foo A in helper A a (foo A) {!!} -- A≡A : A ≡ A baz : (A : Set) → A → Set baz A a = let A≡A = foo A in helper A a (f...
module cedille-syntax where open import lib open import ctxt open import syntax-util open import general-util open import is-free open import cedille-types -- App, AppTp infixl 10 _`_ _-_ _·_ -- Pattern and constructor pattern _`_ t t' = App t NotErased t' pattern _-_ t t' = App t Erased t' pattern _·_ t T = AppTp t T...
{-# OPTIONS --without-K #-} module mini-quine where open import common infixl 2 _▻_ infixl 3 _‘’_ infixr 1 _‘→’_ infixl 3 _‘’ₐ_ infixl 3 _w‘‘’’ₐ_ infixr 2 _‘∘’_ mutual data Context : Set where ε : Context _▻_ : (Γ : Context) → Type Γ → Context data Type : Context → Set where W : ∀ {Γ A} → Type Γ → Ty...
------------------------------------------------------------------------ -- Types with decidable equality have unique identity proofs, and -- related results ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} -- The part up to "decidable⇒set" follows a proof by...
------------------------------------------------------------------------ -- The Agda standard library -- -- Binary Trees ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Data.Tree.Binary where open import Level using (Level; _⊔_) open import Data.List...
module Formalization.ClassicalPropositionalLogic.NaturalDeduction.Proofs where open import Data.Boolean open import Data.Either open import Functional open import Formalization.ClassicalPropositionalLogic.NaturalDeduction open import Formalization.ClassicalPropositionalLogic.Place open import Formalization.ClassicalPr...
------------------------------------------------------------------------ -- Finite sets (currently only some type signatures) ------------------------------------------------------------------------ module Data.Sets where open import Relation.Nullary open import Relation.Binary open import Relation.Binary.OrderMorphi...
module Proof where open import Basics hiding (_==_) open import Proc open import Path import Graph private open module G = Graph Nat open module P = Process param hiding (U; T; _!_) {- Soundness: if we get an answer there is a path Completeness: if there is a path we get an answer -} infix 18 _encodes...
module DifferentArities where open import Common.Equality open import Common.Prelude f : Nat → Nat → Nat f zero = λ x → x f (suc n) m = f n (suc m) testf1 : f zero ≡ λ x → x testf1 = refl testf2 : ∀ {n m} → f (suc n) m ≡ f n (suc m) testf2 = refl testf3 : f 4 5 ≡ 9 testf3 = refl
------------------------------------------------------------------------ -- Binary relations lifted to substitutions ------------------------------------------------------------------------ {-# OPTIONS --safe --without-K #-} module Data.Fin.Substitution.Relation where open import Data.Fin using (Fin; zero; suc) open...
{-# OPTIONS --without-K --rewriting #-} open import HoTT open import cw.CW open import cw.FinCW open import cw.FinBoundary open import cohomology.Theory module cw.cohomology.cochainequiv.FirstCoboundaryCommSquare (OT : OrdinaryTheory lzero) (⊙fin-skel : ⊙FinSkeleton 1) where open OrdinaryTheory OT open import cw.c...
{-# OPTIONS --without-K --rewriting #-} open import lib.Basics open import lib.types.Paths open import lib.types.TwoSemiCategory open import lib.two-semi-categories.Functor module lib.two-semi-categories.FunctorInverse where module _ {k l} {B : Type k} {C : B → B → Type l} (comp : {b b' b'' : B} → C b b' → C b' b'...
{-# OPTIONS --without-K --safe #-} module Dodo.Nullary where open import Dodo.Nullary.Disjoint public open import Dodo.Nullary.Unique public open import Dodo.Nullary.XOpt public
-- WARNING: This file was generated automatically by Vehicle -- and should not be modified manually! -- Metadata -- - Agda version: 2.6.2 -- - AISEC version: 0.1.0.1 -- - Time generated: ??? open import Data.Unit module MyTestModule where e1 : let x = ⊤ in x e1 = checkProperty record { databasePath = DATABASE_P...
-- 2010-10-14 {-# OPTIONS --universe-polymorphism #-} module ProjectionsPreserveGuardednessTrivialExample where -- Coinduction is only available with universe polymorphism postulate Level : Set zero : Level suc : (i : Level) → Level _⊔_ : Level → Level → Level {-# BUILTIN LEVEL Level #-} {-# BUILTIN L...
------------------------------------------------------------------------ -- The Agda standard library -- -- Left-biased universe-sensitive functor and monad instances for These. -- -- To minimize the universe level of the RawFunctor, we require that -- elements of B are "lifted" to a copy of B at a higher universe leve...
{-# OPTIONS --without-K --safe #-} module Dodo.Binary.Flip where -- Stdlib imports open import Level using (Level; _⊔_) open import Function.Base using (flip) open import Relation.Binary using (Rel; REL) open import Relation.Binary using (Symmetric) -- Local imports open import Dodo.Binary.Equality -- # Operations ...
module MatchUpNames where open import ParseTree open import ScopeState open import Data.Sum open import Data.List hiding (lookup) open import AgdaHelperFunctions matchUpSignature : TypeSignature -> ScopeState TypeSignature matchUpExpr : Expr -> ScopeState Expr matchUpExpr (ident identifier₁) = do x <- access ident...
------------------------------------------------------------------------ -- Cyclic groups ------------------------------------------------------------------------ {-# OPTIONS --erased-cubical --safe #-} import Equality.Path as P module Group.Cyclic {e⁺} (eq : ∀ {a p} → P.Equality-with-paths a p e⁺) where open P.D...
import Structure.Logic.Classical.NaturalDeduction module Structure.Logic.Classical.PredicateBoundedQuantification {ℓₗ} {Formula} {ℓₘₗ} {Proof} {ℓₒ} {Domain} ⦃ classicLogic : _ ⦄ where open Structure.Logic.Classical.NaturalDeduction.ClassicalLogic {ℓₗ} {Formula} {ℓₘₗ} {Proof} {ℓₒ} {Domain} (classicLogic) open import F...
-- Andreas, 2013-10-21 -- Test case for CheckInternal extracted from The Agda standard library -- Propositional (intensional) equality module FunExt where open import Common.Level open import Common.Equality Extensionality : (a b : Level) → Set _ Extensionality a b = {A : Set a} {B : A → Set b} {f g : (x : A) → B ...
------------------------------------------------------------------------ -- The Agda standard library -- -- Helpers intended to ease the development of "tactics" which use -- proof by reflection ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} open import Dat...
{-# OPTIONS --cubical --safe #-} module Algebra.Construct.Free.Semilattice.Relation.Unary.Any.Def where open import Prelude hiding (⊥; ⊤) open import Algebra.Construct.Free.Semilattice.Eliminators open import Algebra.Construct.Free.Semilattice.Definition open import Cubical.Foundations.HLevels open import Data.Empty....
{-# OPTIONS --safe #-} open import Definition.Typed.EqualityRelation module Definition.LogicalRelation.Fundamental {{eqrel : EqRelSet}} where open EqRelSet {{...}} open import Definition.Untyped open import Definition.Untyped.Properties open import Definition.Typed open import Definition.Typed.Properties open impor...
module Oscar.Data.Term.ThickAndThin.internal {𝔣} (FunctionName : Set 𝔣) where open import Oscar.Class.AlphaConversion import Oscar.Class.ThickAndThin as ⋆ open import Oscar.Data.Term FunctionName open import Oscar.Data.Term.Injectivity FunctionName open import Oscar.Data.Term.AlphaConversion FunctionName open impor...
module Oscar.Data.Substitist {𝔣} (FunctionName : Set 𝔣) where open import Oscar.Data.Fin open import Oscar.Data.Nat open import Oscar.Data.Product open import Oscar.Data.Term FunctionName open import Oscar.Data.AList open import Oscar.Data.Equality Substitist : Nat → Nat → Set 𝔣 Substitist m n = AList (λ m → Term...
module Prelude where open import Data.Nat public open import Data.Nat.Properties.Simple public open import Data.Fin using (Fin; #_; suc; zero) public open import Data.Unit using (tt; ⊤) public open import Data.Empty public open import Data.Bool using (true; false; Bool) public open import Data.Product public using (...
open import Categories open import Functors open import RMonads module RMonads.CatofRAdj.InitRAdj {a b c d}{C : Cat {a}{b}}{D : Cat {c}{d}} {J : Fun C D}(M : RMonad J) where open import Library open import Naturals hiding (Iso; module Iso) open import RAdjunctions open import RMonads...
module ASN1 where open import ASN1.Untyped public open import ASN1.BER public open import ASN1.X509 public
{-# OPTIONS --without-K --rewriting #-} open import lib.Basics open import lib.NType2 open import lib.types.Group open import lib.types.EilenbergMacLane1.Core open import lib.groups.Homomorphism open import lib.groups.LoopSpace open import lib.two-semi-categories.FundamentalCategory open import lib.two-semi-categories...
{-# OPTIONS --cubical-compatible #-} postulate w/e : Set data _==_ {A : Set} : A → A → Set where idp : {a : A} → a == a data Square {A : Set} {a : A} : {b c d : A} (p : a == b) (q : c == d) (r : a == c) (s : b == d) → Set where ids : Square {a = a} idp idp idp idp J1 : {A : Set} {a : A} {p : a == a} → Square p ...
{-# OPTIONS --cubical --no-import-sorts #-} module SpacesFirstAttempt where open import Agda.Primitive renaming (_⊔_ to ℓ-max; lsuc to ℓ-suc; lzero to ℓ-zero) private variable ℓ ℓ' ℓ'' : Level open import Cubical.Foundations.Everything renaming (_⁻¹ to _⁻¹ᵖ; assoc to ∙-assoc) open import Cubical.Relation.Null...
open import Relation.Binary.Core module Order.Total {A : Set} (_≤_ : A → A → Set) (tot≤ : Total _≤_) where open import Data.Sum refl≤ : {x : A} → x ≤ x refl≤ {x} with tot≤ x x ... | inj₁ x≤x = x≤x ... | inj₂ x≤x = x≤x
module hott.topology.loopspace.theorems where open import hott.core open import hott.core.theorems open import hott.topology.loopspace.eckmann-hilton public
module Data.Int.Literal where open import Data.Nat using (ℕ) open import Level using (suc) record Negative {a} (A : Set a) : Set (suc a) where field Constraint : ℕ → Set a fromNeg : (n : ℕ) → ⦃ Constraint n ⦄ → A open Negative {{...}} public using (fromNeg) {-# BUILTIN FROMNEG fromNeg #-}
{-# OPTIONS --prop --cubical-compatible #-} data _≡_ {A : Set} (x : A) : A → Prop where refl : x ≡ x
------------------------------------------------------------------------ -- A type for values that should be erased at run-time ------------------------------------------------------------------------ -- This module contains some basic definitions with few dependencies -- (in particular, not Function-universe) that do...
{-# OPTIONS --without-K #-} {- Imports everything that is not imported by something else. This is not supposed to be used anywhere, this is just a simple way to do `make all' This file is intentionally named index.agda so that Agda will generate index.html. -} module index where -- import Spaces.IntervalProps -- i...
module Groups.Symm.S3 where open import Equality ------------------------------------------------------------------------ -- definitions bin-op : ∀ {a} (A : Set a) → Set a bin-op A = A → A → A ------------------------------------------------------------------------ -- internal stuffs private record S₃ {a} (A : ...
------------------------------------------------------------------------ -- The Agda standard library -- -- Order-theoretic lattices ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} module Relation.Binary.Lattice where open import Algebra.FunctionProperties ...
open import Prelude open import Nat open import Bij module Int where data Int : Set where +_ : Nat → Int -[1+_] : Nat → Int int→nat : Int → Nat int→nat (+ n) = 1+ (n + n) int→nat -[1+ n ] = n + n int→nat:inj : ∀{m n} → int→nat m == int→nat n → m == n int...
module Haskell.RangedSetsProp.RangesProperties where open import Haskell.RangedSetsProp.library open import Agda.Builtin.Equality open import Agda.Builtin.Bool open import Agda.Builtin.Nat renaming (_==_ to eqq; _<_ to ltt) open import Haskell.Prim open import Haskell.Prim.Ord open import Haskell.Prim.Bool open impo...
module Haskell.RangedSetsProp.library where open import Agda.Builtin.Equality open import Agda.Builtin.Bool open import Haskell.Prim open import Haskell.Prim.Ord open import Haskell.Prim.Bool open import Haskell.Prim.Eq open import Haskell.Prim.Int open import Haskell.Prim.List open import Haskell.RangedSets.Boundari...
------------------------------------------------------------------------ -- The Agda standard library -- -- Several kinds of "relatedness" for containers such as equivalences, -- surjections and bijections ------------------------------------------------------------------------ {-# OPTIONS --without-K --safe #-} modu...
{-# OPTIONS --without-K #-} module EquivEquiv where open import Level using (Level; _⊔_) open import Data.Product using (_,_; proj₁; proj₂) open import Data.Sum using (inj₁; inj₂) open import Relation.Binary using (Setoid) import Relation.Binary.PropositionalEquality as P using (_≡_; refl; sym; trans; cong; module...
module Cats.Functor where open import Level open import Relation.Binary using (_Preserves_⟶_) open import Cats.Category.Base open import Cats.Util.Function using () renaming (_∘_ to _⊙_) open import Cats.Util.SetoidMorphism using (_⇒_ ; IsInjective ; IsSurjective) open import Cats.Util.SetoidMorphism.Iso using ( Is...
{-# OPTIONS --prop --without-K --rewriting #-} -- Step effect. open import Calf.CostMonoid module Calf.Step (costMonoid : CostMonoid) where open CostMonoid costMonoid open import Calf.Prelude open import Calf.Metalanguage open import Calf.PhaseDistinction open import Relation.Binary.PropositionalEquality cost : t...
open import Prelude hiding (module Fin) renaming (_≟_ to _N≟_) module Implicits.Syntax.Type where open import Data.Fin.Substitution open import Data.Nat.Properties as NatProps open import Data.Star using (Star; ε; _◅_) open import Data.List open import Data.List.All hiding (map) open import Data.Maybe hiding (map; Al...
module Lectures.Three where open import Lectures.One open import Lectures.Two -- Introduce propositional equality data _≡_ {A : Set} (x : A) : A → Set where refl : x ≡ x {-# BUILTIN EQUALITY _≡_ #-} -- Comment on precendences infix 10 _≡_ record Equivalence (_~_ : ∀ {A : Set} → A → A → Set) : Set₁ where field...
{-# OPTIONS --universe-polymorphism #-} module Categories.Support.SetoidFunctions where open import Level open import Function using (_on_) open import Relation.Binary as B using (_=[_]⇒_) open import Relation.Binary.PropositionalEquality using () renaming (cong to ≡-cong; cong₂ to ≡-cong₂) open import Data.Product u...
{-# OPTIONS --without-K --exact-split --safe #-} module Fragment.Equational.Theory.Base where open import Function using (_∘_) open import Fragment.Algebra.Signature open import Fragment.Algebra.Free open import Fragment.Algebra.Algebra open import Fragment.Algebra.Properties open import Data.Nat using (ℕ) open imp...
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Algebra.Group.Algebra where open import Cubical.Foundations.Prelude open import Cubical.Foundations.Isomorphism open import Cubical.Foundations.HLevels open import Cubical.Foundations.Structure open import Cubical.Foundations.Function using (_∘_) open i...
{-# OPTIONS --copatterns --sized-types #-} -- {-# OPTIONS -v tc.size.solve:60 #-} open import Common.Size open import Common.Prelude open import Common.Product -- Sized streams via head/tail. record Stream {i : Size} (A : Set) : Set where coinductive constructor delay field force : ∀ {j : Size< i} → A × St...
{-# OPTIONS --without-K --safe #-} -- The Underlying category of an Enriched category over a Monoidal category V open import Categories.Category.Monoidal using (Monoidal) open import Categories.Category.Core renaming (Category to Setoid-Category) module Categories.Enriched.Category.Underlying {o ℓ e} {V : Setoid-Categ...
{- This second-order signature was created from the following second-order syntax description: syntax UTLC | Λ type * : 0-ary term app : * * -> * | _$_ l20 lam : *.* -> * | ƛ_ r10 theory (ƛβ) b : *.* a : * |> app (lam (x.b[x]), a) = b[a] (ƛη) f : * |> lam (x.app (f, x)) = f (lβ) b : ...
module InterpretCommand where open import ParseTree open import Data.List open import Data.Nat open import ScopeState open import Data.Sum hiding (map) open import Data.Bool open import Data.String hiding (_++_) open import Data.Maybe hiding (map) open import Data.Product hiding (map) open import AgdaHelperFunctions ...
{-# OPTIONS --without-K --exact-split --safe #-} open import Fragment.Algebra.Signature module Fragment.Equational.Theory.Laws (Σ : Signature) where open import Fragment.Equational.Theory.Base using (Eq) open import Function using (_∘_) open import Data.Empty using (⊥) open import Data.Fin using (#_) open import Da...
------------------------------------------------------------------------------ -- Properties of the mirror function ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymorphism...
module RecordUpdateSyntax where open import Common.Prelude open import Common.Equality data Param : Nat → Set where param : ∀ n → Param (suc n) record R : Set where field {i} : Nat p : Param i s : Nat old : R old = record { p = param 0; s = 1 } -- Simple update, it should be able to infer the type ...
module Thesis.Derive where open import Thesis.Lang open import Thesis.Changes open import Thesis.LangChanges open import Thesis.LangOps open import Relation.Binary.PropositionalEquality Γ≼ΔΓ : ∀ {Γ} → Γ ≼ ΔΓ Γ Γ≼ΔΓ {∅} = ∅ Γ≼ΔΓ {τ • Γ} = drop Δt τ • keep τ • Γ≼ΔΓ fit : ∀ {τ Γ} → Term Γ τ → Term (ΔΓ Γ) τ fit = weaken...
module z where ------------------------------------------------------------------------------ -- 1 intro -- data types data Nat : Set where zero : Nat suc : Nat → Nat {-# BUILTIN NATURAL Nat #-} -------------------------------------------------- -- begin : from later - here to use in tests data Bool : Se...
module hott.topology.theorems where open import hott.topology open import hott.topology.loopspace.theorems public
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Axiom.Omniscience where open import Cubical.Foundations.Function open import Cubical.Foundations.HLevels open import Cubical.Foundations.Isomorphism open import Cubical.Foundations.Prelude open import Cubical.Foundations.Transport open import Cubical....
------------------------------------------------------------------------------ -- Properties of the divisibility relation ------------------------------------------------------------------------------ {-# OPTIONS --exact-split #-} {-# OPTIONS --no-sized-types #-} {-# OPTIONS --no-universe-polymo...
{- Finite Types This file formalize the notion of Rijke finite type, which is a direct generalization of Bishop finite set. Basically, a type is (Rijke) n-finite if its i-th order homotopy groups πᵢ are Bishop finite for i ≤ n. Referrences: https://github.com/EgbertRijke/OEIS-A000001 -} {-# OPTIONS --safe #-} mo...
{-# OPTIONS --without-K --safe #-} module Strict where open import Agda.Builtin.Strict public open import Level infixr 0 _$!_ _$!_ : {A : Type a} {B : A → Type b} → (∀ x → B x) → ∀ x → B x f $! x = primForce x f {-# INLINE _$!_ #-} infixr 0 let-bang let-bang : {A : Type a} {B : A → Type b} → ∀ x → (∀ x → B x) → B x...
module lambda.stack where open import Relation.Binary.PropositionalEquality infixr 40 _▸_ infixl 35 _∈_ data stack (T : Set) : Set where ε : stack T _▸_ : stack T → T → stack T data _∈_ {T : Set} (x : T) : stack T → Set where here : ∀ {Γ} → x ∈ Γ ▸ x there : ∀ {Γ y} → x ∈ Γ → x ∈ Γ ▸ y data _⊇_ {T : Set} :...
data ⊥ : Set where p0 : Set → Set p0 A = A p1 : ⊥ → Set p1 () p2 : ⊥ → ⊥ p2 () p3 : Set → ⊥ p3 = ?
record Additive {ℓ} (A : Set ℓ) : Set ℓ where field zero : A _+_ : A → A → A open Additive {{...}} public record Subtractive {ℓ} (A : Set ℓ) {{ADD : Additive A}} : Set ℓ where field _-_ : A → A → A neg : A → A neg x = zero - x open Subtractive {{...}} public check : ∀ ℓ (A : Set ℓ) (ADD : Addi...
{-# OPTIONS --cubical --no-import-sorts --safe #-} module Cubical.Algebra.Group.Base where open import Cubical.Foundations.Prelude open import Cubical.Data.Sigma open import Cubical.Data.Prod renaming (_×_ to _×'_) open import Cubical.Data.Int renaming (_+_ to _+Int_ ; _-_ to _-Int_) open import Cubical.Data.Unit ope...
module Sets.PredicateSet.Proofs where import Lvl open import Functional import Logic.Propositional as Logic import Logic.Propositional.Theorems as Logic import Logic.Predicate import Sets.PredicateSet import Structure.Relator.Properties import Type -- [⊆][⊇]-equivalence : ∀...
module AsP where f : {A : Set} → A → A → A f x@y z@w = x g : {A : Set} → A → A → A g x@y z'@w' with y ... | _ = x
module Lemmachine.Resource where import Lemmachine.Resource.Universe open import Data.Product open import Data.List private module U = Lemmachine.Resource.Universe open U using (Code; El) Hook = Σ Code El Hooks = List Hook _⇒_ : {A : Set}{B : A → Set} → (a : A) → B a → (Σ A B) _⇒_ = _,_ record Resource : Set wh...
module _ where postulate U : Set u : U module M (x : U) where postulate f : U → U module M₁ = M (M.f u u) -- this caused a 'recursive display form' error
{-# OPTIONS --without-K --rewriting #-} open import HoTT open import stash.modalities.gbm.GbmUtil module stash.modalities.JoinAdj {i j k} (A : Type i) (B : Type j) (C : Type k) where private module From (f : B → C) (γ : A → hfiber cst f) = JoinRec (fst ∘ γ) f (λ a b → app= (snd (γ a)) b) from-β...
------------------------------------------------------------------------ -- A virtual machine ------------------------------------------------------------------------ module Lambda.VirtualMachine where open import Category.Monad open import Category.Monad.Partiality as P using (_⊥; never); open P._⊥ open import Cod...
{-# OPTIONS --without-K --safe #-} module FreshUtil where open import Level using (Level; _⊔_; Lift) open import Data.Empty open import Data.Product using (∃; _,_; -,_) open import Data.Sum.Base using (_⊎_; [_,_]′; inj₁; inj₂) open import Function.Equivalence using (_⇔_; equivalence) open import Relation.Nullary impor...
{-# OPTIONS --without-K --safe #-} open import Categories.Bicategory using (Bicategory) -- The 1-cell dual (op) and 2-cell dual (co) of a given bicategory. module Categories.Bicategory.Opposite where open import Data.Product using (_,_) import Categories.Bicategory.Extras as BicategoryExtras open import Categories...
{-# OPTIONS --safe --warning=error --without-K #-} open import LogicalFormulae open import Setoids.Setoids open import Agda.Primitive using (Level; lzero; lsuc; _⊔_) open import Groups.Definition open import Sets.EquivalenceRelations open import Setoids.Functions.Extension module Groups.SymmetricGroups.Definition whe...
import Relation.Unary.Monotone as Mono open import Relation.Binary using (Preorder) open import Relation.Binary.PropositionalEquality open import Level module Category.Monad.Monotone.Heap -- preordered heap types {ℓ}(pre : Preorder ℓ ℓ ℓ) -- types (T : Set ℓ) -- weakenable values (V : T → Preorder.Carrier ...
module BasicT.Metatheory.Gentzen-BasicTarski where open import BasicT.Syntax.Gentzen public open import BasicT.Semantics.BasicTarski public -- Soundness with respect to all models, or evaluation. eval : ∀ {A Γ} → Γ ⊢ A → Γ ⊨ A eval (var i) γ = lookup i γ eval (lam t) γ = λ a → eval t (γ , a) eval (app t u) ...
{-# OPTIONS --without-K #-} module Pifextensional where open import Relation.Binary.PropositionalEquality using (_≡_; refl; sym; trans; cong; cong₂; module ≡-Reasoning) open ≡-Reasoning open import Data.Empty using (⊥) open import Data.Unit using (⊤; tt) open import Data.Sum using (_⊎_; inj₁; inj₂) open ...
open import Prelude hiding (_<_) module Implicits.Resolution.GenericFinite.Resolution where open import Coinduction open import Data.List open import Data.List.Any open Membership-≡ open import Data.Fin.Substitution open import Relation.Binary using (Rel) open import Implicits.Syntax open import Implicits.Syntax.Typ...
module Haskell.Prim.Bounded where open import Agda.Builtin.Nat open import Agda.Builtin.Bool open import Agda.Builtin.Char open import Agda.Builtin.Equality open import Agda.Builtin.List open import Haskell.Prim open import Haskell.Prim.Eq open import Haskell.Prim.Int open import Haskell.Prim.Maybe open import Haske...
{-# OPTIONS --without-K --rewriting #-} open import lib.Basics module C1 {@♭ i₁ j₁ : ULevel} (@♭ I : Type i₁) (@♭ R : I → Type j₁) (@♭ r₀ : (index : I) → R index) where -- We assume the family R satisfies Axiom C0 open import Axiom.C0 {i₁} {j₁} I R open import Basics open imp...
-- this is so this can be imported even though it has unresolved holes {-# OPTIONS --allow-unsolved-metas #-} module v01-01-basics where import Relation.Binary.PropositionalEquality as Eq open Eq using (_≡_; refl) open Eq.≡-Reasoning using (begin_; _≡⟨⟩_; _∎) data day : Set where mon : day tue : day w...
open import Agda.Builtin.Unit open import Agda.Builtin.List open import Agda.Builtin.Reflection id : {A : Set} → A → A id x = x macro tac : Term → TC ⊤ tac hole = unify hole (def (quote id) (arg (arg-info visible relevant) (var 0 []) ∷ [])) test : {A : Set} → A → A test x = {!tac!}
module bijection where open import Level renaming ( zero to Zero ; suc to Suc ) open import Data.Nat open import Data.Maybe open import Data.List hiding ([_] ; sum ) open import Data.Nat.Properties open import Relation.Nullary open import Data.Empty open import Data.Unit hiding ( _≤_ ) open import Relation.Binary.Cor...
{-# OPTIONS --without-K --rewriting #-} open import lib.Basics open import lib.NType2 open import lib.types.TLevel module experimental.Category where record CategoryStructure {i j} (Obj : Type i) (Mor : Obj → Obj → Type j) : Type (lmax i j) where constructor category-structure field comp : {o₁ o₂ o₃ : Obj}...