• 【具体数学 读书笔记】1.2 Lines in the Plane


    本节介绍平面划分问题,即n条直线最多把一个平面划分为几个区域(region)。

    问题描述:

      "What is the maximum number Ln of regions defined by n lines in the plane?"

    这个问题最初由瑞士数学家Jacob Steiner在1826年解决。

    延续上一节的解题步骤,即首先关注小规模数据,观察出结果,然后猜测一个递推式并从理论上证明,最后由递推式导出"closed form"(通项式)。下面具体整理解题步骤:

    1. 观察得出小规模数据的结果,尝试给出递推式:

      L1 = 2

      L2 = 4 = 2 + 2

      L3 = 7 = 4 + 3

    现在可以猜测一个递推式:Ln = Ln-1 + n

    2. 从理论上证明递推式:

    首先对于直线分平面问题有一个结论: a straight line can split a convex region into at most two new regions, which will also be convex. 即一条直线最多可以把一个凸的区域分成两个凸的区域。

    (对于convex,旁注上有如下定义:a region is convex if it includes all line segments between any two of its points.)

    接下来可以观察到如下结论:

      for n>0, the nth line increases the number of regions by k

      iff. it splits k old regions

      iff. it hits the previous lines in k-1 different points.

    由于已有n-1条直线,所以第n条直线最多和已有直线产生n-1个交点,所以k的最大值为n,由此一个可行解,它是充分的 Ln <= Ln-1 + n (n>0)

    接下来试图说明它的必要性:只要把第n条直线放在与前n-1条都不相交的方向,那么第n条直线必和前n-1条直线各有一个交点。又因为Ln-1为最大值,所以保证了前n-1条直线产生的n-2个交点互异,可以做到第n条直线产生的n-1个新交点彼此互异,且和前n-2个交点也互异。由此 Ln >= Ln-1 + n (n>0)。

    所以取等号了,加上对平凡情况的约定,构成如下递推式:

      L0 = 1

      Ln = Ln-1 + n (n>0)

    3. 由递推式求通项式:

    "we can often understand a recurrence by 'unfolding' or 'plugging in' it all the way to the end." 即逐项代入,直至平凡情况,看展开后的值是否易求。

      Ln = Ln-1 + n

        = Ln-2 + (n-1) + n

        = ...

        = L0 + 1 + 2 + ... + (n-1) + n = 1 + Sn

    其中Sn是很常见的前n项整数和,又叫"triangular numbers",因为它是n行的三角形摆放的保龄球的个数;也可以叫它前缀和吧。传说高斯在9岁时给出的通项式~~Sn = n(n+1)/2。由此得到Ln的通项式 Ln = n(n+1)/2 + 1

    作者说我们不妨记住Sn数列的小规模值,如下表:

    n 1 2 3 4 5 6 7 8 9 10 11 12 13 14
    Sn 1 3 6 10 15 21 28 36 45 55 66 78 91 105

    接下来作者还介绍了原问题的一个变种----折线分平面问题。

    一条折线(bent line, each containing one "zig")可以看作是两条直线相交得到;因抹除了两条射线,所以比两条直线分成的区域数减少一半。

    如果每条折线的zig point都放置在交点“外围”,那么在放置第n条折线时(与之前的所有折线交于4个点),相比2n条直线分成的平面数,每条直线会减少2个交点,也就减少了两个区域。由此得到如下递推式及通项式:

      Zn = L2n - 2n

      = 2n(2n+1)/2 + 1 - 2n

      = 2n^2 - n + 1

  • 相关阅读:
    后勤数据抽取流程图 Logistic Data Extraction
    WINDOWS两条线路上网的解决办法
    Zabbix Agent for Linux部署
    Java项目的自动更新并构建脚本
    使用Goole搜索引擎
    golang程序性能优化方法----不断更新
    golang性能分析策略
    问题分析:引入新elastic api导致的TIME_WAIT堆积
    数据权限限定办法
    MariaDB集群搭建
  • 原文地址:https://www.cnblogs.com/helenawang/p/5484075.html
Copyright © 2020-2023  润新知