Zulip Chat Archive

Stream: lean4

Topic: unknown identifier


Dean Young (Dec 27 2022 at 15:31):

I have this example here:

def exams := Sigma (X : Prop), Sigma (y : Prop), Type

It gives

Main.lean:360:19: error: unknown identifier 'X'
Main.lean:360:28: error: expected command

Henrik Böving (Dec 27 2022 at 15:33):

Because you are using the sigma type via its identifier instead of its notation.

def exams := Σ (X : Prop), Σ (y : Prop), Type

Dean Young (Dec 27 2022 at 15:37):

Henrik Böving said:

Because you are using the sigma type via its identifier instead of its notation.

def exams := Σ (X : Prop), Σ (y : Prop), Type

Is there an ascii alternative?

Dean Young (Dec 27 2022 at 15:38):

Oh wait it's Sigma fun

Henrik Böving (Dec 27 2022 at 15:39):

Sigma fun X => Sigma fun y => Type

Henrik Böving (Dec 27 2022 at 15:40):

But I'd say if you are using Lean you won't be able to avoid unicode forever so you might as well embrace it :P

Dean Young (Dec 27 2022 at 16:00):

Hmm... thanks for the help and maybe so...

Oh and maybe you know how to get Type n as a function of n : Nat?

Kevin Buzzard (Dec 27 2022 at 16:03):

You can't do that because the n in Type n isn't a nat, it just looks like a nat.

Dean Young (Dec 27 2022 at 16:30):

Kevin Buzzard said:

You can't do that because the n in Type n isn't a nat, it just looks like a nat.

What about a predicate like "small" or "contained in Type n"

Reid Barton (Dec 27 2022 at 16:32):

You can say that there Exists an Equiv to a Type n -- even with only ASCII

Reid Barton (Dec 27 2022 at 16:33):

Henrik Böving said:

But I'd say if you are using Lean you won't be able to avoid unicode forever so you might as well embrace it :P

Yeah but you will have a lot more fun without unicode!

Dean Young (Dec 27 2022 at 17:39):

Reid Barton said:

Henrik Böving said:

But I'd say if you are using Lean you won't be able to avoid unicode forever so you might as well embrace it :P

Yeah but you will have a lot more fun without unicode!

Well, there was at least a point to it. I made this thing I call Mathematex, which is ultimately going to pack a bunch of things into a Latex package, maybe which calls my server of linearlibrary.org to perform the computing. Latex only works for ASCII as far as I can tell.


Last updated: Dec 20 2023 at 11:08 UTC