-
Notifications
You must be signed in to change notification settings - Fork 247
_≤ᵇ_
for Natural numbers
#781
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hmm, well the idea is that I'm struggling to think of a use case for where using Basically if we can come up with a use for it then yes. Otherwise I think best to try and keep the boolean versions as unobtrusive as possible and encourage everyone to use the proper dependent types. I know as an Agda beginner I would have gone straight for the boolean versions if they were prominently available. |
one trouble I have with the current definition of ≤?-yes : ∀ {m n} (m≤n : m ≤ n) → (m ≤? n) ≡ yes m≤n
≤?-no : ∀ {m n} (m>n : ¬ m ≤ n) → ∃ λ ¬p → (m ≤? n) ≡ no ¬p the idea is that if |
We should probably provide a pair of general lemmas: (p? : Decidable P) -> Irrelevant P -> (p : P) -> p? ≡ yes p
(p? : Decidable P) -> ¬ P -> ∃ λ ¬p → p? ≡ no ¬p Which could then be used to reimplement |
yes that's true. probably the first lemma can have a relevant variant. |
Why does |
sorry I might not react fast enough today. could you please explain why that's true? for example, module _ {m n : ℕ}
(m>n : ¬ m ≤ n) where
m>n′ : ¬ m ≤ n
m>n′ z≤n = m>n z≤n
m>n′ (s≤s m≤n) = m>n (s≤s m≤n)
irrelevant : m>n ≡ m>n′
irrelevant = {!!} how can this be proved? |
Hm, I was a bit too fast: you can prove that they are pointwise equal (because any two elements of the empty type are equal) but to prove that |
On Sun, May 19, 2019 at 10:57:12AM -0700, Jesper Cockx wrote:
Any two proofs of a negative proposition are equal
Are they? You seemed to argue differently in and around agda/agda#2516 (comment) ...
|
They are propositionally equal, not definitionally equal (if you want them to be, you can use irrelevance or |
Yep. That's why I opened #645 but then we decided that the change would be too |
I always argued in favour of making |
Yup, we'd need to add the definition |
It's OK to always have --prop open, isn't it? what can it hurt? |
Without data D A : Set where
c : A -> D A and Agda will figure out that |
The original problem has been solved so I'm closing this. |
I realized that now in stdlib,
_<ᵇ_
is defined and_≤?_
depends on it. Does that make sense to define_≤ᵇ_
in terms of_<ᵇ_
and have_≤?_
derive proofs from_≤ᵇ_
? Namely, two additional lemmas,≤ᵇ⇒≤
and≤⇒≤ᵇ
. I am asking this, because for me_≤_
is a more frequent relation than_<_
.The text was updated successfully, but these errors were encountered: