Cardinality

在ERP, DW里都出现了cardinality这个单词,REA model里的cardinality是已经弄懂了,可是DW里的cardinality又让人如此迷惑,上wiki查了一下,是一大堆关于数学的东西,而且是玄之又玄的无穷理论,提到了Finite, countable and uncountable sets的概念,其中的countable infinite和incountable infinite很是赞。可是看完了还是云山雾罩。定理是清楚了,可是怎么用还是迷糊,于是搜了下baidu,发现一篇未名的帖子,甚好,甚强巨^^
北大果然高手如云。。。
 
 
 
发信人: newforest (木遥·最后一眼), 信区: Reader
标 题: 长度是怎样炼成的?——无穷、测度及其他 (1)
发信站: 北大未名站 (2006年02月06日15:22:42 星期一)
 
长度是怎样炼成的?

应小乐之请写的一个东西,其目的是为了回答以下问题:

点没有长度和面积,为什么由点组成的线和面会具有长度和面积?
“长度”“面积”这些词汇究竟是在怎样的意义上被使用的?
有的时候我们把点的长度叫做零,有的时候叫做无穷小,这两个称呼是不是都有道理?
无穷个零相加是不是还得零?(其实和第一个问题是一个意思,无穷个点怎么加成线段的?)
等等等等。

当然,小乐的问题是着眼于哲学,而我的回答将会着眼于数学,——我不是学哲学的,但是大概也知道在哲学上这些词汇常常导致混乱的争论,比如芝诺悖论之类。幸运的是,早在一百年前,通过一大批杰出的数学家的努力,以上这些问题已经被精确地给出了解答,这就是在数学中被称为“测度论”的一套理论体系。这里“精确”的意思是说,这套理论体系完全基于形式逻辑,而且只采用了非常少的公理(下面会陈述之),从而,在这套理论中不存在任何模糊或者逻辑上模棱两可之处(除了几个需要加以特别说明的地方=_=!)。换句话说,我们不仅可以认为数学家能够确定无疑的回答以上这些问题,而且可以认为人类在今天能够确定无疑的回答以上这些问题(在承认那些公理的前提下)。

不幸的是,这一断言几乎必然会遭到哲学家的反对。一方面是因为哲学家们倾向于每个人自己创造一组定义,——从我在未名哲学版见过的一系列关于芝诺悖论的讨论来看,这样的结果是所有的论述最终都流于自说自话。另一方面大概也因为学术壁垒的缘故,哲学家们大概从来也没有了解过数学家们已经在此问题上做出过的卓越工作,(确实,很多细节是过于数学化了一点……)。有鉴于此,我答应小乐以尽可能通俗的方式(在不损害准确性的前提下)大致介绍一下测度论的内容。我想在这个版面上大概还会有不少别的朋友对此感兴趣吧。

下面正式开始。

一、关于无穷

当我们使用“无穷”这个词的时候,我们必须时刻谨记,这个词有两种截然不同的意义——不,我这里说的不是亚里士多德关于实无穷和潜无穷的那些绕口令,而是某些重要得多的本质问题,对他们的清晰阐释开始于伟大的德国数学家康托Georg Cantor (1845-1918):当我们说一个集合有无穷多个元素的时候,我们必须指明这里的无穷是哪一种,是“可数无穷”还是“不可数无穷”。虽然都是无穷集合,但是它们会体现出截然不同的性质。

为了说明这一问题,我们引进集合的“势(cardinality)”的概念。简单说来,势就是集合的元素的个数。一个集合有三个元素,我们就称其势为3。两个集合如果元素个数相等,我们就称它们为等势的。——很显然,要判断两个集合是不是等势,只需要看这两个集合之间能不能建立起元素的一一对应即可,如果可以的话,我们就说这两个集合的元素是一样多的。

到这里为止都显得很简单。可是最有趣的部分马上就要出现了:康托指出,不但对于有限个元素的集合我们可以讨论它们的势,对于无穷个元素的集合,我们同样可以讨论它们之间是否等势。换句话说,我们可以讨论两个无穷集合的元素是不是一样多!

之所以如此,是因为集合之间的“一一对应”本质上只是个数学概念,是可以被精确研究的对象(请回忆高中数学课本关于映射的那一章)。从而,随便拿两个集合来,它们之间是否能建立一一对应只是数学上的问题而已。

以下是一些最基本也是最著名的例子和命题,请尽量耐心的阅读。所有这些陈述都是可以基于最简单的形式逻辑给出严格证明的,证明可以在参考文献[1]上查到:

·每一个集合都和它自身等势。

注:废话。

