id stringlengths 27 136 | text stringlengths 4 1.05M |
|---|---|
algebraic-stack_agda0000_doc_8528 | {-# OPTIONS --cubical --safe #-}
module Data.String where
open import Agda.Builtin.String using (String) public
open import Agda.Builtin.String
open import Agda.Builtin.String.Properties
open import Agda.Builtin.Char using (Char) public
open import Agda.Builtin.Char
open import Agda.Builtin.Char.Properties
open impor... |
algebraic-stack_agda0000_doc_8529 | -- Example usage of solver
{-# OPTIONS --without-K --safe #-}
open import Categories.Category
module Experiment.Categories.Solver.Category.Example
{o ℓ e} (𝒞 : Category o ℓ e) where
open import Experiment.Categories.Solver.Category 𝒞
open Category 𝒞
open HomReasoning
private
variable
A B C D E : Obj
m... |
algebraic-stack_agda0000_doc_8530 | ----------------------------------------------------------------
-- This file contains the definition of isomorphisms. --
----------------------------------------------------------------
module Category.Iso where
open import Category.Category
record Iso {l : Level}{ℂ : Cat {l}}{A B : Obj ℂ} (f : el (Hom ℂ A B... |
algebraic-stack_agda0000_doc_8531 | ------------------------------------------------------------------------
-- The Agda standard library
--
-- The Cowriter type and some operations
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe --sized-types #-}
module Codata.Cowriter where
open import Size
imp... |
algebraic-stack_agda0000_doc_8532 | module Dave.Algebra.Naturals.Bin where
open import Dave.Algebra.Naturals.Definition
open import Dave.Algebra.Naturals.Addition
open import Dave.Algebra.Naturals.Multiplication
open import Dave.Embedding
data Bin : Set where
⟨⟩ : Bin
_t : Bin → Bin
_f : Bin → Bin
inc : Bin → Bin
inc ⟨⟩ = ⟨⟩... |
algebraic-stack_agda0000_doc_8533 | open import ExtractSac as ES using ()
open import Extract (ES.kompile-fun)
open import Data.Nat as N using (ℕ; zero; suc; _≤_; _≥_; _<_; _>_; s≤s; z≤n; _∸_)
import Data.Nat.DivMod as N
open import Data.Nat.Properties as N
open import Data.List as L using (List; []; _∷_)
open import Data.Vec as V using (Vec; []; _... |
algebraic-stack_agda0000_doc_8534 | module Properties.Base where
open import Data.Maybe hiding (All)
open import Data.List
open import Data.List.All
open import Data.Product
open import Data.Sum
open import Relation.Nullary
open import Relation.Binary.PropositionalEquality
open import Typing
open import Global
open import Values
open import Session
op... |
algebraic-stack_agda0000_doc_8535 |
open import Oscar.Prelude
open import Oscar.Class.IsFunctor
open import Oscar.Class.Reflexivity
open import Oscar.Class.Smap
open import Oscar.Class.Surjection
open import Oscar.Class.Transitivity
module Oscar.Class.Functor where
record Functor 𝔬₁ 𝔯₁ ℓ₁ 𝔬₂ 𝔯₂ ℓ₂ : Ø ↑̂ (𝔬₁ ∙̂ 𝔯₁ ∙̂ ℓ₁ ∙̂ 𝔬₂ ∙̂ 𝔯₂ ∙̂ ℓ₂) wher... |
algebraic-stack_agda0000_doc_8536 | ------------------------------------------------------------------------
-- INCREMENTAL λ-CALCULUS
--
-- Overloading ⟦_⟧ notation
--
-- This module defines a general mechanism for overloading the
-- ⟦_⟧ notation, using Agda’s instance arguments.
------------------------------------------------------------------------
... |
algebraic-stack_agda0000_doc_8537 | {-# OPTIONS --allow-unsolved-metas #-}
module IsLiteralProblem where
open import OscarPrelude
open import IsLiteralSequent
open import Problem
record IsLiteralProblem (𝔓 : Problem) : Set
where
constructor _¶_
field
{problem} : Problem
isLiteralInferences : All IsLiteralSequent (inferences 𝔓)
isLite... |
algebraic-stack_agda0000_doc_8538 | module Pi-.Invariants where
open import Data.Empty
open import Data.Unit
open import Data.Sum
open import Data.Product
open import Relation.Binary.Core
open import Relation.Binary
open import Relation.Nullary
open import Relation.Binary.PropositionalEquality
open import Data.Nat
open import Data.Nat.Properties
open imp... |
algebraic-stack_agda0000_doc_8539 | ------------------------------------------------------------------------
-- Two logically equivalent axiomatisations of equality
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Equality where
open import Logical-equivalence hiding (id; _∘_)
open impo... |
algebraic-stack_agda0000_doc_8540 | {-# OPTIONS -v tc.conv.irr:50 #-}
-- {-# OPTIONS -v tc.lhs.unify:50 #-}
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 in... |
algebraic-stack_agda0000_doc_8541 | {-# OPTIONS --safe #-}
module Definition.Typed.Properties where
open import Definition.Untyped
open import Definition.Untyped.Properties
open import Definition.Typed
open import Definition.Typed.RedSteps
import Definition.Typed.Weakening as Twk
open import Tools.Empty using (⊥; ⊥-elim)
open import Tools.Product
ope... |
algebraic-stack_agda0000_doc_8542 | {-# OPTIONS --cubical --safe #-}
module Data.Nat.Properties where
open import Data.Nat.Base
open import Agda.Builtin.Nat using () renaming (_<_ to _<ᴮ_; _==_ to _≡ᴮ_) public
open import Prelude
open import Cubical.Data.Nat using (caseNat; injSuc) public
open import Data.Nat.DivMod
mutual
_-1⊔_ : ℕ → ℕ → ℕ
zero ... |
algebraic-stack_agda0000_doc_8543 | ------------------------------------------------------------------------
-- Paths and extensionality
------------------------------------------------------------------------
{-# OPTIONS --erased-cubical --safe #-}
module Equality.Path where
import Bijection
open import Equality hiding (module Derived-definitions-and... |
algebraic-stack_agda0000_doc_8512 | {-# OPTIONS --without-K #-}
open import lib.Basics
module lib.types.Sigma where
-- Cartesian product
_×_ : ∀ {i j} (A : Type i) (B : Type j) → Type (lmax i j)
A × B = Σ A (λ _ → B)
infixr 5 _×_
module _ {i j} {A : Type i} {B : A → Type j} where
pair : (a : A) (b : B a) → Σ A B
pair a b = (a , b)
-- pair= h... |
algebraic-stack_agda0000_doc_8513 | {-# OPTIONS --without-K --exact-split --safe #-}
module 06-universes where
import 05-identity-types
open 05-identity-types public
--------------------------------------------------------------------------------
-- Section 6.3 Observational equality on the natural numbers
-- Definition 6.3.1
Eq-ℕ : ℕ → ℕ → UU lzer... |
algebraic-stack_agda0000_doc_8514 | {-# OPTIONS --cubical --no-import-sorts --allow-unsolved-metas #-}
module Number.Instances.QuoQ.Definitions where
open import Agda.Primitive renaming (_⊔_ to ℓ-max; lsuc to ℓ-suc; lzero to ℓ-zero)
open import Cubical.Foundations.Everything renaming (_⁻¹ to _⁻¹ᵖ; assoc to ∙-assoc)
open import Cubical.Foundations.Logic... |
algebraic-stack_agda0000_doc_8515 | -- TODO: Generalize and move to Structure.Categorical.Proofs
module Structure.Category.Proofs where
import Lvl
open import Data
open import Data.Tuple as Tuple using (_,_)
open import Functional using (const ; swap ; _$_)
open import Lang.Instance
open import Logic
open import Logic.Propositional
open import Logi... |
algebraic-stack_agda0000_doc_8516 | module OscarEverything where
open import OscarPrelude
open import HasSubstantiveDischarge
|
algebraic-stack_agda0000_doc_8517 | {-# OPTIONS --cubical --safe #-}
module Cardinality.Finite.SplitEnumerable.Instances where
open import Cardinality.Finite.SplitEnumerable
open import Cardinality.Finite.SplitEnumerable.Inductive
open import Cardinality.Finite.ManifestBishop using (_|Π|_)
open import Data.Fin
open import Prelude
open import Data.List.... |
algebraic-stack_agda0000_doc_8518 | -- 2012-03-08 Andreas
module _ where
{-# TERMINATING #-}
-- error: misplaced pragma
|
algebraic-stack_agda0000_doc_8519 | -- Andreas, 2014-01-16, issue 1406
-- Agda with K again is inconsistent with classical logic
-- {-# OPTIONS --cubical-compatible #-}
open import Common.Level
open import Common.Prelude
open import Common.Equality
cast : {A B : Set} (p : A ≡ B) (a : A) → B
cast refl a = a
data HEq {α} {A : Set α} (a : A) : {B : Set ... |
algebraic-stack_agda0000_doc_8520 | {-# OPTIONS --cubical-compatible #-}
------------------------------------------------------------------------
-- Universe levels
------------------------------------------------------------------------
module Common.Level where
open import Agda.Primitive public using (Level; lzero; lsuc; _⊔_)
-- Lifting.
record Lif... |
algebraic-stack_agda0000_doc_8521 | {- 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
-}
{-# OPTIONS --allow-unsolved-metas #-}
-- This module provides some scaffoldi... |
algebraic-stack_agda0000_doc_8522 | module utm where
open import turing
open import Data.Product
-- open import Data.Bool
open import Data.List
open import Data.Nat
open import logic
data utmStates : Set where
reads : utmStates
read0 : utmStates
read1 : utmStates
read2 : utmStates
read3 : utmStates
read4 : utmStates
r... |
algebraic-stack_agda0000_doc_8523 | {-# OPTIONS --safe #-}
module Cubical.HITs.TypeQuotients where
open import Cubical.HITs.TypeQuotients.Base public
open import Cubical.HITs.TypeQuotients.Properties public
|
algebraic-stack_agda0000_doc_8524 |
data _≡_ {A : Set} (x : A) : A → Set where
refl : x ≡ x
cong : ∀ {A B : Set} (f : A → B) {x y : A} → x ≡ y → f x ≡ f y
cong f refl = refl
data ℕ : Set where
zero : ℕ
suc : ℕ → ℕ
data Fin : ℕ → Set where
zero : {n : ℕ} → Fin (suc n)
suc : {n : ℕ} (i : Fin n) → Fin (suc n)
data _≤_ : ℕ → ℕ → Set where
... |
algebraic-stack_agda0000_doc_8525 | {-# OPTIONS --no-positivity-check #-}
module IIRDg where
import LF
import DefinitionalEquality
import IIRD
open LF
open DefinitionalEquality
open IIRD
mutual
data Ug {I : Set}{D : I -> Set1}(γ : OPg I D) : I -> Set where
introg : (a : Gu γ (Ug γ) (Tg γ)) -> Ug γ (Gi γ (Ug γ) (Tg γ) a)
Tg : {I : Set}{D : I ... |
algebraic-stack_agda0000_doc_8526 |
module Oscar.Category.Setoid where
open import Oscar.Builtin.Objectevel
open import Oscar.Property
record IsSetoid {𝔬} {𝔒 : Ø 𝔬} {𝔮} (_≋_ : 𝑴 1 𝔒 𝔮) : Ø 𝔬 ∙̂ 𝔮 where
field
reflexivity : ∀ x → x ≋ x
symmetry : ∀ {x y} → x ≋ y → y ≋ x
transitivity : ∀ {x y} → x ≋ y → ∀ {z} → y ≋ z → x ≋ z
open ... |
algebraic-stack_agda0000_doc_8527 | module _ where
data Flat (A : Set) : Set where
flat : @♭ A → Flat A
-- the lambda cohesion annotation must match the domain.
into : {A : Set} → A → Flat A
into = λ (@♭ a) → flat a
|
algebraic-stack_agda0000_doc_16480 | {-# OPTIONS --safe #-}
open import Definition.Typed.EqualityRelation
module Definition.LogicalRelation.Substitution.Introductions.Pair {{eqrel : EqRelSet}} where
open EqRelSet {{...}}
open import Definition.Untyped as U hiding (wk)
open import Definition.Untyped.Properties
open import Definition.Typed
open import De... |
algebraic-stack_agda0000_doc_16481 | {-# OPTIONS --without-K #-}
open import lib.Basics
open import lib.types.Lift
open import lib.types.Paths
open import lib.types.Pointed
module lib.types.Unit where
tt = unit
⊙Unit : Ptd₀
⊙Unit = ⊙[ Unit , unit ]
abstract
-- Unit is contractible
Unit-is-contr : is-contr Unit
Unit-is-contr = (unit , λ y → idp)... |
algebraic-stack_agda0000_doc_16482 |
module _ where
-- Should not be able to give by name
id : {_ = A : Set} → A → A
id x = x
works : (X : Set) → X → X
works X = id {X}
fails : (X : Set) → X → X
fails X = id {A = X}
|
algebraic-stack_agda0000_doc_16483 | module Text.Greek.SBLGNT.2Pet where
open import Data.List
open import Text.Greek.Bible
open import Text.Greek.Script
open import Text.Greek.Script.Unicode
ΠΕΤΡΟΥ-Β : List (Word)
ΠΕΤΡΟΥ-Β =
word (Σ ∷ υ ∷ μ ∷ ε ∷ ὼ ∷ ν ∷ []) "2Pet.1.1"
∷ word (Π ∷ έ ∷ τ ∷ ρ ∷ ο ∷ ς ∷ []) "2Pet.1.1"
∷ word (δ ∷ ο ∷ ῦ ∷ ∙λ ∷ ο ∷ ... |
algebraic-stack_agda0000_doc_16484 |
module Chain
{ A : Set }
(_==_ : A -> A -> Set )
(refl : (x : A) -> x == x)
(trans : (x y z : A) -> x == y -> y == z -> x == z)
where
infix 2 chain>_
infixl 2 _===_
infix 3 _by_
chain>_ : (x : A) -> x == x
chain> x = refl _
_===_ : {x y z : A} -> x == y -> y == z -> x == z
xy === y... |
algebraic-stack_agda0000_doc_16485 | {-# OPTIONS --without-K --safe #-}
open import Algebra.Construct.DirectProduct
module Construct.DirectProduct where
open import Algebra.Bundles
import Algebra.Construct.DirectProduct as DirectProduct
open import Data.Product
open import Data.Product.Relation.Binary.Pointwise.NonDependent
open import Level using (Lev... |
algebraic-stack_agda0000_doc_16486 | ------------------------------------------------------------------------
-- The Agda standard library
--
-- Core lemmas for division and modulus operations
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Data.Nat.DivMod.Core where
open import Agda.Bu... |
algebraic-stack_agda0000_doc_16487 |
open import SOAS.Metatheory.Syntax
-- Metasubstitution operation
module SOAS.Metatheory.SecondOrder.Metasubstitution {T : Set}(Syn : Syntax {T}) where
open Syntax Syn
open import SOAS.Metatheory.FreeMonoid Syn
open import SOAS.Common
open import SOAS.Families.Core {T}
open import SOAS.Families.Build
open import SO... |
algebraic-stack_agda0000_doc_16488 | -- Andreas, 2016-10-11, AIM XXIV, issue #2248
-- COMPILED_TYPE should only work on postulates
data Unit : Set where
unit : Unit
abstract
IO : Set → Set
IO A = A
doNothing : IO Unit
doNothing = unit
{-# COMPILED_TYPE IO IO #-}
main : IO unit
main = doNothing
|
algebraic-stack_agda0000_doc_16489 | -- an example showing how to use sigma types to define a type for non-zero natural numbers
module nat-nonzero where
open import bool
open import eq
open import nat
open import nat-thms
open import product
ℕ⁺ : Set
ℕ⁺ = Σ ℕ (λ n → iszero n ≡ ff)
suc⁺ : ℕ⁺ → ℕ⁺
suc⁺ (x , p) = (suc x , refl)
_+⁺_ : ℕ⁺ → ℕ⁺ → ℕ⁺
(x , ... |
algebraic-stack_agda0000_doc_16490 | {-# OPTIONS --safe #-}
module Definition.Typed.Consequences.Inequality where
open import Definition.Untyped hiding (U≢ℕ; U≢Π; U≢ne; ℕ≢Π; ℕ≢ne; Π≢ne; U≢Empty; ℕ≢Empty; Empty≢Π; Empty≢ne)
open import Definition.Typed
open import Definition.Typed.Properties
open import Definition.Typed.EqRelInstance
open import Definiti... |
algebraic-stack_agda0000_doc_16491 | {-
This file contains:
- Definitions equivalences
- Glue types
-}
{-# OPTIONS --cubical --safe #-}
module Cubical.Core.Glue where
open import Cubical.Core.Primitives
open import Agda.Builtin.Cubical.Glue public
using ( isEquiv -- ∀ {ℓ ℓ'} {A : Type ℓ} {B : Type ℓ'} (f : A → B) → Type (ℓ ⊔ ℓ')
; e... |
algebraic-stack_agda0000_doc_16492 |
-- This module explains how to combine elimination of empty types with pattern
-- match style definitions without running into problems with decidability.
module Introduction.Data.Empty where
-- First we introduce an empty and a singleton type.
data Zero : Set where
data One : Set where
one : One
-- There is a s... |
algebraic-stack_agda0000_doc_16493 | {-# OPTIONS --type-in-type #-}
Ty : Set
Ty =
(Ty : Set)
(nat top bot : Ty)
(arr prod sum : Ty → Ty → Ty)
→ Ty
nat : Ty; nat = λ _ nat _ _ _ _ _ → nat
top : Ty; top = λ _ _ top _ _ _ _ → top
bot : Ty; bot = λ _ _ _ bot _ _ _ → bot
arr : Ty → Ty → Ty; arr
= λ A B Ty nat top bot arr prod sum →
... |
algebraic-stack_agda0000_doc_16494 | {-# OPTIONS --without-K #-}
open import Base
open import Spaces.Interval
module Spaces.IntervalProps where
bool-split : bool {zero} → Set
bool-split true = unit
bool-split false = ⊥
-- If [bool] is contractible, then [true ≡ false]
bool-contr-path : is-contr (bool {zero}) → true ≡ false
bool-contr-path (x , f) = (f... |
algebraic-stack_agda0000_doc_16495 | -- Giving /lift \phi/ the the first hole TWICE (the first time you get an type error), causes the following internal error:
-- An internal error has occurred. Please report this as a bug.
-- Location of the error:
-- src/full/Agda/TypeChecking/Reduce/Monad.hs:118
------------------------------------------------... |
algebraic-stack_agda0000_doc_16464 | {-# OPTIONS --safe #-}
postulate F : Set → Set
{-# POLARITY F ++ #-}
|
algebraic-stack_agda0000_doc_16465 | {-# OPTIONS --no-termination-check #-}
module Data.Bin.DivModTests where
open import Data.Bin.DivMod
open Everything using (BinFin; _divMod_; result)
open import IO
open import Data.Bin hiding (suc; fromℕ)
open import Data.String hiding (_≟_)
open import Data.Unit hiding (_≟_)
open import Coinduction
open import Data... |
algebraic-stack_agda0000_doc_16466 | open import Nat
open import Prelude
open import List
open import judgemental-erase
open import statics-checks
open import statics-core
module constructability where
-- we construct expressions and types by induction on their
-- structure. for each sub term, we call the relevant theorem, then
-- assemble the resu... |
algebraic-stack_agda0000_doc_16467 | -- Andreas, 2017-01-12, issue #2386
postulate
B : Set
data _≡_ {A B : Set} (x : A) : A → Set where
refl : (b : B) → x ≡ x
{-# BUILTIN EQUALITY _≡_ #-}
-- Wrong type of _≡_
|
algebraic-stack_agda0000_doc_16468 | open import Prelude
module Implicits.Substitutions.Context where
open import Implicits.Syntax.Type
open import Implicits.Syntax.Context
open import Implicits.Substitutions.Type as TS using ()
open import Data.Fin.Substitution
open import Data.Star as Star hiding (map)
open import Data.Star.Properties
open import Dat... |
algebraic-stack_agda0000_doc_16469 | {-# OPTIONS --without-K --rewriting #-}
open import lib.Basics
open import lib.cubical.Square
open import lib.types.Group
open import lib.types.EilenbergMacLane1.Core
module lib.types.EilenbergMacLane1.PathElim where
module _ {i} (G : Group i) where
private
module G = Group G
module EM₁Level₂PathElim {k} {... |
algebraic-stack_agda0000_doc_16470 |
postulate
ANY : ∀{a}{A : Set a} → A
data Ty : Set where
_⇒_ : (a b : Ty) → Ty
data Tm : (b : Ty) → Set where
S : ∀{c a b} → Tm ((c ⇒ (a ⇒ b)) ⇒ ((c ⇒ a) ⇒ (c ⇒ b)))
_∙_ : ∀{a b} (t : Tm (a ⇒ b)) (u : Tm a) → Tm b
data _↦_ : ∀{a} (t t' : Tm a) → Set where
↦S : ∀{c a b} {t : Tm (c ⇒ (a ⇒ b))} {u : Tm (c ... |
algebraic-stack_agda0000_doc_16471 |
-- The error on Agda 2.5.3 was:
-- An internal error has occurred. Please report this as a bug.
-- Location of the error: src/full/Agda/TypeChecking/Substitute/Class.hs:209
open import Agda.Primitive using (_⊔_ ; Level ; lsuc)
record Unit {U : Level} : Set U where
-- error still occurs with no constructors or fields... |
algebraic-stack_agda0000_doc_16472 | {- 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
-}
{-# OPTIONS --allow-unsolved-metas #-}
-- This module proves the two "V... |
algebraic-stack_agda0000_doc_16473 | open import Data.Product using ( _,_ )
open import Data.Sum using ( inj₁ ; inj₂ )
open import Web.Semantic.DL.ABox.Interp using ( _*_ )
open import Web.Semantic.DL.ABox.Model using ( *-resp-⟨ABox⟩ )
open import Web.Semantic.DL.Category.Object using ( Object ; iface )
open import Web.Semantic.DL.Category.Morphism using ... |
algebraic-stack_agda0000_doc_16474 | module Algebra.LabelledGraph where
open import Algebra.Dioid
-- Core graph construction primitives
data LabelledGraph {D eq} (d : Dioid D eq) (A : Set) : Set where
ε : LabelledGraph d A -- Empty graph
v : A -> LabelledGraph d A -- Graph comprising a single vertex
_[_]>_ : LabelledGraph d A -> D -... |
algebraic-stack_agda0000_doc_16475 | open import Agda.Builtin.Bool
works : Bool → Bool
works b with b | true
... | b′ | _ = b′
fails : Bool → Bool
fails b with b′ ← b | true
... | _ = b′
|
algebraic-stack_agda0000_doc_16476 | module CS410-Functor where
open import CS410-Prelude
record Functor (T : Set -> Set) : Set1 where
field
-- OPERATIONS ----------------------------------------------
map : forall {X Y} -> (X -> Y) -> T X -> T Y
-- LAWS ----------------------------------------------------
mapid : forall {X}(x : ... |
algebraic-stack_agda0000_doc_16477 | module DualTail1 where
open import Data.Nat
open import Data.Fin using (Fin; zero; suc)
open import Data.Product
open import Function using (id; _∘_)
open import Relation.Binary.PropositionalEquality using (_≡_; refl)
open import Types.Direction
open import Types.IND1 as IND hiding (GType; Type; SType; _≈_; _≈'_)
... |
algebraic-stack_agda0000_doc_16478 | open import Data.Nat
open import Data.Nat.Show
open import IO
module Ackermann where
ack : ℕ -> ℕ -> ℕ
ack zero n = n + 1
ack (suc m) zero = ack m 1
ack (suc m) (suc n) = ack m (ack (suc m) n)
main = run (putStrLn (show (ack 3 9)))
|
algebraic-stack_agda0000_doc_16479 | {-# OPTIONS --type-in-type #-}
module CS410-Categories where
open import CS410-Prelude
postulate
extensionality : {S : Set}{T : S -> Set}
{f g : (x : S) -> T x} ->
((x : S) -> f x == g x) ->
f == g
imp : {S : Set}{T : S -> Set}(f : (x : S) -> T x){x : S} -> ... |
algebraic-stack_agda0000_doc_16848 |
-- Linear monoidal closed structure for families
module SOAS.Families.Linear {T : Set} where
open import SOAS.Common
open import SOAS.Context {T}
open import SOAS.Sorting {T}
open import SOAS.Families.Core {T}
open import SOAS.Families.Isomorphism {T}
open import Categories.Category.Monoidal
open import Categories.... |
algebraic-stack_agda0000_doc_16849 | open import Nat
open import Prelude
open import contexts
module core where
-- types
data htyp : Set where
b : htyp
⦇-⦈ : htyp
_==>_ : htyp → htyp → htyp
-- arrow type constructors bind very tightly
infixr 25 _==>_
-- external expressions
data hexp : Set where
c : hexp
_·... |
algebraic-stack_agda0000_doc_16850 | {-# OPTIONS --rewriting #-}
module Luau.TypeCheck where
open import Agda.Builtin.Equality using (_≡_)
open import FFI.Data.Maybe using (Maybe; just)
open import Luau.Syntax using (Expr; Stat; Block; BinaryOperator; yes; nil; addr; number; bool; string; val; var; var_∈_; _⟨_⟩∈_; function_is_end; _$_; block_is_end; bin... |
algebraic-stack_agda0000_doc_16851 | module Pi.Syntax where
open import Data.Empty
open import Data.Unit
open import Data.Sum
open import Data.Product
infixr 12 _×ᵤ_
infixr 11 _+ᵤ_
infixr 50 _⨾_
infixr 10 _↔_
infix 99 !_
-- Types
data 𝕌 : Set where
𝟘 : 𝕌
𝟙 : 𝕌
_+ᵤ_ : 𝕌 → 𝕌 → 𝕌
_×ᵤ_ : 𝕌 → 𝕌 → 𝕌
⟦_⟧ : (A : 𝕌) → Set
... |
algebraic-stack_agda0000_doc_16852 | module Automata.Nondeterministic where
-- Standard libraries imports ----------------------------------------
open import Level using ()
renaming (zero to ℓ₀)
open import Data.Nat using (ℕ)
open import Data.Product using (_×_)
open import Data.Vec using (Vec ; [] ; _∷_)
open import Relation.Unary using (Pred)
open... |
algebraic-stack_agda0000_doc_16853 | module ByteCount where
open import Agda.Builtin.Word
{-# FOREIGN GHC import Foreign.C.Types #-}
postulate
CSize : Set
mkCSize : Word64 → CSize
{-# COMPILE GHC CSize = type CSize #-}
{-# COMPILE GHC mkCSize = CSize #-}
ByteCount : Set
ByteCount = CSize
|
algebraic-stack_agda0000_doc_16854 | ------------------------------------------------------------------------
-- Primitive IO: simple bindings to Haskell types and functions
------------------------------------------------------------------------
module IO.Primitive where
open import Data.String hiding (Costring)
open import Data.Char
open import Foreig... |
algebraic-stack_agda0000_doc_16855 | {-# OPTIONS --cubical -van-extra-option-just-to-test-a-hack:0 #-}
|
algebraic-stack_agda0000_doc_16856 | open import Function using (_$_)
open import Relation.Nullary using (yes; no)
open import Relation.Binary using (Decidable; Irrelevant; Antisymmetric; Setoid)
open import AKS.Algebra.Bundles using (NonZeroCommutativeRing; Field)
module AKS.Algebra.Consequences {c ℓ} (R : NonZeroCommutativeRing c ℓ) where
open import... |
algebraic-stack_agda0000_doc_16857 | ------------------------------------------------------------------------------
-- Natural numbers (PCF version)
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}... |
algebraic-stack_agda0000_doc_16858 | {-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism #-}
{-# OPTIONS --without-K #-}
module CombiningProofs.Erasing where
postulate
D : Set
succ₁ : D → D
data N : D → Set where
nsucc₁ : ∀ {n} → N n → N (succ₁ n)
nsucc₂... |
algebraic-stack_agda0000_doc_16859 | {-# OPTIONS --safe --warning=error --without-K #-}
open import LogicalFormulae
open import Functions.Definition
open import Numbers.Naturals.Semiring
open import Numbers.Naturals.Order
open import Numbers.Naturals.Order.WellFounded
open import Semirings.Definition
open import Orders.Total.Definition
open import Order... |
algebraic-stack_agda0000_doc_16860 |
module Basic.Axiomatic.Partial where
open import Data.Bool hiding (not; if_then_else_; _∧_)
open import Data.Vec hiding ([_]; _++_; split)
open import Function
open import Relation.Binary.PropositionalEquality
open import Data.Product
import Level as L
open import Utils.Decidable
open import Basic.AST
open imp... |
algebraic-stack_agda0000_doc_16861 | {-# OPTIONS --without-K --safe #-}
module Categories.Category.Construction.LT-Models where
-- Given a fixed Lawvere Theory LT and a fixed category C,
-- the Functors [LT , C] form a category.
-- The proof is basically the same as that of Functors.
open import Level
open import Categories.Category.Core using (Catego... |
algebraic-stack_agda0000_doc_16862 | module Auto-Modules where
open import Auto.Prelude hiding (cong; trans)
module NonemptySet (X : Set) (x : X) where
h0 : (P : X → Set) → (∀ x → P x) → Σ X P
h0 = {!!}
-- h0 = λ P h → Σ-i x (h x)
module WithRAA (RAA : ∀ A → ¬ (¬ A) → A) where
h1 : ∀ A → A ∨ ¬ A
h1 = {!!}
--h1 = λ A → RAA (A ∨ ((x : A) → ⊥)) (λ z... |
algebraic-stack_agda0000_doc_16863 |
module Base where
data True : Set where
T : True
data False : Set where
infix 20 _*_
data _*_ (A : Set)(B : A -> Set) : Set where
<_,_> : (x : A) -> B x -> A * B
rel : Set -> Set1
rel A = A -> A -> Set
pred : Set -> Set1
pred A = A -> Set
Refl : {A : Set} -> rel A -> Set
Refl {A} R = {x : A} -> R x x
Sym... |
algebraic-stack_agda0000_doc_8944 | {-# OPTIONS --without-K #-}
open import HoTT.Base
open import HoTT.Equivalence
module HoTT.Identity.Universe {i} {A B : 𝒰 i} where
-- Axiom 2.10.3 - univalence
postulate
idtoeqv-equiv : isequiv (idtoeqv {A = A} {B = B})
=𝒰-equiv : (A == B) ≃ (A ≃ B)
=𝒰-equiv = idtoeqv , idtoeqv-equiv
module _ where
open qinv... |
algebraic-stack_agda0000_doc_8945 | module hott.types.int where
open import hott.functions
open import hott.core
import hott.types.nat as nat
open nat using (ℕ)
data ℤ : Type₀ where
zero : ℤ
+ve : ℕ → ℤ
-ve : ℕ → ℤ
fromNat : ℕ → ℤ
fromNat nat.zero = zero
fromNat (nat.succ n) = +ve n
neg : ℤ → ℤ
neg zero = zero
neg (+ve n) = -ve n
neg (-ve n... |
algebraic-stack_agda0000_doc_8946 | ------------------------------------------------------------------------
-- Second-order abstract syntax
--
-- Examples of the formalisation framework in use
------------------------------------------------------------------------
module Examples where
-- | Algebraic structures
-- Monoids
import Monoid.Signature
im... |
algebraic-stack_agda0000_doc_8947 | {-# OPTIONS --without-K --safe #-}
module Experiment.Zero where
open import Level using (_⊔_)
-- Empty type
data ⊥ : Set where
-- Unit type
record ⊤ : Set where
constructor tt
-- Boolean
data Bool : Set where
true false : Bool
-- Natural number
data ℕ : Set where
zero : ℕ
suc : ℕ → ℕ
-- Propositional Eq... |
algebraic-stack_agda0000_doc_8948 | {-# OPTIONS --without-K --safe #-}
module Dodo.Binary.Intersection where
-- Stdlib imports
open import Level using (Level; _⊔_)
open import Data.Product as P
open import Data.Product using (_×_; _,_; swap; proj₁; proj₂)
open import Relation.Binary using (REL)
-- Local imports
open import Dodo.Binary.Equality
-- # D... |
algebraic-stack_agda0000_doc_8949 | -- Andreas, 2015-12-10, issue reported by Andrea Vezzosi
open import Common.Equality
open import Common.Bool
id : Bool → Bool
id true = true
id false = false
is-id : ∀ x → x ≡ id x
is-id true = refl
is-id false = refl
postulate
P : Bool → Set
b : Bool
p : P (id b)
proof : P b
proof rewrite is-id b = p
|
algebraic-stack_agda0000_doc_8950 | module Selective where
open import Prelude.Equality
open import Agda.Builtin.TrustMe
-----------------------------------------------------------------
-- id : ∀ {a} {A : Set a} → A → A
-- id x = x
id : ∀ {A : Set} → A → A
id x = x
{-# INLINE id #-}
infixl -10 id
syntax id {A = A} x = x ofType A
const : ∀ {a b} {A ... |
algebraic-stack_agda0000_doc_8951 | module SizedIO.ConsoleObject where
open import Size
open import SizedIO.Console
open import SizedIO.Object
open import SizedIO.IOObject
-- A console object is an IO object for the IO interface of console
ConsoleObject : (i : Size) → (iface : Interface) → Set
ConsoleObject i iface = IOObject consoleI iface i
|
algebraic-stack_agda0000_doc_8952 | module Acc where
data Rel(A : Set) : Set1 where
rel : (A -> A -> Set) -> Rel A
_is_than_ : {A : Set} -> A -> Rel A -> A -> Set
x is rel f than y = f x y
data Acc {A : Set} (less : Rel A) (x : A) : Set where
acc : ((y : A) -> x is less than y -> Acc less y) -> Acc less x
data WO {A : Set} (less : Rel A) : Set w... |
algebraic-stack_agda0000_doc_8953 | {-# OPTIONS --cumulativity #-}
open import Agda.Builtin.Equality
mutual
X : Set
X = _
Y : Set₁
Y = Set
test : _≡_ {A = Set₁} X Y
test = refl
|
algebraic-stack_agda0000_doc_8954 | ------------------------------------------------------------------------
-- Potentially cyclic precedence graphs
------------------------------------------------------------------------
module Mixfix.Cyclic.PrecedenceGraph where
open import Data.Fin using (Fin)
open import Data.Nat using (ℕ)
open import Data.Vec as V... |
algebraic-stack_agda0000_doc_8955 | ------------------------------------------------------------------------
-- This module establishes that the recognisers are as expressive as
-- possible when the alphabet is Bool (this could be generalised to
-- arbitrary finite alphabets), whereas this is not the case when the
-- alphabet is ℕ
-----------------------... |
algebraic-stack_agda0000_doc_8956 | module Lemmachine.Spike where
open import Data.Fin
open import Data.Digit
-- 3.9 Quality Values
DIGIT = Decimal
data qvalue : DIGIT → DIGIT → DIGIT → Set where
zero : (d₁ d₂ d₃ : DIGIT) → qvalue d₁ d₂ d₃
one : qvalue zero zero zero
|
algebraic-stack_agda0000_doc_8957 | {-# OPTIONS --cubical --no-import-sorts --safe #-}
module Cubical.Categories.Commutativity where
open import Cubical.Foundations.Prelude
open import Cubical.Categories.Category
private
variable
ℓ ℓ' : Level
module _ {C : Precategory ℓ ℓ'} where
open Precategory C
compSq : ∀ {x y z w u v} {f : C [ x , y ]... |
algebraic-stack_agda0000_doc_8958 | ------------------------------------------------------------------------
-- The Agda standard library
--
-- Lexicographic induction
------------------------------------------------------------------------
{-# OPTIONS --without-K --safe #-}
module Induction.Lexicographic where
open import Data.Product
open import Ind... |
algebraic-stack_agda0000_doc_8959 | {-
This file contains:
- Fibers of induced map between set truncations is the set truncation of fibers
modulo a certain equivalence relation defined by π₁ of the base.
-}
{-# OPTIONS --safe #-}
module Cubical.HITs.SetTruncation.Fibers where
open import Cubical.HITs.SetTruncation.Base
open import Cubical.Foundati... |
algebraic-stack_agda0000_doc_17408 | {-# OPTIONS --without-K --safe #-}
module Definition.Conversion.Consequences.Completeness where
open import Definition.Untyped
open import Definition.Typed
open import Definition.Conversion
open import Definition.Conversion.EqRelInstance
open import Definition.LogicalRelation
open import Definition.LogicalRelation.S... |
algebraic-stack_agda0000_doc_17409 | ------------------------------------------------------------------------------
-- All the Peano arithmetic modules
------------------------------------------------------------------------------
{-# OPTIONS --exact-split #-}
{-# OPTIONS --no-sized-types #-}
{-# OPTIONS --no-universe-polymorphism ... |
algebraic-stack_agda0000_doc_17410 | module Computability.Data.Fin.Opposite where
open import Computability.Prelude
open import Data.Nat using (_≤_; _<_; s≤s; z≤n)
open import Data.Nat.Properties using (≤-step)
open import Data.Fin using (Fin; zero; suc; inject₁; fromℕ; fromℕ<; toℕ; opposite)
opposite-fromℕ : ∀ k → opposite (fromℕ k) ≡ zero
opposite-fro... |
algebraic-stack_agda0000_doc_17411 | module Type.Properties.Decidable.Proofs where
open import Data
open import Data.Proofs
open import Data.Boolean using (if_then_else_)
open import Data.Boolean.Stmt
open import Data.Either as Either using (_‖_)
open import Data.Tuple as Tuple using (_⨯_ ; _,_)
open import Functional
import Lvl
open import Data.Boo... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.