Skip to content

Conversation

@matthewware
Copy link

…turally.

This is just an idea to float so the catalan function in Combinatorics.jl won't be in conflict with the constant Base.catalan. I just renamed catalan -> catalan_const. Any comments are welcome!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your editor seems to have automatically converted spaces to tabs, which messes up vertical alignment in editors set up with different tab sizes (and here on github)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah yeah I guess I have vim set up to do that. I can take care of this. I should have read through Style.jl before submitting.

@stevengj
Copy link
Member

I don't really understand why this constant is in base at all.

@matthewware
Copy link
Author

My guess is that since it's defined in the mpfr libraries it was added into base just incase.

@KristofferC
Copy link
Member

Maybe this is not the place to discuss this but these one letter constants keep biting me in the ass. Do they really have to be exported by default? Unicode in code is becoming more and more common so is it really worth to pollute the namespace for some numbers?

@stevengj
Copy link
Member

@KristofferC, yes, we've discussed removing everything except for π.

@matthewware
Copy link
Author

I don't have strong feelings either way. @StefanKarpinski was okay with renaming. Maybe someone with more knowledge could weigh in on how important and useful it is to have this defined in Base. Maybe @jiahao has an opinion?

@jiahao
Copy link
Member

jiahao commented Aug 20, 2015

Let's keep this PR focused on catalan -> catalan_const.

e (The natural base) is discussed in #10612.

@stevengj
Copy link
Member

If we are going to rename, I would prefer catalan_constant, since const has a special meaning in Julia.

@nalimilan
Copy link
Member

I fail to see how we could rename catalan to catalan_constant without also renaming all other constants. Better move them to a Base.Constants module if they are really annoying.

@StefanKarpinski
Copy link
Member

I suspect we could just delete the Catalan constant.

@matthewware
Copy link
Author

So for now I'll just take the constant out (?) and leave the discussion of the other constants for later.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since all constants' symbols are now single-letter, vertical alignment isn't needed anymore, one space would suffice (this is also valid for the two spaces between the decimal expansion and the expressions: IMO they can now be collapsed to a single space.

@ararslan
Copy link
Member

This PR is no longer relevant, as catalan is no longer exported from Base and instead now lives in MathConstants. See #23427.

@ararslan ararslan closed this Mar 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants