Problem 1: Given an array of real number with length (n+ 1) A:

a1,  a2, ... , an2+1.

Prove that there is either an increasing or a decreasing subarray of A with length (n + 1).

Proof:

  In order to prove the proposition, we just need to prove that there must be a decreasing subarray of A

with length (n + 1) when there doesn't exist an increasing subarray of A with length (n + 1). Let mdenote

the length of the longest increasing subarray(LIS) beginning with element ai , thus under the assumption above we

have: for all 1 ≤ i ≤n+ 1, 1 ≤ mi ≤ n. Therefore by drawer principle we have mk1 = mk2  = ...  = mk(n+1),(k< k2 <... < k(n+1)).

(otherwise we have nnumbers at most whilst we got n+ 1).We assert that's the disired decreasing array, otherwise if (ki , kj) :

aki < akj ,we have LIS(mki) ≥ LIS(mkj) + 1, and this results a contradiction.

drawer principle in Combinatorics的更多相关文章

  1. pigeonhole principle 哈希表的重复问题(冲突)是不可避免的

    https://en.wikipedia.org/wiki/Pigeonhole_principle Sock-picking Assume a drawer contains a mixture o ...

  2. 抄书 Richard P. Stanley Enumerative Combinatorics Chapter 2 Sieve Methods

    2.1 Inclusion-Exclusion Roughly speaking, a "sieve method" in enumerative combinatorics is ...

  3. Atitit.软件开发的几大规则,法则,与原则Principle v3

    Atitit.软件开发的几大规则,法则,与原则Principle  v31.1. 修改历史22. 设计模式六大原则22.1. 设计模式六大原则(1):单一职责原则22.2. 设计模式六大原则(2):里 ...

  4. C#设计模式系列:开闭原则(Open Close Principle)

    1.开闭原则简介 开闭原则对扩展开放,对修改关闭,开闭原则是面向对象设计中可复用设计的基石. 2.开闭原则的实现 实现开闭原则的关键就在于抽象,把系统的所有可能的行为抽象成一个抽象底层,这个抽象底层规 ...

  5. android nagative drawer图标跟标题适配

    <?xml version="1.0" encoding="utf-8"?> <resources> <string name=& ...

  6. 开放封闭原则(Open Closed Principle)

    在面向对象的设计中有很多流行的思想,比如说 "所有的成员变量都应该设置为私有(Private)","要避免使用全局变量(Global Variables)",& ...

  7. 最少知识原则(Least Knowledge Principle)

    最少知识原则(Least Knowledge Principle),或者称迪米特法则(Law of Demeter),是一种面向对象程序设计的指导原则,它描述了一种保持代码松耦合的策略.其可简单的归纳 ...

  8. 接口分离原则(Interface Segregation Principle)

    接口分离原则(Interface Segregation Principle)用于处理胖接口(fat interface)所带来的问题.如果类的接口定义暴露了过多的行为,则说明这个类的接口定义内聚程度 ...

  9. 依赖倒置原则(Dependency Inversion Principle)

    很多软件工程师都多少在处理 "Bad Design"时有一些痛苦的经历.如果发现这些 "Bad Design" 的始作俑者就是我们自己时,那感觉就更糟糕了.那么 ...

随机推荐

  1. PostgreSQL Replication之第九章 与pgpool一起工作(7)

    9.7 处理故障转移和高可用 可以使用pgpool来解决的一些明显的问题是高可用性和故障转移.一般来讲,有使用pgpool或者不使用pgpool可以用来处理这些问题的各种方法. 9.7.1 使用Pos ...

  2. topsort

    top排序每次入队的是限制情况为0的... 就可以直接记录了,每次出队的就也是为0的,出队结果对每个子节点或者被限制节点,的限制条件-1 然后再判断有没有后继有没有为0的,有就入队! 出入队一次,找后 ...

  3. Fzu oj2194星系碰撞(排序+并查集+路径压缩)

    Problem 2194 星系碰撞 Accept: 14    Submit: 48Time Limit: 30000 mSec    Memory Limit : 327680 KB  Proble ...

  4. fzuoj Problem 2179 chriswho

    http://acm.fzu.edu.cn/problem.php?pid=2179 Problem 2179 chriswho Accept: 57    Submit: 136 Time Limi ...

  5. [原创]java WEB学习笔记87:Hibernate学习之路-- -映射 继承关系(subclass , joined-subclass,union-subclass )

    本博客的目的:①总结自己的学习过程,相当于学习笔记 ②将自己的经验分享给大家,相互学习,互相交流,不可商用 内容难免出现问题,欢迎指正,交流,探讨,可以留言,也可以通过以下方式联系. 本人互联网技术爱 ...

  6. 12---Net基础加强

    使用ShowDialog窗体之间的回传值: using System; using System.Collections.Generic; using System.ComponentModel; u ...

  7. java 中 equals和==的区别

    public static void main(String[] args) { int n=0; int m=0; System.out.println(n==m); String str = ne ...

  8. oracle的簇的创建

    簇其实就是一组表,由一组共享相同数据块的多个表组成,将经常一起使用的表组合在一起成簇可以提高处理效率:在一个簇中的表就叫做簇表. 建立顺序是:簇→簇表→簇索引→数据 创建簇的格式 CREATE CLU ...

  9. linux添加字体的过程

    只说一下过程, 至于具体的原理还没搞明白. 1. 首先你要有字体文件,ttf或者ttc格式的均可以 我们可以从windows的 C:\WINDOWS\Fonts\ 这个目录下的字体文件复制出来,例如我 ...

  10. 用jQuery创建HTML中不存在的标签元素碰到的问题

    如果你自定义了一个标签,比如<aaa></aaa> 用jQuery的写法,比如var custom_element = $('<aaa class="ee&qu ...