·全体正整数的集合和全体正偶数的集合等势。

注:这是第一个有趣然而迷惑人的结果。我们等于是在说:一个集合可以和它的一部分一样多!——但是这并不是一个悖论。我们通常觉得一个集合不能和它的一部分一样多只是针对有限集合而言的,本来就没人说过无限集合不能和它的一部分一样多,只是有时候大家会不自觉地有这个误解而已。

·全体正整数的集合和全体有理数的集合等势。(什么是有理数来着?查书去!)

注:这是在数学上很重要的一个例子,说明一个实数中的稠密集可以和一个离散集等势,不过大家看到这里大概已经开始打瞌睡了……跳过这个例子!

·全体正整数的集合和全体实数的集合不等势。

注:睁大眼睛,迄今为止最重要的一句话出现了!你永远不可能在全体正整数的集合和全体实数的集合之间建立起一一对应来。对这个陈述的证明是数学上最有趣也最迷人的证明之一,可惜的是篇幅所限我不能在这里证明给大家看。那么只讨论结论好了:并不是所有的无穷集合都是等势的,有一些无穷集合比另一些无穷集合的元素更多,换句话说,无穷之间也是有大小的。

·任给一个无穷集合,我们都能够造出一个集合包含它,而且和它不等势。

注:换句话说,无穷和无穷相比,没有最大,只有更大。——但是请注意,虽然我们能够造出越来越大的无穷集合,但是我们并不真正对那些太大的无穷感兴趣,因为和这个世界没什么关系。

·如果两个集合都和第三个集合等势,那么它们彼此也等势。

注:好像也是废话,但是它引出了下面的重要陈述。

· 有很多集合都和全体正整数的集合等势,从而它们彼此也等势,我们称所有这样的集合为“可数无穷的(countably infinite)”。有很多无穷集合比全体正整数的集合的势更大,我们称所有这样的集合为不可数无穷的(uncountably infinite)。但是,不存在无穷集合的势比全体正整数的集合的势更小。

注:我们待会儿再来讨论为什么起这么两个名字。前面的例子告诉我们,全体正偶数的集合是可数无穷的,全体有理数的集合是可数无穷的,但是全体实数的集合是不可数无穷的。

·在不可数无穷集合中间,有些集合是和全体实数的集合等势的,这些集合被称为“连续统(continuum)”

注:好了,现在我们对全体无穷集合建立了一个简单的分类。最小的一类称为可数无穷集。剩下的都叫不可数无穷集。不可数无穷集里面又有特殊的一类叫作连续统,剩下当然还有一些非连续统的不可数无穷集,但是它们几乎和真实世界没有任何关系,所以忽略之。(有人不愿意忽略它们,非要去研究里面的一些麻烦的问题,于是产生了数学中间最让人头晕的一部分结论,比如什么哥德尔不完全性定理之类……这个定理偏偏还特别著名,很多人都问过我它究竟说的是啥。相信我,你不可能弄明白的。)

也就是说,我们真正关心的是两类特殊的无穷集合,一类称为可数无穷集,一类称为连续统。所有的可数无穷集彼此等势,所有的连续统彼此等势,但是任何可数无穷集和连续统之间不等势,后者总是更大一些……真绕嘴阿。

下面是一些可数无穷集和连续统的例子:

可数无穷集

自然数集,整数集,有理数集。(基本上,如果你在平面上或者直线上随手点无穷个点,并且这些点彼此都不挨着,那么它们的总数就是可数无穷的。但是也存在一些不这么简单的可数无穷集。)

连续统:

实数集,直线上点的个数,平面上点的个数,一个正方形里点的个数,或者简而言之,一切几何对象里的点的个数都是连续统。(这里一个常常被人提到的推论就是直线上的点和平面上的点一样多,——都是连续统那么多。其实证明很简单,但是一言难尽,请查书去。)

好了,现在我们可以讨论这两个名字是怎么来的了。请注意,所有的可数无穷集都是可以和正整数建立起一一对应的,这是什么意思呢?这意味着,我们可以把一个可数无穷集中的每个元素都对应到一个正整数,这相当于给他们编了号码,从而我们可以去数它们(这就是可数这个词的来历)。也就是说,我们可以按照1号、2 号、3号这么一直数下去,虽然总数是无穷的,但是只要我们在理论上一直数完所有的自然数,我们就能真正数遍这个集合的所有元素(至少在想像里是这样)。

而连续统集合却不是这样。一个直线上的点是连续统,这就是说,无论怎么巧妙的给这些点编号,我们都是不可能给所有的点都编上号码然后一个一个的数下去把它们都数完的。它们是“不可数”的。

