Hacker News new | past | comments | ask | show | jobs | submit login

Math includes the idea of orders of infinity. There are infinite prime numbers, there are more positive integers, even more integers (positive and negative), even more rational numbers (A/B), and even more numbers (rational + irrational {e, Pi} etc)...



In what sense are there more rational numbers than prime numbers? They can be put into bijection with each other, so we generally think of them as being same infinity. There are more real nubmers, of course, by Cantor's diagonalization, so your basic point is true.


The set of all prime numbers is contained within the set of rational numbers, but they are rational numbers that are not within the set of prime numbers.

Cantor's diagonalization is simply demonstrating that same inequality by showing a number in set A is not in set B.

Just because you can map two infinity's to each other does not mean they are of the same size consider: Limit(0->inifinity) of (x - (x/2)) algebraically that's clearly Limit(0->inifinity) of X/2 which is infinity.

PS: What makes Cantor's diagonalization interesting is you can repeat it recursively an infinite number of times. This is more obvious in base 2.


The existence of a bijection between two sets is what "same size" means in set theory. Yes, there are non-prime integers, but you can establish a bijection between the two, so their cardinalities are equal (both have a cardinality of aleph zero).

The reals, on the other hand, cannot be placed in a bijection with the natural numbers, and there are therefore "more" reals than naturals (i.e. there is an injection from the naturals to the reals, but not from the reals to the naturals -- any function from reals to naturals must have some pair x ≠ y with f(x) = f(y)).


I didn't go far into set theory but, informally, it seems to me that for any given natural number N, there will be N natural numbers less than or equal to N (obviously) and P prime numbers less than or equal to N, and P < N. Doesn't taking the limit as N goes to infinity show that there are fewer primes than there are natural numbers? Where am I going wrong?


It might be easier to think of it this way: Are there more natural numbers than there are even natural numbers?

The answer is no, as illustrated by the Hotel paradox[0], in which we have a infinitely many rooms and want to accommodate a (possibly infinite) number of guests.. To summarize: For any finite number of guests, you can always find an even-numbered room to correspond to that guest (assume the guests are numbered sequentially, then double their number and put them in the room that has that number.). This creates a one-to-one correspondence, which means that the sets are the same size.

You might say, 'well, that only works because we're dealing with a finite number of guests. But we're talking about infinity'. There are a few different ways of answering that question. In my opinion, the easiest way to look at it is to remember that there is no such number as 'infinity' - when we say 'infinity', we're really trying to express the concept of growing without bound. So, the above strategy (double the person's number) works for any arbitrarily large group. At no point does it stop working, even as the group size grows larger and larger, so we can say that the two sets have the same size.

On the other hand, we have no such strategy for putting every irrational number in one-to-one correspondence with the counting numbers. That proof is a little harder, and the analogy with the hotel guests breaks down, unfortunately, so it's a bit tougher to explain.

[0] https://en.wikipedia.org/wiki/Hilbert's_paradox_of_the_Grand...


> Where am I going wrong?

In short, infinities are complicated and intuition doesn't work well.

In slightly longer, you're talking about the difference of the rate of growth of two functions rather than actually about the cardinalities of the sets.

We define two sets as having the same cardinality when we can create a bijection between them. We can list the primes in order from smallest to largest and number them with the natural numbers. So we'll have 2 match up with 0, 3 with 1, 5 with 2, 7 with 3, etc. Every single prime number will correspond with a natural number AND every single natural number will correspond with a prime number, no exceptions. So they must be the same size. They are also the same size as the integers and the rational numbers but the set of real numbers is a bigger infinity.


You're confusing a classification system with size.

Is the set of Real Numbers larger, smaller, or the same size as the set of points in a finite 2d object? Can you setup a bijection in either direction?


Assuming you consider the dimensions/axes/whatever of the 2d space to be indexed by reals (which is conventional), then yes one can construct a bijection:

    - normalise x and y coordinates in the shape into the interval (0, 1)
    - interleave the bits of the normalised x and y coordinates
This gives a single real value in the interval (0, 1), which exists and is unique for every point in the space (so it is an injection), and it covers every real number in that interval (so it is a surjection).

This gives you a bijection between points in (a) 2-dimensional space and a segment of the real line (which, in turn, has a bijection with the whole real line if you want to specify that).

