Zulip Chat Archive

Stream: maths

Topic: norm_num and fin


Yury G. Kudryashov (Mar 04 2022 at 15:22):

The following #mwe doesn't work. How can I make norm_num work with fin n? @Mario Carneiro

import tactic.norm_num

example : (2 : fin 3) = 0 := by norm_num

Mario Carneiro (Mar 04 2022 at 15:23):

norm_fin

Mario Carneiro (Mar 04 2022 at 15:23):

actually that one should work in norm_num

Yury G. Kudryashov (Mar 04 2022 at 15:24):

It doesn't. norm_fin works.

Mario Carneiro (Mar 04 2022 at 15:27):

oh, it's just your imports

Mario Carneiro (Mar 04 2022 at 15:27):

if you import tactic.norm_fin then norm_num works

Mario Carneiro (Mar 04 2022 at 15:27):

because tactic.norm_fin declares a norm_num extension

Jakub Kądziołka (Mar 04 2022 at 17:20):

wait, how come 2 = 0 in that type?

Alex J. Best (Mar 04 2022 at 17:22):

It doesn't, I guess its a typo

Kevin Buzzard (Mar 04 2022 at 17:26):

yeah, it adds to the mystery of the question that an expert Lean user is complaining about how he can't prove an obviously false statement

Mario Carneiro (Mar 04 2022 at 17:37):

when I say "works" above I mean it reduces to false instead of leaving it as is

Eric Wieser (Mar 04 2022 at 18:32):

Who needs norm_num?

example : (3 : fin 3) = 0 := rfl

Last updated: Dec 20 2023 at 11:08 UTC