有人会说,这不是自欺欺人么?反正都是无穷个,反正事实上总也不可能数得完,那么在理论上区分“想像中数得完”和“想像中也数不完”有什么实际意义呢?

有的。正是这一点微妙的差别,使得有些事情我们能够对可数集去做却不能对连续统集合去做,也正是这一点差别,促成了从没有大小的点到有大小的直线和平面之间的巨大的飞跃。

 
另附上一些基本概念阐述 from wiki
 

In mathematics, the cardinality of a set is a measure of the "number of elements of the set". There are two approaches to cardinality – one which compares sets directly using bijections and injections, and another which uses cardinal numbers.

Comparing sets

Two sets A and B have the same cardinality if there exists a bijection, that is, an injective and surjective function, from A to B. For example, the set E = {2, 4, 6, …} of positive even numbers has the same cardinality as the set N = {1, 2, 3, …} of natural numbers, since the function f(n) = 2n is a bijection from N to E.

A set A has cardinality greater than or equal to the cardinality of B if there exists an injective function from B into A. The set A has cardinality strictly greater than the cardinality of B if A has cardinality greater than or equal to the cardinality of B, but A and B do not have the same cardinality. In other words, if there is an injective function from B to A, but no bijective function from B to A. For example, the set R of all real numbers has cardinality strictly greater than the cardinality of the set N of all natural numbers, because the inclusion map i : NR is injective, but it can be shown that there does not exist a bijective function from N to R.

[edit] Finite, countable and uncountable sets

If the axiom of choice holds, the law of trichotomy holds for cardinality. Thus we can make the following definitions:

  • Any set X with cardinality less than that of the natural numbers (|X| < |N|) is said to be a finite set.
  • Any set X that has the same cardinality as the set of the natural numbers (|X| = |N| = ) is said to be a countably infinite set.
  • Any set X with cardinality greater than that of the natural numbers (|X| > |N|, for example |R| = > |N|) is said to be uncountable.

[edit] Infinite sets

Our intuition gained from finite sets breaks down when dealing with infinite sets. In the late nineteenth century Georg Cantor, Gottlob Frege, Richard Dedekind and others rejected the view of Galileo (which derived from Euclid) that the whole cannot be the same size as the part. One example of this is Hilbert’s paradox of the Grand Hotel.

Dedekind simply defined an infinite set as one having the same size as at least one of its "proper" parts; this notion of infinity is called Dedekind infinite.

Cantor introduced the above-mentioned cardinal numbers, and showed that some infinite sets are greater than others. The smallest infinite cardinality is that of the natural numbers ().

[edit] Cardinality of the continuum

One of Cantor’s most important results was that the cardinality of the continuum () is greater than that of the natural numbers (); that is, there are more real numbers R than whole numbers N. Namely, Cantor showed that (see Cantor’s diagonal argument).

The continuum hypothesis states that there is no cardinal number between the cardinality of the reals and the cardinality of the natural numbers, that is, . However, this hypothesis can neither be proved nor disproved within the widely accepted ZFC axiomatic set theory, if ZFC is consistent.

Cardinal arithmetic can be used to show not only that the number of points in a real number line is equal to the number of points in any segment of that line, but that this is equal to the number of points on a plane and, indeed, in any finite-dimensional space. These results are highly counterintuitive, because they imply that there exist proper subsets and proper supersets of an infinite set S that have the same size as S, although S contains elements that do not belong to its subsets, and the supersets of S contain elements that are not included in it.

The first of these results is apparent by considering, for instance, the tangent function, which provides a one-to-one correspondence between the interval [-0.5π, 0.5π] and R (see also Hilbert’s paradox of the Grand Hotel).

The second result was first demonstrated by Cantor in 1878, but it became more apparent in 1890, when Giuseppe Peano introduced the space-filling curves, curved lines that twist and turn enough to fill the whole of any square, or cube, or hypercube, or finite-dimensional space. These curves are not a direct proof that a line has the same number of points as a finite-dimensional space, but they can be easily used to obtain such a proof.

The cardinal equality c2 = c can be demonstrated using cardinal arithmetic: This argument is a condensed version of the notion of interleaving two binary sequences: let be the binary expansion of x and let be the binary expansion of y. Then , the interleaving of the binary expansions, is a well-defined function when x and y have unique binary expansions. Only countably many reals have non-unique binary expansions.

Cantor’s generalized diagonal argument shows that which implies . Here denotes the power set of , the set of all subsets of , and denotes the set of functions from to . Furthermore .

总之就是很牛。。。

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.