Once again, cardinality in set theory is based on injections and bijections. If there is an injection from X into Y, then Y is at least as big as X. If there is a bijection between them (i.e. injections in both directions), then they are the same size.

(Also, bijections are inherently bidirectional.)


You used a countable infinity to tile an uncountable one. The set of 0 to 1 line segments being a countable infinity. 0 to 1 maps 1, 1 to 2 maps to 2 ect.


I believe you misread the text you're replying to. The bijection is between the points in the 2d space and the points in the line segment. Both of these are uncountably infinite.


>Cantor's diagonalization is simply demonstrating that same inequality by showing a number in set A is not in set B.

If that were true, why go to all the trouble, just show 1/2 which is not a natural number, or sqrt(2) which is not a rational number.

Cantor's diagonalization is proving that no mapping exists between the natural numbers and the real numbers in [0, 1]; that no matter what mapping you (try to) come up, there will be a number you would miss.

The primes and rationals have the same size (cardinality) as the natural numbers, namely countably infinite. See https://en.wikipedia.org/wiki/Countable_set#Formal_overview_...


So, you can show the Real numbers between 0 and 1 is larger than the number of Natural numbers.

There are an infant number of points between 0 and 1 and an infinite number of points between 0 and 2. The distance between 0 and 2 is larger. The number of points between 0 and 1 is smaller than the number of points on the unit circle AND they are a different class of infinity.


"The distance between 0 and 2 is larger" is a question about the metric of the space, not size of sets. There are the same number of points in both sets, since f(x) = 2x is a bijection between them.

Try to make arguments from axioms and definitions rather than asserting things from intuition. Intuition is often a useful tool, but (1) it's not an argument, and (2) it's not very helpful once you step into the infinite realm. Incidentally, that's why I went for programming: it's like math, but with no infinity (unless you're using floats, but that's a much easier infinity).


You say same number, you mean same flavor. Either the 'number' is not in R and thus it's not a number or you end up with a host of contradictions.

But, I have had my fun poking people who don't really get set theory.


Best trolling on HN in weeks.


Where in math is the subset partial ordering used to describe one set as larger than another?

Diagonalization isn't showing that a number in set A isn't in set B - that's obviously true for reals and integers, but it's also true for rationals and integers. It's showing that there does not exist a mapping from B to A where there's an element in B for each element in A.

We're obviously not using the same definition of "size". I generally think in terms of cardinality, what are you thinking of?


Cardinality is the number of elements in a set.

If every element in set A is in set B, and there are elements in set A left over it's larger because that's what larger means. {A,B} < {A,B,C}

There are countable and uncountable infinite set's. All countable set's have a bijection with N. However, there are more than two sizes of infinite sets. Real numbers < Imaginary numbers.


That's not what larger means, that's what (maps into a) strict subset means. In finite numbers, that's the same as larger (greater cardinality), but it's very much not the case for infinite numbers.

There are more than two sizes of infinite sets, but there are just as many real numbers as imaginary numbers for the same reason there's just as many integers as rational numbers.

Try reading this: https://en.wikipedia.org/wiki/Cardinality#Infinite_sets


We agree that {A,B,C} has a lower cardinality than {A,B}.

Now, feel free to try and map the set of Real numbers to the set of irrational numbers. ex: e + ei.


{A,B,C} is of greater cardinality than {A,B}. However, the argument that "a rule works for finite numbers, so it must work for infinite numbers" is clearly false.

For a your mapping, see: http://math.stackexchange.com/questions/512397/is-there-a-si...


The distance between 0 and 1 is smaller than the distance between 0 and 2. The number of points between 0 and 1 is larger than the number of rational numbers.


> The distance between 0 and 1 is smaller than the distance between 0 and 2.

This is correct. However, the number of real-valued points between 0 and 1 is the same as the number of real-valued points between 0 and 2.

> The number of points between 0 and 1 is larger than the number of rational numbers.

This is also true because there are uncountably many real-valued points between 0 and 1 and countably many rational numbers.


1. e + ei is not real.

2. f(x) = x + sqrt(2) if there exists an integer k>=0 such that x - k * sqrt(2) is rational; f(x) = x otherwise.

