text stringlengths 4 690k |
|---|
{-# OPTIONS --without-K --rewriting #-}
open import HoTT
module homotopy.WedgeOfCircles {i} where
WedgeOfCircles : (I : Type i) → Type i
WedgeOfCircles I = BigWedge {A = I} (λ _ → ⊙S¹)
|
{-# OPTIONS --safe --warning=error --without-K #-}
open import LogicalFormulae
open import Groups.Homomorphisms.Definition
open import Groups.Definition
open import Setoids.Setoids
open import Sets.EquivalenceRelations
open import Rings.Definition
open import Lists.Lists
open import Rings.Homomorphisms.Definition
mod... |
module MLib.Fin.Parts.Core where
open import MLib.Prelude
open Nat using (_*_; _+_; _<_)
open Table
record Parts {a} (A : Set a) (size : A → ℕ) : Set a where
field
numParts : ℕ
parts : Table A numParts
partAt = lookup parts
sizeAt = size ∘ partAt
totalSize = sum (map size parts)
partsizes = tabula... |
{-# OPTIONS --cubical --safe #-}
module Data.Ternary where
open import Prelude
open import Relation.Nullary.Discrete.FromBoolean
infixl 5 _,0 _,1 _,2
data Tri : Type where
0t : Tri
_,0 _,1 _,2 : Tri → Tri
infix 4 _≡ᴮ_
_≡ᴮ_ : Tri → Tri → Bool
0t ≡ᴮ 0t = true
x ,0 ≡ᴮ y ,0 = x ≡ᴮ y
x ,1 ≡ᴮ y ,1 = x ≡ᴮ y
x ,2 ≡... |
module Sublist where
open import Data.List
open import Data.List.All
open import Data.List.Any
open import Level
open import Relation.Binary.PropositionalEquality hiding ([_])
open import Function
open import Category.Monad
open import Data.Product
open import Membership-equality hiding (_⊆_; set)
infix 3 _⊆_
-- Su... |
{-
This file contains:
- The reduced version gives the same type as James.
-}
{-# OPTIONS --safe --experimental-lossy-unification #-}
module Cubical.HITs.James.Inductive.ColimitEquivalence where
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv
open import Cubical.Foundations.Isomorphis... |
-- 2017-06-16, reported by Ambrus Kaposi on the Agda mailing list
-- WAS:
-- β is not a legal rewrite rule, since the left-hand side
-- f a reduces to f a
-- when checking the pragma REWRITE β
-- SHOULD: succeed
{-# OPTIONS --rewriting #-}
module _ where
module a where
postulate
_~_ : {A : Set} → A → A → Set... |
{-# OPTIONS --show-implicit #-}
module Substitution where
|
import Lvl
open import Data.Boolean
open import Type
module Data.List.Sorting {ℓ} {T : Type{ℓ}} (_≤?_ : T → T → Bool) where
open import Functional using (_∘₂_)
open import Data.Boolean.Stmt
open import Data.List
import Data.List.Relation.Pairwise
open import Data.List.Relation.Permutation
open import Logic
... |
{-# OPTIONS --without-K #-}
module NTypes.Sigma where
open import NTypes
open import PathOperations
open import PathStructure.Sigma
open import Transport
open import Types
Σ-isSet : ∀ {a b} {A : Set a} {B : A → Set b} →
isSet A → (∀ x → isSet (B x)) → isSet (Σ A B)
Σ-isSet {A = A} {B = B} A-set B-set x y p q
= sp... |
{-# OPTIONS --without-K --exact-split --safe #-}
module Fragment.Setoid.Morphism.Setoid where
open import Fragment.Setoid.Morphism.Base
open import Level using (Level; _⊔_)
open import Relation.Binary using (Setoid; IsEquivalence; Rel)
private
variable
a b ℓ₁ ℓ₂ : Level
module _ {S : Setoid a ℓ₁} {T : Setoid... |
open import Common.Prelude
open import Common.Reflect
module TermSplicingOutOfScope where
f : Set → Set → Set → Set
f x y z = unquote (var 3 [])
|
module Data.List.First.Membership {ℓ}{A : Set ℓ} where
open import Data.Product
open import Data.List
open import Data.List.Relation.Unary.Any
open import Data.List.First hiding (find)
open import Relation.Nullary
open import Relation.Binary
open import Relation.Binary.PropositionalEquality
open import Level
open impo... |
------------------------------------------------------------------------
-- Nullary relations (some core definitions)
------------------------------------------------------------------------
-- The definitions in this file are reexported by Relation.Nullary.
module Relation.Nullary.Core where
open import Data.Empty
... |
open import Agda.Primitive
f : ∀ {a b c} → Set a → Set b → Set c → Set {!!} -- WAS solution: (a ⊔ (b ⊔ c))
f A B C = A → B → C -- NOW: (a ⊔ b ⊔ c)
|
{-# OPTIONS --safe #-}
module Cubical.Categories.Instances.Functors where
open import Cubical.Categories.Category
open import Cubical.Categories.Functor.Base
open import Cubical.Categories.NaturalTransformation.Base
open import Cubical.Categories.NaturalTransformation.Properties
open import Cubical.Categories.Morphis... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Lemmas relating algebraic definitions (such as associativity and
-- commutativity) that don't the equality relation to be a setoid.
------------------------------------------------------------------------
{-# OP... |
------------------------------------------------------------------------
-- Undecidability of subtyping in Fω with interval kinds
------------------------------------------------------------------------
{-# OPTIONS --safe --without-K #-}
module FOmegaInt.Undecidable where
open import Function.Equivalence using (_⇔_;... |
{-# OPTIONS --cubical --safe #-}
module Data.List.Smart where
open import Prelude
open import Data.Nat.Properties using (_≡ᴮ_; complete-==)
infixr 5 _∷′_ _++′_
data List {a} (A : Type a) : Type a where
[]′ : List A
_∷′_ : A → List A → List A
_++′_ : List A → List A → List A
sz′ : List A → ℕ → ℕ
sz′ []′ k ... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Lists made up entirely of unique elements (propositional equality)
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.List.Relation.Unary.Uni... |
{-# OPTIONS --without-K #-}
open import Base
open import Homotopy.Pushout
open import Homotopy.VanKampen.Guide
module Homotopy.VanKampen.Code.LemmaPackB {i} (d : pushout-diag i)
(l : legend i (pushout-diag.C d)) where
open pushout-diag d
open legend l
open import Homotopy.Truncation
open import Homotopy.P... |
{-# OPTIONS --rewriting #-}
open import Agda.Builtin.Equality
{-# BUILTIN REWRITE _≡_ #-}
data Bool : Set where true false : Bool
op : Bool → Set → Set
op false _ = Bool
op true A = A
postulate
id : Bool → Bool
id-comp : ∀ y → id y ≡ y
{-# REWRITE id-comp #-}
postulate
A : Set
law : (i : Bool) → op (id ... |
-- 2010-09-24
-- example originally stolen from Andrea Vezzosi's post on the Agda list
{-# OPTIONS --no-irrelevant-projections #-}
module IrrelevantRecordFields where
open import Common.Equality
record SemiG : Set1 where
constructor _,_,_,_,_,_
field
M : Set
unit : M
_+_ : M -> M -> M
.assoc :... |
-- An ATP type must be used with data-types or postulates.
-- This error is detected by Syntax.Translation.ConcreteToAbstract.
module ATPBadType1 where
data Bool : Set where
false true : Bool
{-# ATP type false #-}
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- Machine words: basic type and conversion functions
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.Word.Base where
open import Level usin... |
{-# OPTIONS --without-K --safe #-}
-- The Category of Algebraic Kan Complexes
module Categories.Category.Instance.KanComplexes where
open import Level
open import Function using (_$_)
open import Data.Product using (Σ; _,_; proj₁)
open import Categories.Category
open import Categories.Category.SubCategory
open impo... |
{-# OPTIONS --without-K #-}
open import HoTT
module homotopy.PathSetIsInital {i} (A : Type i)
-- (A-conn : is-connected 0 A)
where
open Cover
module _
(a₁ : A)
-- And an arbitrary covering.
{k} (cov : Cover A k)
-- (cov-conn : is-connected 0 (Cover.TotalSpace cov))
(a↑₁ : Fiber cov a₁)
... |
{-# OPTIONS --copatterns #-}
module EmptyInductiveRecord where
mutual
data E : Set where
e : F -> E
record F : Set where
inductive
constructor c
field f : E
open F
data ⊥ : Set where
elim : E → ⊥
elim (e (c x)) = elim x
mutual
empty : E
empty = e empty?
empty? : F
f empty? = empty
a... |
module Generic.Test.Data.List where
module _ where
open import Generic.Main as Main hiding ([]; _∷_) renaming (List to StdList)
infixr 5 _∷_ _∷′_
List : ∀ {α} -> Set α -> Set α
List = readData StdList
pattern [] = #₀ lrefl
pattern _∷_ x xs = !#₁ (relv x , xs , lrefl)
_∷′_ : ∀ {α} {A : Set α} ->... |
------------------------------------------------------------------------
-- Code related to the paper "Total Definitional Interpreters for Time
-- and Space Complexity"
--
-- Nils Anders Danielsson
------------------------------------------------------------------------
-- Note that the code has evolved after the pape... |
{-# OPTIONS --type-in-type #-}
module Prob where
open import DescTT
mutual
data Sch : Set where
ty : (S : Set) -> Sch
exPi : (s : Sch)(T : toType s -> Sch) -> Sch
imPi : (S : Set)(T : S -> Sch) -> Sch
toType : Sch -> Set
toType (ty S) = S
toType (exPi s T) = (x : toType s) -> toType (T x)... |
{-# OPTIONS --without-K #-}
module HoTT.Equivalence.Proposition where
open import HoTT.Base
open import HoTT.HLevel
open import HoTT.Equivalence
open variables
-- Proven by Theorem 4.3.2
postulate
isequiv-prop : {f : A → B} → isProp (isequiv f)
{-
fib : B → 𝒰 _
fib y = Σ[ x ∶ A ] (f x == y)
-- Left invers... |
{-# OPTIONS --safe #-}
module STLC.Operational.Eager where
open import STLC.Syntax
open import STLC.Operational.Base
open import Data.Empty using (⊥-elim)
open import Data.Product using (∃-syntax; _,_)
open import Data.Sum using (_⊎_; inj₁; inj₂)
open import Data.Nat using (ℕ; zero; suc; _+_)
open import Data.Fin usin... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Indexed container combinators
------------------------------------------------------------------------
module Data.Container.Indexed.Combinator where
open import Level
open import Data.Container.Indexed
open im... |
{-# OPTIONS --without-K --safe #-}
module Data.Binary.Definition where
open import Level
open import Data.Bits public renaming (Bits to 𝔹; [] to 0ᵇ; 0∷_ to 1ᵇ_; 1∷_ to 2ᵇ_)
-- The following causes a performance hit:
-- open import Agda.Builtin.List using ([]; _∷_; List)
-- open import Agda.Builtin.Bool using (Bool... |
------------------------------------------------------------------------------
-- Conat properties
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-# OPTIONS ... |
{-# OPTIONS --cubical --no-import-sorts --safe #-}
open import Cubical.Core.Everything
module Cubical.Algebra.Structures {a} (A : Type a) where
-- The file is divided into sections depending on the arities of the
-- components of the algebraic structure.
open import Cubical.Foundations.Prelude using (isSet; cong; _... |
module BBHeap.Order.Properties {A : Set}(_≤_ : A → A → Set) where
open import BBHeap _≤_
open import BBHeap.Order _≤_ renaming (Acc to Accₕ ; acc to accₕ)
open import Data.Nat
open import Induction.Nat
open import Induction.WellFounded
ii-acc : ∀ {b} {h} → Acc _<′_ (# {b} h) → Accₕ h
ii-acc (acc rs) = accₕ (λ h' #h'... |
{-# OPTIONS --without-K --safe #-}
open import Definition.Typed.EqualityRelation
module Definition.LogicalRelation.Substitution.Introductions.Emptyrec {{eqrel : EqRelSet}} where
open EqRelSet {{...}}
open import Definition.Untyped as U hiding (wk)
open import Definition.Untyped.Properties
open import Definition.Type... |
module Numeral.Finite.Bound where
open import Lang.Instance
open import Numeral.Finite
open import Numeral.Natural
open import Numeral.Natural.Relation.Order
open import Numeral.Natural.Relation.Order.Proofs
-- For an arbitrary number `n`, `bound-[≤] n` is the same number as `n` semantically but with a different boun... |
module Avionics.Real where
open import Algebra.Definitions using (LeftIdentity; RightIdentity; Commutative)
open import Data.Bool using (Bool; _∧_)
open import Data.Float using (Float)
open import Data.Maybe using (Maybe; just; nothing)
open import Data.Nat using (ℕ)
open import Level using (0ℓ; _⊔_) renaming (suc to ... |
open import Prelude
open import Nat
open import List
open import Bij
-- The contents of this file were originally written in a different codebase,
-- which was itself a descendant of a prior codebase that had been using non-standard
-- definitions of naturals and other basic definitions. As such this code has
-- inher... |
module FixityOutOfScopeInRecord where
postulate _+_ : Set
record R : Set where
infixl 30 _+_
-- Should complain that _+_ is not in (the same) scope
-- in (as) its fixity declaration.
|
{- Byzantine Fault Tolerant Consensus Verification in Agda, version 0.9.
Copyright (c) 2021, Oracle and/or its affiliates.
Licensed under the Universal Permissive License v 1.0 as shown at https://opensource.oracle.com/licenses/upl
-}
open import LibraBFT.Base.Types
open import LibraBFT.Impl.Consensus.Liveness.... |
module Logic.Identity where
open import Logic.Equivalence
open import Logic.Base
infix 20 _≡_ _≢_
data _≡_ {A : Set}(x : A) : A -> Set where
refl : x ≡ x
subst : {A : Set}(P : A -> Set){x y : A} -> x ≡ y -> P y -> P x
subst P {x} .{x} refl px = px
sym : {A : Set}{x y : A} -> x ≡ y -> y ≡ x
sym {A} refl = refl
... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- This module is DEPRECATED. Please use
-- Data.List.Relation.Binary.Lex.NonStrict directly.
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data... |
------------------------------------------------------------------------
-- Binomial theorem
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe --exact-split #-}
module Math.BinomialTheorem.Nat where
-- agda-stdlib
open import Data.Nat
open import Data.Nat.Propert... |
{-
This second-order signature was created from the following second-order syntax description:
syntax Combinatory | CL
type
* : 0-ary
term
app : * * -> * | _$_ l20
i : *
k : *
s : *
theory
(IA) x |> app (i, x) = x
(KA) x y |> app (app(k, x), y) = x
(SA) x y z |> app (app (app (s, x), ... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Examples of decision procedures and how to use them
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module README.Decidability where
-- Reflects and ... |
{-# OPTIONS --cubical-compatible #-}
module WithoutK2 where
-- Equality defined with two indices.
data _≡_ {A : Set} : A → A → Set where
refl : ∀ x → x ≡ x
K : {A : Set} (P : {x : A} → x ≡ x → Set) →
(∀ x → P (refl x)) →
∀ {x} (x≡x : x ≡ x) → P x≡x
K P p (refl x) = p x
|
open import SOAS.Common
open import SOAS.Families.Core
open import Categories.Object.Initial
open import SOAS.Coalgebraic.Strength
import SOAS.Metatheory.MetaAlgebra
-- Substitution structure by initiality
module SOAS.Metatheory.Substitution {T : Set}
(⅀F : Functor 𝔽amiliesₛ 𝔽amiliesₛ) (⅀:Str : Strength ⅀F)
(𝔛... |
module BuiltinConstructorsNeededForLiterals where
data Nat : Set where
zero : Nat → Nat
suc : Nat → Nat
{-# BUILTIN NATURAL Nat #-}
data ⊥ : Set where
empty : Nat → ⊥
empty (zero n) = empty n
empty (suc n) = empty n
bad : ⊥
bad = empty 0
|
{-# OPTIONS --without-K #-}
open import HoTT
open import homotopy.HSpace renaming (HSpaceStructure to HSS)
open import homotopy.WedgeExtension
module homotopy.Pi2HSusp where
module Pi2HSusp {i} (A : Type i) (gA : has-level ⟨ 1 ⟩ A)
(cA : is-connected ⟨0⟩ A) (A-H : HSS A)
(μcoh : HSS.μe- A-H (HSS.e A-H) == HSS.μ-... |
open import Categories
open import Monads
open import Level
import Monads.CatofAdj
module Monads.CatofAdj.TermAdjHom
{c d}
{C : Cat {c}{d}}
(M : Monad C)
(A : Cat.Obj (Monads.CatofAdj.CatofAdj M {c ⊔ d}{c ⊔ d})) where
open import Library
open import Functors
open import Adjunctions
open import Monads.EM M
o... |
{-# OPTIONS --without-K --rewriting #-}
open import lib.Base
open import lib.PathFunctor
open import lib.PathGroupoid
open import lib.Equivalence
{- Structural lemmas about paths over paths
The lemmas here have the form
[↓-something-in] : introduction rule for the something
[↓-something-out] : elimination rule for... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- The lifting of a strict order to incorporate a new supremum
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
-- This module is designed to be used with... |
module _ where
module A where
infix 2 _↑
infix 1 c
data D : Set where
● : D
_↑ : D → D
c : {x y : D} → D
syntax c {x = x} {y = y} = x ↓ y
module B where
infix 1 c
data D : Set where
c : {y x : D} → D
syntax c {y = y} {x = x} = y ↓ x
open A
open B
rejected : A.D
rejected = ● ↑ ↓... |
{-# OPTIONS --cubical --safe #-}
module Issue4949 where
open import Agda.Builtin.Cubical.Path
open import Agda.Primitive.Cubical renaming (primIMax to _∨_)
open import Agda.Builtin.Unit
open import Agda.Builtin.Sigma
open import Agda.Builtin.Cubical.Glue renaming (prim^glue to glue)
idIsEquiv : ∀ {ℓ} (A : Set ℓ) → i... |
-- Problem 4: ``50 shades of continuity''
{-
C(f) = ∀ c : X. Cat(f,c)
Cat(f,c) = ∀ ε > 0. ∃ δ > 0. Q(f,c,ε,δ)
Q(f,c,ε,δ) = ∀ x : X. abs(x - c) < δ ⇒ abs(f x - f c) < ε
C'(f) = ∃ getδ : X -> RPos -> RPos. ∀ c : X. ∀ ε > 0. Q(f,c,ε,getδ c ε)
4a: Define UC(f):
UC(f) = ∀ ε > 0. ∃ δ > 0. ∀ y : X.... |
-- {-# OPTIONS --show-implicit --show-irrelevant #-}
module Data.QuadTree.LensProofs.Valid-LensA where
open import Haskell.Prelude renaming (zero to Z; suc to S)
open import Data.Lens.Lens
open import Data.Logic
open import Data.QuadTree.InternalAgda
open import Agda.Primitive
open import Data.Lens.Proofs.LensLaws
ope... |
{- Byzantine Fault Tolerant Consensus Verification in Agda, version 0.9.
Copyright (c) 2021, Oracle and/or its affiliates.
Licensed under the Universal Permissive License v 1.0 as shown at https://opensource.oracle.com/licenses/upl
-}
open import LibraBFT.Base.Types
open import LibraBFT.Concrete.System
open imp... |
{- https://lists.chalmers.se/pipermail/agda/2013/006033.html http://code.haskell.org/~Saizan/unification/ 18-Nov-2013 Andrea Vezzosi -}
module UnifyProof2 where
open import Data.Fin using (Fin; suc; zero)
open import Data.Nat hiding (_≤_)
open import Relation.Binary.PropositionalEquality
open import Function
open impo... |
{-# OPTIONS --without-K #-}
module sets.fin.ordering where
open import equality.core
open import function.isomorphism
open import sets.core
open import sets.fin.core
open import sets.fin.properties
import sets.nat.ordering as N
_<_ : ∀ {n} → Fin n → Fin n → Set
i < j = toℕ i N.< toℕ j
infixr 4 _<_
ord-from-ℕ : ∀ {n}... |
module ComplexIMPORT where
{-# IMPORT Prelude as P #-}
|
module AmbiguousModule where
module A where
module B where
module A where
open B
open A
|
{-# OPTIONS --cubical --no-import-sorts --safe --guardedness #-}
module Cubical.Codata.Stream.Base where
open import Cubical.Core.Everything
record Stream (A : Type₀) : Type₀ where
coinductive
constructor _,_
field
head : A
tail : Stream A
|
module Pragmas where
-- Check that Haskell code is parsed with the correct language pragmas
{-# FOREIGN AGDA2HS
{-# LANGUAGE TupleSections #-}
{-# LANGUAGE LambdaCase #-}
#-}
{-# FOREIGN AGDA2HS
foo :: Bool -> a -> (a, Int)
foo = \ case
False -> (, 0)
True -> (, 1)
#-}
|
postulate
F : Set → Set
G : Set
G = {!F ?!}
-- KEEP COMMENTS AT THE END to not mess with the ranges in Issue2174.sh
-- Andreas, 2016-09-10, issue #2174 reported by Nisse
-- First infer, then give should goalify the questionmark
|
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Algebra.Group.Properties where
open import Cubical.Core.Everything
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv
open import Cubical.Foundations.Function using (id; flip)
open import Cubical.Foundations.Isomorphism
open i... |
------------------------------------------------------------------------
-- The syntax of the untyped λ-calculus
------------------------------------------------------------------------
{-# OPTIONS --safe #-}
module Lambda.Simplified.Syntax where
open import Equality.Propositional
open import Prelude
open import Ve... |
open import Formalization.PredicateLogic.Signature
module Formalization.PredicateLogic.Classical.Semantics.Homomorphism (𝔏 : Signature) where
open Signature(𝔏)
import Lvl
open import Data
open import Data.Boolean
open import Data.Boolean.Stmt
open import Data.ListSized
open import Data.ListSized.Functions
open... |
-- A module which re-exports Type.Category.ExtensionalFunctionsCategory as the default category for types, and defines some shorthand names for categorical stuff.
module Type.Category where
open import Functional
open import Function.Equals
open import Logic.Predicate
open import Relator.Equals.Proofs.Equiv
import ... |
module Lib.List where
open import Lib.Prelude
open import Lib.Id
infix 30 _∈_
infixr 40 _::_ _++_
infix 45 _!_
data List (A : Set) : Set where
[] : List A
_::_ : A -> List A -> List A
{-# COMPILED_DATA List [] [] (:) #-}
{-# BUILTIN LIST List #-}
{-# BUILTIN NIL [] #-}
{-# BUILTIN CONS _::_ #-}
_++_ : {A ... |
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Categories.NaturalTransformation where
open import Cubical.Categories.NaturalTransformation.Base public
open import Cubical.Categories.NaturalTransformation.Properties public
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- AVL trees
------------------------------------------------------------------------
-- AVL trees are balanced binary search trees.
-- The search tree invariant is specified using the technique
-- described by Co... |
{- Byzantine Fault Tolerant Consensus Verification in Agda, version 0.9.
Copyright (c) 2020, 2021, Oracle and/or its affiliates.
Licensed under the Universal Permissive License v 1.0 as shown at https://opensource.oracle.com/licenses/upl
-}
module Dijkstra.EitherLike where
open import Haskell.Prelude
open imp... |
open import Prelude
open import StateMachineModel
open StateMachine
open System
open import Relation.Nullary.Negation using (contradiction)
open import Relation.Binary.Core using (Tri)
module Behaviors
(State : Set)
(Event : Set)
(sys : System State Event)
(_∈Set?_ : (ev : Event) (evSet :... |
{-# OPTIONS --safe --warning=error --without-K #-}
open import LogicalFormulae
open import Agda.Primitive using (Level; lzero; lsuc; _⊔_)
open import Decidable.Sets
open import Lists.Lists
open import Numbers.Naturals.Semiring
module UnorderedSet.Definition {a : _} {V : Set a} (dec : DecidableSet V) where
data Unord... |
{-# OPTIONS --without-K --safe #-}
-- The Everything module of undecidability analysis
-- In Agda, we use first order de Bruijn indices to represent variables, that is, the
-- natural numbers.
module Everything where
-- Subtyping problems of all following calculi are undecidable. In this technical
-- work, our reduc... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Signs
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.Sign where
------------------------------------------------------------------------... |
-- We need to look at irrelevant variables in meta instantiation occurs check.
-- Here's why.
module Issue483 where
data _==_ {A : Set}(x : A) : A → Set where
refl : x == x
data ⊥ : Set where
resurrect : .⊥ → ⊥
resurrect ()
data D : Set where
c : (x : ⊥) → (.(y : ⊥) → x == resurrect y) → D
d : D
d = c _ (λ y →... |
data Greeting : Set where
hello : Greeting
greet : Greeting
greet = hello
|
-- Jesper, Andreas, 2018-10-29, issue #3332
--
-- WAS: With-inlining failed in termination checker
-- due to a DontCare protecting the clause bodies
-- (introduced by Prop).
{-# OPTIONS --prop #-}
open import Agda.Builtin.Equality
open import Agda.Builtin.List
postulate
A : Set
_++_ : List A → List A → List A
[] ... |
import Relation.Binary.PropositionalEquality as PE
module x01 where
import Data.Empty.Polymorphic as DEP
open import Data.Unit.Polymorphic
import Data.Maybe as Maybe
{-
Dependent Types at Work
Ana Bove and Peter Dybjer
Chalmers University of Technology, Göteborg, Sweden
intro to functional programming with depend... |
{-# OPTIONS --safe --warning=error #-}
open import Sets.EquivalenceRelations
open import Functions.Definition
open import Agda.Primitive using (Level; lzero; lsuc; _⊔_; Setω)
open import Setoids.Setoids
open import Groups.Definition
open import LogicalFormulae
open import Orders.WellFounded.Definition
open import Numb... |
-- Interface to standard library.
module Library where
open import Function public
hiding (_∋_)
open import Level public
using (Level) renaming (zero to lzero; suc to lsuc)
open import Size public
open import Category.Monad public
using (RawMonad; module RawMonad)
open import Data.Empty public
using (⊥; ⊥... |
{-# OPTIONS --cubical --safe #-}
module Cubical.Data.Universe.Base where
|
open import Data.Product renaming (_,_ to _,,_) -- just to avoid clash with other commas
open import Algebra.Structures using (IsSemigroup)
open import Algebra.FunctionProperties using (LeftIdentity; Commutative)
module Preliminaries where
Rel : Set -> Set₁
Rel A = A -> A -> Set
Entire : {A B : Set} ->... |
------------------------------------------------------------------------------
-- The division specification
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-... |
-- Andreas, 2016-06-11
postulate Foo : Foo → Set
|
----------------------------------------------------------------------------------
-- Types for parse trees
----------------------------------------------------------------------------------
module options-types where
open import ial
open import parse-tree
posinfo = string
alpha = string
alpha-bar-4 = string
alpha-r... |
module reductionSystems1 where
data ℕ : Set where
Z : ℕ
S : ℕ -> ℕ
_+_ : ℕ -> ℕ -> ℕ
n + Z = n
n + S m = S (n + m)
_*_ : ℕ -> ℕ -> ℕ
n * Z = Z
n * S m = (n * m) + n
{-
{-# BUILTIN NATURAL ℕ #-}
{-# BUILTIN ZERO Z #-}
{-# BUILTIN SUC S #-}
{-# BUILTIN NATPLUS _+_ #-}
{-# BUILTIN NATTIMES _*_... |
{-# OPTIONS --rewriting #-}
-- {-# OPTIONS --confluence-check #-}
-- Formulæ and hypotheses (contexts)
open import Library
module Formulas (Base : Set) where
-- Propositional formulas
data Form : Set where
Atom : (P : Base) → Form
True False : Form
_∨_ _∧_ _⇒_ : (A B : Form) → Form
infixl 8 _∧_
infixl 7 _∨_... |
module Categories.Monad.EilenbergMoore where
|
module Issue87 where
data I : Set where
data D : I -> Set where
d : forall {i} (x : D i) -> D i
bar : forall {i} -> D i -> D i -> D i
bar (d x) (d y) with y
bar (d x) (d {i} y) | z = d {i} y
-- Panic: unbound variable i
-- when checking that the expression i has type I
|
{-# OPTIONS --cubical #-}
module LookVsTime where
open import Data.Fin using (#_)
open import Data.Integer using (+_; -[1+_])
open import Data.List using (List; _∷_; []; map; concat; _++_; replicate; zip; length; take)
open import Data.Nat using (_*_; ℕ; suc; _+_)
open import Data.Product using (_,_; uncur... |
{-# OPTIONS --without-K #-}
open import Base
open import Homotopy.Pointed
open import Homotopy.Connected
module Homotopy.Cover {i} (A⋆ : pType i)
(A⋆-is-conn : is-connected⋆ ⟨0⟩ A⋆) where
open pType A⋆ renaming (∣_∣ to A ; ⋆ to a)
open import Homotopy.Cover.Def A
module Reconstruct where
open import Homotopy.Co... |
-- ----------------------------------------------------------------------
-- The Agda Descriptor Library
--
-- Natural transformations on indexed families (predicates)
-- ----------------------------------------------------------------------
module Relation.Unary.Predicate.Transformation where
open import Data.Empty... |
{-# OPTIONS --without-K #-}
module CauchyProofs where
-- Proofs about permutations defined in module Cauchy (everything
-- except the multiplicative ones which are defined in CauchyProofsT and
-- CauchyProofsS
open import Relation.Binary.PropositionalEquality
using (_≡_; refl; sym; trans; subst; subst₂; cong; con... |
-- Copyright 2019, Xuanrui Qi
-- Original algorithm by: Jacques Garrigue, Xuanrui Qi & Kazunari Tanaka
open import Data.Nat hiding (compare)
open import Data.Nat.Properties
open import Relation.Binary
import Relation.Binary.PropositionalEquality as Eq
open Eq using (_≡_; refl; subst; sym; inspect; [_])
open Eq.≡-Reason... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.