homalg-project / CAP_project

CAP project -- Categories, Algorithms, and Programming
https://homalg-project.github.io/docs/CAP_project-based/
24 stars 18 forks source link

Distinguish between small and big integers #1633

Open zickgraf opened 3 months ago

zickgraf commented 3 months ago

This is a tentative attempt to distinguish between small and big integers in GAP to mirror the situation in Julia. Doing this across the whole codebase seems like an enormous effort. I'm not sure if this effort is worth it.

@mohamed-barakat If you are interested in this, we can look at some examples (e.g. the CategoryOfRows) in more detail and check what would have to be done.

mohamed-barakat commented 3 months ago

Yes, I am interested. I would also like to have a version of SkeletalFinSets which uses the small integers and not the gmp-integers.

zickgraf commented 3 months ago

Yes, I am interested. I would also like to have a version of SkeletalFinSets which uses the small integers and not the gmp-integers.

What application do you have in mind? This category would not have products etc. anymore, correct?

zickgraf commented 3 months ago

There are also some subtleties in Julia when working with ranges of big ints:

julia> typeof(length(BigInt(1):BigInt(1)))
BigInt

julia> typeof(length(map(x -> x,BigInt(1):BigInt(1))))
Int64