---
layout: default
title : "Demos.HSP module"
date : "2022-04-27"
author: "the agda-algebras development team"
---
### Inconsistency in first formalization attempt
<!--
```agda
{-# OPTIONS --cubical-compatible --exact-split --safe #-}
open import Overture using ( π ; π₯ ; Signature )
module Demos.ContraX {π : Signature π π₯} where
open import Data.Unit.Polymorphic using ( β€ ; tt )
open import Data.Empty.Polymorphic using ( β₯ )
open import Level using ( 0β )
open import Relation.Binary using ( Setoid )
open import Relation.Binary.PropositionalEquality using ( setoid )
open import Data.Product using ( Ξ£-syntax )
open import Function renaming (Func to _βΆ_ ) using ()
open import Overture using ( projβ ; projβ )
open import Setoid.Algebras {π = π} using ( Algebra ; π»[_] )
open import Setoid.Functions using (IsSurjective ; Image_β_)
open Algebra
```
-->
```agda
_β _ : Set β Algebra 0β 0β β _
X β π¨ = Ξ£[ h β (setoid X βΆ π»[ π¨ ])] IsSurjective h
myA : Setoid 0β 0β
myA = record { Carrier = β€
; _β_ = Ξ» x xβ β β€
; isEquivalence = record { refl = tt
; sym = Ξ» _ β tt
; trans = Ξ» _ _ β tt } }
myAlg : Algebra _ _
myAlg = record { Domain = myA ; Interp = _ }
contradiction : (β X π¨ β X β π¨) β β₯
contradiction h1 = ex falso
where
h : Ξ£[ h β (setoid β₯ βΆ π»[ myAlg ])] IsSurjective h
h = h1 β₯ myAlg
falso : Image (projβ h) β tt
falso = (projβ h)
ex : Image (projβ h) β tt β β₯
ex (Image_β_.eq a x) = a
```