This function maps all real numbers to irrational numbers, 1-to-1.


e is real, e + ei is irrational.


I believe you mean "complex". You can form a bijection between the reals and the complex numbers by interleaving the digits, as any Google search can tell you.


For every point on your mapimg I define two points X + 1 and x + 1i. You can assign infinity to one of them but not both.


I'm afraid you have some basic confusion with mathematical concepts, including "mapping", "irrational", "complex", and "infinity".

So, after you define x+1 and x+i, now what? Also please bear in mind that "infinity" is neither real nor complex: if you have a well-defined mapping into complex numbers, then by definition, it never maps to infinity.

(Yes, there are some "functions" like y = 1/x that "maps to infinity", but it's simply mathematicians being lazy and abusing notations because everybody around them understands what's going on.)


O, I get it.

There is a basic contradiction in set theory. Called Russell's paradox, there are two ways around it. First is ignoring it, aka everything builds from it's self nothing can become recursive. Or Zer's something or other that basically removed membership and equality and hides in the corner crying.

As such infinity is generally assumed not to exit in R. And causes all this all infinite set's map able to each other are equivalent size crap. It's also why real mathematicians laugh at the set guys.

But, sorry the way R was initially defined it included infinity and you only get to put it into 1 place on your mapping. Or as a math professor said, what angle is the highest number in R mapping to.


Where did you get all this idea? You know enough terms, yet somehow you have an incorrect understanding of pretty much everything.

If you are interested, please read an actual math textbook. (Yes, they can be a giant time sink, but at least you'll learn the correct meanings of sets and functions.)


I have taken plenty of high level math classes for fun and easy A's, I even had a department head yell at me for not getting a PHD. So, I can speak the lingo.

But, the absurd results are not generalizable outside of their assumptions sorry Axioms. Set theory being one of the most obvious cases.

It's sadly like a religion in many ways, follow enough false statements and you can prove anything. Yet, if you find a contradiction then don't actually accept at least one of your assumptions are false.


e is irrational, e+ei can't be irrational because it isn't real (all irrationals are reals).


Sorry, imaginary number composed of two irrational numbers.


The cardinality of the set of prime numbers and of rationals are both aleph-null[1]. Same with the list of all integers, the list of all positive integers, and the list of all even integers. They all have the same cardinality, and that cardinality is aleph-null.

But please, continue to argue with mathematical definitions that have been established for over a century.

[1]: https://en.wikipedia.org/wiki/Aleph_number#Aleph-naught


Within a segment of numbers I understand how there are more rational numbers than integers, but I don't understand it in the context of infinity. How can there be more rational numbers than integers when in both cases there are infinite amounts? Are there mathematical operations or concepts that depend on this (in the context of infinity, not subsets)?


There are different kinds of infinity. The integers are countable, the real numbers aren't. You can prove that if you try to map each integer to some rational number, there will be some rational numbers that are not on that list --- there are more of them. See https://en.wikipedia.org/wiki/Cantor%27s_diagonal_argument.


> You can prove that if you try to map each integer to some rational number, there will be some rational numbers that are not on that list --- there are more of them.

Did you mean reals here? There _is_ a (bijection) mapping between integers and rationals.

https://en.wikipedia.org/wiki/Cantor_pairing_function#Cantor...


in mathematics, we lose concept of how many and fall back to cardinality, which has a lose correlation with how many. So asking "are there the same number" of integers as rational numbers gets a little iffy until we make some definitions. We just say that we can create a bijection from integers to rationals. They each index the other, and for each thing in one, there is one and only one thing in the other. Does this mean there are the same "many"? Well loosely, and in the context of cardinality, yes. But things get weird because there are the same "many" of the whole as a subset (ie, there are as "many" even numbers as integers, as "many" positive numbers as positive and negative integers, etc).

But most people would disagree with you when you say "how can there be more rational numbers than integers..." because while we don't have a firm grasp of how many, we definitely would say that having the same cardinality means that there isn't some notion of "more".

I'm not sure what you mean by mathematical operations or concepts that depend on this.


Thank you for your answer.

> I'm not sure what you mean by mathematical operations or concepts that depend on this.

I suppose I meant to ask if there was any practical application of the concepts you described.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: