text stringlengths 4 690k |
|---|
{-# OPTIONS --without-K --safe #-}
open import Algebra.Structures.Bundles.Field
module Algebra.Linear.Construct.Vector
{k ℓ} (K : Field k ℓ)
where
open import Level using (_⊔_)
open import Data.Product using (_×_; _,_)
open import Data.Vec public hiding (sum)
import Data.Vec.Properties as VP
import Data.Vec.Rela... |
{-# OPTIONS --without-K #-}
open import lib.Base
module test.succeed.Test1 where
module _ where
private
data #I : Type₀ where
#zero : #I
#one : #I
I : Type₀
I = #I
zero : I
zero = #zero
one : I
one = #one
postulate
seg : zero == one
absurd : zero ≠ one
absurd ()
|
module ForallForParameters
(F : Set -> Set -> Set) X {Y} (Z : F X Y) where
data List A : Set where
[] : List A
_::_ : A -> List A -> List A
module M A {B} (C : F A B) where
data D : Set -> Set where
d : A -> D A
data P A : D A -> Set where
data Q {A} X : P A X -> Set where
module N I J K = ... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- Properties of homogeneous binary relations
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Relation.Binary where
-----------------------------... |
-- 2012-03-08 Andreas
module NoTerminationCheck2 where
{-# NON_TERMINATING #-}
data D : Set where
lam : (D -> D) -> D
-- error: works only for function definitions
|
module ModusPonens where
modusPonens : ∀ {P Q : Set} → (P → Q) → P → Q
modusPonens x = x
|
module Data.Var where
open import Data.List using (List; []; _∷_; map)
open import Data.List.Relation.Unary.All using (All; []; _∷_)
open import Function using (const; _∘_)
open import Level using (Level; 0ℓ)
open import Relation.Unary using (IUniversal; _⇒_; _⊢_)
-- -----------------------------------------------... |
{-# OPTIONS --cubical --safe #-}
module Data.Fin where
open import Data.Fin.Base public
|
-- notes-05-friday.agda
open import mylib
-- Π-types = dependent function types
Π : (A : Set)(B : A → Set) → Set
Π A B = (x : A) → B x
syntax Π A (λ x → P) = Π[ x ∈ A ] P
-- Σ-types = dependent pair type
record Σ(A : Set)(B : A → Set) : Set where
constructor _,_
field
proj₁ : A
proj₂ : B proj₁
open Σ... |
module PatternSynonymImports2 where
open import PatternSynonyms hiding (test)
open import PatternSynonymImports
myzero' = z
myzero'' = myzero
list2 : List _
list2 = 1 ∷ []
test : ℕ → ℕ
test myzero = 0
test sz = 1
test (ss x) = x
|
------------------------------------------------------------------------------
-- Sort a list
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-# OPTIONS --wit... |
{-# OPTIONS --without-K --safe #-}
open import Categories.Category
open import Categories.Category.Monoidal
open import Categories.Category.Monoidal.Closed
module Categories.Category.Monoidal.Closed.IsClosed
{o ℓ e} {C : Category o ℓ e} {M : Monoidal C} (Cl : Closed M) where
open import Data.Product using (Σ; _,_)... |
module Numeral.Natural.Relation.Proofs where
open import Data
open import Functional
open import Numeral.Natural
open import Numeral.Natural.Relation
open import Numeral.Natural.Relation.Order
open import Numeral.Natural.Relation.Order.Proofs
open import Logic.Propositional
open import Logic.Propositional.Theorems
imp... |
-- Isomorphism of indexed families
module SOAS.Families.Isomorphism {T} where
open import SOAS.Common
open import SOAS.Context {T}
open import SOAS.Families.Core {T}
open import Categories.Morphism 𝔽amilies public using ()
renaming ( _≅_ to _≅ₘ_ ; module ≅ to ≅ₘ ; ≅-setoid to ≅ₘ-setoid)
-- Isomorphism betw... |
module Numeral.Finite.Oper.Comparisons.Proofs where
import Lvl
open import Data
open import Data.Boolean
import Data.Boolean.Operators
open Data.Boolean.Operators.Programming
open import Logic.Propositional
open import Logic.Predicate
open import Numeral.Finite
open import Numeral.Finite.Oper.Comparis... |
module STLC.Term.Reduction where
open import STLC.Term as Term
open Term.Substitution using () renaming (_[/_] to _[/t_])
open import Data.Nat using (ℕ; _+_)
open import Relation.Binary.Construct.Closure.ReflexiveTransitive
using (Star)
infix 4 _—→_
data _—→_ { n : ℕ } : Term n -> Term n -> Set where
β-·₁... |
------------------------------------------------------------------------
-- The univalence axiom
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
-- Partly based on Voevodsky's work on so-called univalent
-- foundations.
open import Equality
module Univalen... |
{-# OPTIONS --without-K --rewriting #-}
module lib.groups.Groups where
open import lib.groups.CommutingSquare public
open import lib.groups.FreeAbelianGroup public
open import lib.groups.FreeGroup public
open import lib.groups.GroupProduct public
open import lib.groups.Homomorphism public
open import lib.groups.Homo... |
A : Set₁
A = Set
{-# POLARITY A #-}
|
{-# OPTIONS --without-K --safe --no-sized-types --no-guardedness
--no-subtyping #-}
module Agda.Builtin.Float where
open import Agda.Builtin.Bool
open import Agda.Builtin.Int
open import Agda.Builtin.Maybe
open import Agda.Builtin.Nat
open import Agda.Builtin.Sigma
open import Agda.Builtin.String
open imp... |
------------------------------------------------------------------------------
-- Testing the translation of definitions
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymor... |
module WarningOnUsage where
id : {A : Set} → A → A
id x = x
-- Deprecated names
λx→x = id
{-# WARNING_ON_USAGE λx→x "DEPRECATED: Use `id` instead of `λx→x`" #-}
open import Agda.Builtin.Equality
_ : {A : Set} {x : A} → λx→x x ≡ x
_ = refl
|
------------------------------------------------------------------------
-- The Agda standard library
--
-- Morphisms between algebraic structures
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Algebra.Morphism where
import Algebra.Morphism.Definiti... |
module Issue1760b where
-- Skipping an old-style mutual block: Somewhere within a `mutual`
-- block before a record definition.
mutual
data D : Set where
lam : (D → D) → D
{-# NO_POSITIVITY_CHECK #-}
record U : Set where
field ap : U → U
|
module Mutual2 where
data Bool
: Set
where
false
: Bool
true
: Bool
data ℕ
: Set
where
zero
: ℕ
suc
: ℕ
→ ℕ
is-even
: ℕ
→ Bool
is-odd
: ℕ
→ Bool
is-even zero
= true
is-even (suc n)
= is-odd n
is-odd zero
= false
is-odd (suc n)
= is-even n
is-even'
: ℕ
→... |
{-# OPTIONS --without-K --safe #-}
open import Level
-- Kan Complexes
--
-- These are technically "Algebraic" Kan Complexes, as they come with a choice of fillers
-- However, this notion is far easier than the more geometric flavor,
-- as we can sidestep questions about choice.
module Categories.Category.Constructi... |
import Lvl
open import Structure.Setoid
open import Type
module Automaton.Deterministic.Finite where
open import Automaton.Deterministic
open import Data.Boolean
open import Data.Boolean.Stmt
open import Data.List renaming (∅ to ε ; _⊰_ to _·_)
open import Data.List.Setoid
open import Data.List.Functions using (... |
-- Andreas, 2017-05-13, issue reported by nad
module Issue2579 where
open import Common.Bool
open import Issue2579.Import
import Issue2579.Instance Bool true as I
-- without the "as I" the instance is not in scope
-- (and you get a parse error)
theWrapped : {{w : Wrap Bool}} → Bool
theWrapped {{w}} = Wrap.wrapped w... |
{-# OPTIONS --universe-polymorphism #-}
module Issue248 where
open import Common.Level
data ⊥ : Set where
-- This type checks:
Foo : ⊥ → (l : Level) → Set
Foo x l with x
Foo x l | ()
-- This didn't (but now it does):
Bar : ⊥ → (l : Level) → Set l → Set
Bar x l A with x
Bar x l A | ()
-- Bug.agda:25,1-15
-- ⊥ !=... |
module Structure.Operator.Vector.LinearMaps where
open import Functional
open import Function.Proofs
open import Logic.Predicate
import Lvl
open import Structure.Function
open import Structure.Function.Multi
open import Structure.Operator.Properties
open import Structure.Operator.Vector.LinearMap
open import Stru... |
{-# OPTIONS --safe --warning=error --without-K #-}
open import LogicalFormulae
open import Setoids.Setoids
open import Rings.Definition
open import Numbers.Naturals.Semiring
open import Numbers.Naturals.Order
open import Modules.Definition
open import Vectors
open import Sets.EquivalenceRelations
open import Sets.FinS... |
{-# OPTIONS --rewriting #-}
module Properties.TypeCheck where
open import Agda.Builtin.Equality using (_≡_; refl)
open import Agda.Builtin.Bool using (Bool; true; false)
open import FFI.Data.Maybe using (Maybe; just; nothing)
open import FFI.Data.Either using (Either)
open import Luau.TypeCheck using (_⊢ᴱ_∈_; _⊢ᴮ_∈_;... |
open import Oscar.Prelude
open import Oscar.Data.¶
open import Oscar.Data.Descender
open import Oscar.Data.Fin
open import Oscar.Data.Term
module Oscar.Data.Substitist where
module Substitist {𝔭} (𝔓 : Ø 𝔭) where
open Term 𝔓
Substitist = flip Descender⟨ (λ n-o → Fin (↑ n-o) × Term n-o) ⟩
|
module Type where
open import Type.Core public
open import Type.NbE public
open import Type.Lemmas public
|
{-# OPTIONS --cubical --safe #-}
module Data.Sigma where
open import Data.Sigma.Base public
|
{-# OPTIONS --sized-types #-}
module SOList.Lower {A : Set}(_≤_ : A → A → Set) where
open import Data.List
open import Bound.Lower A
open import Bound.Lower.Order _≤_
open import Size
data SOList : {ι : Size} → Bound → Set where
onil : {ι : Size}{b : Bound}
→ SOList {↑ ι} b
:< : {ι : Size}{b ... |
{-# OPTIONS --cubical #-}
module Cubical.Categories.Type where
open import Cubical.Foundations.Prelude
open import Cubical.Categories.Category
module _ ℓ where
TYPE : Precategory (ℓ-suc ℓ) ℓ
TYPE .ob = Type ℓ
TYPE .hom A B = A → B
TYPE .idn A = λ x → x
TYPE .seq f g = λ x → g (f x)
TYPE .seq-λ f = refl
... |
{-# OPTIONS --without-K --rewriting #-}
open import HoTT
module homotopy.WedgeExtension
{i j} {A : Type i} {a₀ : A} {B : Type j} {b₀ : B} where
-- easier to keep track of than a long list of arguments
record args : Type (lmax (lsucc i) (lsucc j)) where
field
n m : ℕ₋₂
{{cA}} : is-connected (S n... |
{-
This file contains a proof of the following fact:
for a commutative ring R with elements f and g s.t.
⟨f,g⟩ = R, we get a get a pullback square
_/1
R ----> R[1/f]
⌟
_/1 | | χ₁
v v
R[1/g] -> R[1/fg]
χ... |
module IndexInference where
data Nat : Set where
zero : Nat
suc : Nat -> Nat
data Vec (A : Set) : Nat -> Set where
[] : Vec A zero
_::_ : {n : Nat} -> A -> Vec A n -> Vec A (suc n)
infixr 40 _::_
-- The length of the vector can be inferred from the pattern.
foo : Vec Nat _ -> Nat
foo (a :: b :: c :: [])... |
module ImplArg2 where
data Nat : Set where
zero : Nat
suc : Nat -> Nat
data Vec (A : Set) : Nat -> Set where
vnil : Vec A zero
vcons : {n : Nat} -> A -> Vec A n -> Vec A (suc n)
cons : {A : Set} (a : A) {n : Nat} -> Vec A n -> Vec A (suc n)
cons a = vcons a
|
------------------------------------------------------------------------------
-- First-order logic with equality
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #... |
open import Categories
open import Functors
open import RMonads
module RMonads.CatofRAdj.TermRAdjObj {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
open import RAdjunctions
open import RMonads.CatofRAdj M
open i... |
{-# OPTIONS --without-K #-}
open import function.extensionality.core
module hott.equivalence.alternative where
open import sum
open import equality.core
open import equality.calculus
open import function.core
open import function.extensionality.proof
open import function.isomorphism.core
open import function.isomorph... |
{-# OPTIONS --prop --safe #-}
open import Agda.Builtin.Equality
open import Agda.Builtin.Nat hiding (_<_)
data _<_ : Nat → Nat → Set where
zero-< : ∀ {n} → zero < suc n
suc-< : ∀ {m n} → m < n → suc m < suc n
record Acc (a : Nat) : Prop where
inductive
pattern
constructor acc
field acc< : (∀ b → b < a →... |
{-
This second-order equational theory was created from the following second-order syntax description:
syntax GroupAction | GA
type
* : 0-ary
X : 0-ary
term
unit : * | ε
add : * * -> * | _⊕_ l20
neg : * -> * | ⊖_ r40
act : * X -> X | _⊙_ r30
theory
(εU⊕ᴸ) a |> add (unit, a) = a
(εU⊕ᴿ) a |... |
-- A variant of code reported by Andreas Abel, due to Andreas Abel and
-- Nicolas Pouillard.
-- npouillard, 2011-10-04
{-# OPTIONS --guardedness --sized-types #-}
open import Common.Coinduction renaming (∞ to co)
open import Common.Size
data ⊥ : Set where
data Mu-co : Size → Set where
inn : ∀ {i} → co (Mu-co i) ... |
------------------------------------------------------------------------
-- Properties of functions, such as associativity and commutativity
------------------------------------------------------------------------
-- This file contains some core definitions which are reexported by
-- Algebra.FunctionProperties. They a... |
module sn-calculus-confluence.helper where
open import Data.List.All
open import Function
using (_∘_)
open import Data.List.Any using (Any ; here ; there)
open import Data.Nat using (_+_)
open import utility
open import Esterel.Lang
open import Esterel.Lang.Properties
open import Esterel.Environment as Env
open impo... |
module Fail.TupleType where
open import Haskell.Prelude
idT : ∀ {as} → Tuple as → Tuple as
idT x = x
{-# COMPILE AGDA2HS idT #-}
|
{-# OPTIONS --without-K --safe #-}
module Categories.Adjoint.Equivalents where
-- Theorems about equivalent formulations to Adjoint
-- (though some have caveats)
open import Level
open import Data.Product using (_,_; _×_)
open import Function using (_$_) renaming (_∘_ to _∙_)
open import Function.Equality using (Π; ... |
{-# OPTIONS --safe --warning=error --without-K #-}
open import LogicalFormulae
open import Groups.DirectSum.Definition
open import Setoids.Setoids
open import Rings.Definition
module Rings.DirectSum {a b c d : _} {A : Set a} {S : Setoid {a} {b} A} {_+1_ : A → A → A} {_*1_ : A → A → A} {C : Set c} {T : Setoid {c} {d}... |
{-# OPTIONS --without-K #-}
open import Prelude
import GSeTT.Typed-Syntax
import Globular-TT.Syntax
import Globular-TT.Rules
module Globular-TT.Globular-TT {l} (index : Set l) (rule : index → GSeTT.Typed-Syntax.Ctx × (Globular-TT.Syntax.Pre-Ty index))
(assumption : G... |
-- {-# OPTIONS -v interaction:50 #-}
x : Set → Set
x = {!λ x → x!}
-- "refine" (C-c C-r) should behave the same as "give" here
-- Old, bad result:
-- x = λ x₁ → x₁
-- New, expected result:
-- x = λ x → x
-- Expected interaction test case behavior:
--
-- (agda2-give-action 0 'no-paren)
|
module Luau.Type where
data Type : Set where
nil : Type
_⇒_ : Type → Type → Type
none : Type
any : Type
_∪_ : Type → Type → Type
_∩_ : Type → Type → Type
|
------------------------------------------------------------------------------
-- FOCT list terms properties
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-... |
module 030-semigroup where
-- We need equivalence.
open import 020-equivalence
-- Semigroups are basically a set with equality and some binary
-- operator which is associative and respects equality.
record SemiGroup
{M : Set}
(_==_ : M -> M -> Set)
(_*_ : M -> M -> M)
: Set1 where
field
equiv : Equiv... |
{-# OPTIONS --sized-types #-}
open import Relation.Binary.Core
module SOList.Total.Properties {A : Set}
(_≤_ : A → A → Set)
(trans≤ : Transitive _≤_) where
open import Bound.Total A
open import Bound.Total.Order _≤_
open import Bound.Total.Order.Properties _≤_ trans≤
open import List... |
module test.AddInteger where
open import Type
open import Declarative
open import Builtin
open import Builtin.Constant.Type
open import Builtin.Constant.Term Ctx⋆ Kind * # _⊢⋆_ con size⋆
open import Agda.Builtin.Sigma
-- zerepoch/zerepoch-core/test/data/addInteger.plc
addI : ∀{Γ} →
Γ ⊢ con integer (size⋆ 8) ⇒ con ... |
-- {-# OPTIONS -v tc.proj.like:10 #-} {-# OPTIONS -v tc.conv:10 #-}
import Common.Level
module ProjectionLikeAndModules1 (A : Set) (a : A) where
record ⊤ : Set where
constructor tt
data Wrap (W : Set) : Set where
wrap : W → Wrap W
data Bool : Set where
true false : Bool
-- `or' should be projection like in t... |
open import Everything
module Test.SurjidentityP where
module _
{𝔬₁} {𝔒₁ : Ø 𝔬₁}
{𝔯₁} (_∼₁_ : 𝔒₁ → 𝔒₁ → Ø 𝔯₁)
{𝔬₂} {𝔒₂ : Ø 𝔬₂}
{𝔯₂} (_∼₂_ : 𝔒₂ → 𝔒₂ → Ø 𝔯₂)
(_∼₂2_ : 𝔒₂ → 𝔒₂ → Ø 𝔯₂)
{𝔯₂'} (_∼₂'_ : 𝔒₂ → 𝔒₂ → Ø 𝔯₂')
{ℓ₂} (_∼̇₂_ : ∀ {x y} → x ∼₂ y → x ∼₂ y → Ø ℓ₂)
... |
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Algebra.Definitions where
open import Cubical.Core.Everything
open import Cubical.Relation.Binary
open import Cubical.Data.Sigma using (_×_)
open import Cubical.Data.Sum using (_⊎_)
open import Cubical.HITs.PropositionalTruncation using (∥_∥)
open impo... |
{-# OPTIONS --rewriting #-}
module Luau.Heap where
open import Agda.Builtin.Equality using (_≡_; refl)
open import FFI.Data.Maybe using (Maybe; just; nothing)
open import FFI.Data.Vector using (Vector; length; snoc; empty; lookup-snoc-not)
open import Luau.Addr using (Addr; _≡ᴬ_)
open import Luau.Var using (Var)
open... |
{-# OPTIONS --without-K #-}
open import lib.Basics
open import lib.types.Paths
open import lib.types.Pi
open import lib.types.Unit
open import lib.types.Nat
open import lib.types.TLevel
open import lib.types.Pointed
open import lib.types.Sigma
open import lib.NType2
open import lib.types.PathSeq
open import nicolai.p... |
module _ where
module M where
record S : Set₁ where
open M
field
F1 : Set
F2 : {!!}
|
{-# OPTIONS --without-K --no-pattern-matching #-}
module Ch2-9 where
open import Level hiding (lift)
open import Ch2-1
open import Ch2-2
open import Ch2-3
open import Ch2-4
open import Ch2-5
open import Ch2-6
open import Ch2-7
open import Ch2-8
open import Data.Product
open import Function using (id; _∘_)
-- happl... |
module Unique where
open import Category
module Uniq (ℂ : Cat) where
private open module C = Cat ℂ
-- We say that f ∈! P iff f is the unique arrow satisfying P.
data _∈!_ {A B : Obj}(f : A ─→ B)(P : A ─→ B -> Set) : Set where
unique : (forall g -> P g -> f == g) -> f ∈! P
itsUnique : {A B : Obj}{f : A... |
module MLib.Fin.Parts.Nat.Simple.Properties where
open import MLib.Prelude
open import MLib.Fin.Parts.Nat
import MLib.Fin.Parts.Nat.Simple as S
module P a b = Partsℕ (S.repl a b)
open Nat using (_*_; _+_; _<_)
open Fin using (toℕ; fromℕ≤)
open List
fromAny : ∀ a b → Any Fin (S.repl a b) → ℕ × ℕ
fromAny zero b ()
f... |
module Luau.Substitution where
open import Luau.Syntax using (Expr; Stat; Block; nil; addr; var; function_is_end; _$_; block_is_end; local_←_; _∙_; done; return; _⟨_⟩ ; name; fun; arg; number; binexp)
open import Luau.Value using (Value; val)
open import Luau.Var using (Var; _≡ⱽ_)
open import Properties.Dec using (Dec... |
{-# OPTIONS --without-K #-}
open import M-types.Base.Core
open import M-types.Base.Sum
open import M-types.Base.Prod
open import M-types.Base.Eq
module M-types.Base.Contr where
IsContr : ∏[ X ∈ Ty ℓ ] Ty ℓ
IsContr X = ∑[ x ∈ X ] ∏[ x′ ∈ X ] x′ ≡ x
Contr : Ty (ℓ-suc ℓ)
Contr {ℓ} = ∑[ X ∈ Ty ℓ ] IsCon... |
{-# OPTIONS --without-K #-}
module Model.Product where
open import Cats.Category
open import Data.Product using (<_,_>)
open import Model.Type.Core
open import Util.HoTT.HLevel
open import Util.Prelude hiding (_×_)
infixr 5 _×_
_×_ : ∀ {Γ} (T U : ⟦Type⟧ Γ) → ⟦Type⟧ Γ
T × U = record
{ ObjHSet = λ δ → T .ObjHSet ... |
{-
This file contains:
Properties of the FreeGroup:
- FreeGroup A is Set, SemiGroup, Monoid, Group
- Recursion principle for the FreeGroup
- Induction principle for the FreeGroup on hProps
- Condition for the equality of Group Homomorphisms from FreeGroup
- Equivalence of the types (A → Group .fst) (GroupHom (freeGro... |
-- Andreas, 2013-11-11 Better error for wrongly named implicit arg.
module Issue949 where
postulate
S : Set
F : {A : Set} → Set
ok : F {A = S}
err : F {B = S}
-- Old error:
--
-- Set should be a function type, but it isn't
-- when checking that {B = S} are valid arguments to a function of
-- type Set
--... |
open import Common.Prelude
open import Common.Reflect
module TermSplicingLooping where
mutual
f : Set -> Set
f = unquote (def (quote f) [])
|
module Lec1Start where
-- the -- mark introduces a "comment to end of line"
------------------------------------------------------------------------------
-- some basic "logical" types
------------------------------------------------------------------------------
data Zero : Set where
-- to give a value in a data... |
{-# OPTIONS --without-K --safe #-}
module Categories.Comonad.Relative where
open import Level
open import Categories.Category using (Category)
open import Categories.Functor using (Functor; Endofunctor; _∘F_) renaming (id to idF)
import Categories.Morphism.Reasoning as MR
open import Categories.NaturalTransformation ... |
-- This is an implementation of the equality type for Sets. Agda's
-- standard equality is more powerful. The main idea here is to
-- illustrate the equality type.
module Equality where
open import Level
-- The equality of two elements of type A. The type a ≡ b is a family
-- of types which captures the statement of e... |
{-# OPTIONS --copatterns --sized-types #-}
open import Level
open import Algebra.Structures
open import Relation.Binary
open import Algebra.FunctionProperties
module Comb (K : Set) (_≈_ : Rel K zero)
(_+_ _⋆_ : Op₂ K) (-_ : Op₁ K) (0# 1# : K)
(isRing : IsRing _≈_ _+_ _⋆_ -_ 0# 1#) where
open import... |
-- We apply the theory of quasi equivalence relations (QERs) to finite multisets and association lists.
{-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Relation.ZigZag.Applications.MultiSet where
open import Cubical.Core.Everything
open import Cubical.Foundations.Prelude
open import Cubical.Foundatio... |
{-# OPTIONS --warning=error #-}
{-# POLARITY F #-}
{-# POLARITY G #-}
|
------------------------------------------------------------------------
-- An alternative definition of equality
------------------------------------------------------------------------
module TotalParserCombinators.CoinductiveEquality where
open import Codata.Musical.Notation
open import Data.List
open import Data.... |
{-# OPTIONS --type-in-type --guardedness #-}
module IO.Instance where
open import Class.Monad using (Monad)
open import Class.Monad.IO
open import Class.Monoid
open import Data.Product
open import Data.Sum
open import IO
open import Monads.ExceptT
open import Monads.StateT
open import Monads.WriterT
open import Level... |
------------------------------------------------------------------------------
-- The FOTC lists type
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-# OPTIO... |
-- Andreas, 2012-10-18
module Issue481 where
as = Set
open import Common.Issue481ParametrizedModule as as -- as clause
open import Common.Issue481ParametrizedModule as as as -- as clause, duplicate def.
|
open import MLib.Algebra.PropertyCode
open import MLib.Algebra.PropertyCode.Structures
module MLib.Matrix.SemiTensor.Associativity {c ℓ} (struct : Struct bimonoidCode c ℓ) where
open import MLib.Prelude
open import MLib.Matrix.Core
open import MLib.Matrix.Equality struct
open import MLib.Matrix.Mul struct
open import... |
{-# OPTIONS -v interaction.case:65 #-}
data Bool : Set where
true false : Bool
test : Bool → Bool
test x = {!x!}
|
module CTL.Modalities where
open import CTL.Modalities.AF public
open import CTL.Modalities.AG public
open import CTL.Modalities.AN public
-- open import CTL.Modalities.AU public -- TODO Unfinished
open import CTL.Modalities.EF public
open import CTL.Modalities.EG public
open import CTL.Modalities.EN public
-- open im... |
{-# OPTIONS --safe --warning=error --without-K #-}
open import Agda.Primitive
module Basic where
data False : Set where
record True : Set where
data _||_ {a b : _} (A : Set a) (B : Set b) : Set (a ⊔ b) where
inl : A → A || B
inr : B → A || B
infix 1 _||_
|
------------------------------------------------------------------------
-- A formalisation of some definitions and laws from Section 3 of Ralf
-- Hinze's paper "Streams and Unique Fixed Points"
------------------------------------------------------------------------
module Hinze.Section3 where
open import Stream.Pro... |
------------------------------------------------------------------------
-- The one-sided Step function, used to define similarity and the
-- two-sided Step function
------------------------------------------------------------------------
{-# OPTIONS --sized-types #-}
open import Prelude
open import Labelled-transit... |
module Holes.Util where
open import Holes.Prelude
private
Rel : ∀ {a} → Set a → ∀ ℓ → Set (a ⊔ lsuc ℓ)
Rel A ℓ = A → A → Set ℓ
module CongSplit {ℓ x} {X : Set x} (_≈_ : Rel X ℓ) (reflexive : ∀ {x} → x ≈ x) where
two→one₁ : {_+_ : X → X → X}
→ (∀ {x x′ y y′} → x ≈ x′ → y ≈ y′ → (x + y) ≈ (x′ + y′))... |
{-# OPTIONS --without-K #-}
open import HoTT
open import homotopy.CircleHSpace
open import homotopy.LoopSpaceCircle
open import homotopy.Pi2HSusp
open import homotopy.IterSuspensionStable
-- This summerizes all [πₙ Sⁿ]
module homotopy.PinSn where
private
-- another way is to use path induction to prove the oth... |
open import MLib.Algebra.PropertyCode
open import MLib.Algebra.PropertyCode.Structures
module MLib.Matrix.Bimonoid {c ℓ} (struct : Struct bimonoidCode c ℓ) where
open import MLib.Prelude
open import MLib.Matrix.Core
open import MLib.Matrix.Equality struct
open import MLib.Matrix.Mul struct
open import MLib.Matrix.Plu... |
open import Common.Prelude
record IsNumber (A : Set) : Set where
field fromNat : Nat → A
open IsNumber {{...}} public
{-# BUILTIN FROMNAT fromNat #-}
instance
IsNumberNat : IsNumber Nat
IsNumberNat = record { fromNat = λ n → n }
record IsNegative (A : Set) : Set where
field fromNeg : Nat → A
open IsNegat... |
{-# OPTIONS --cubical #-}
module Cubical.Categories.Category where
open import Cubical.Foundations.Prelude
record Precategory ℓ ℓ' : Type (ℓ-suc (ℓ-max ℓ ℓ')) where
no-eta-equality
field
ob : Type ℓ
hom : ob → ob → Type ℓ'
idn : ∀ x → hom x x
seq : ∀ {x y z} (f : hom x y) (g : hom y z) → hom x z
... |
------------------------------------------------------------------------
-- Acyclic precedence graphs
------------------------------------------------------------------------
module Mixfix.Acyclic.PrecedenceGraph where
open import Data.List
open import Data.Product
open import Mixfix.Fixity
open import Mixfix.Operat... |
{-# OPTIONS --cubical --no-import-sorts --guardedness --safe #-}
module Cubical.Codata.M.AsLimit.helper where
open import Cubical.Foundations.Prelude
open import Cubical.Foundations.Equiv using (_≃_)
open import Cubical.Foundations.Function using (_∘_)
open import Cubical.Data.Unit
open import Cubical.Data.Prod
open... |
-- Andreas, 2016-07-13, issue reported by Mietek Bak
-- {-# OPTIONS -v tc.size:20 #-}
-- {-# OPTIONS -v tc.meta.assign:30 #-}
open import Agda.Builtin.Size
data Cx (U : Set) : Set where
⌀ : Cx U
_,_ : Cx U → U → Cx U
data _∈_ {U : Set} (A : U) : Cx U → Set where
top : ∀ {Γ} → A ∈ (Γ , A)
pop : ∀ {C Γ} → ... |
{-# OPTIONS --type-in-type #-}
module Data where
open import Prelude
data Sigma (A : Set)(B : A -> Set) : Set
data Sigma A B where
pair : (x : A) -> B x -> Sigma A B
fst : {A : _} {B : _} -> Sigma A B -> A
fst (pair x y) = x
snd : {A : _} {B : _} (p : Sigma A B) -> B (fst p)
snd (pair x y) = y
data Unit : Set
da... |
------------------------------------------------------------------------
-- The Agda standard library
--
-- The lifting of a strict order to incorporate new extrema
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
-- This module is designed to be used with
--... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.