Approximation ratio

【Definition】 An algorithm has an approximation ratio of ρ\rhoρ(n) if, for any input of size n, the cost C of the solution produced by the algorithm is within a factor of ρ\rhoρ (n) of the cost C* of an optimal solution: max(CC∗,C∗C)≤ρ(n)\frac{C}{C^*},\frac{C^*}{C}) \leq \rho(n)C∗C​,CC∗​)≤ρ(n)
If an algorithm achieves an approximation ratio of ρ\rhoρ(n), we call it a ρ\rhoρ(n)-approximation algorithm.

【Definition】 An approximation scheme for an optimization problem is an approximation algorithm that takes as input not only an instance of the problem, but also a value ϵ\epsilonϵ > 0 such that for any fixed ϵ\epsilonϵ, the scheme is a (1+ ϵ\epsilonϵ)-approximation algorithm.
We say that an approximation scheme is a polynomial-time approximation scheme (PTAS) if for any fixed ϵ\epsilonϵ > 0, the scheme runs in time polynomial in the size n of its input instance.
eg. O((1/ϵ)2n3)O((1/ \epsilon)^2 n^3)O((1/ϵ)2n3) --> FPTAS (fully …) , O(nϵ/2)O(n^{\epsilon/2})O(nϵ/2), …

Approximate Bin Packing

Online Algorithms

next fit

void NextFit ( )
{   read item1;while ( read item2 ) {if ( item2 can be packed in the same bin as item1 )place item2 in the bin;elsecreate a new bin for item2;item1 = item2;} /* end-while */
}

Let M be the optimal number of bins required to pack a list I of items. Then next fit never uses more than 2M – 1 bins. There exist sequences such that next fit uses 2M – 1 bins.

first fit

void FirstFit ( )
{   while ( read item ) {scan for the first bin that is large enough for item;if ( found )place item in that bin;elsecreate a new bin for item;} /* end-while */
}

Let M be the optimal number of bins required to pack a list I of items. Then first fit never uses more than 17M / 10 bins. There exist sequences such that first fit uses 17(M – 1) / 10 bins.
best fit

Off-line Algorithm

first fit decreasing
Let M be the optimal number of bins required to pack a list I of items. Then first fit decreasing never uses more than 11M / 9 + 6/9 bins. There exist sequences such that first fit decreasing uses 11M / 9 + 6/9 bins.
best fit decreasing

Exercises

Approximation相关推荐

  1. Sparse low rank approximation

    1. Sparse and low rank approximation (source codes) :http://www.ugcs.caltech.edu/~srbecker/wiki/Main ...

  2. 核逼近(Kernel Approximation)

    核逼近(Kernel Approximation) 主要方法和函数: sklearn.kernel_approximation.Nystroem sklearn.kernel_approximatio ...

  3. 人脸检测--Recurrent Scale Approximation for Object Detection in CNN

    Recurrent Scale Approximation for Object Detection in CNN ICCV2017 https://github.com/sciencefans/RS ...

  4. UA OPTI544 量子光学9 2-level system approximation的向量模型

    UA OPTI544 量子光学9 2-level system approximation的向量模型 Bloch Vector与Optical Bloch Equation Bloch变量及其物理含义 ...

  5. UA OPTI544 量子光学8 2-level system approximation的population rate equation模型

    UA OPTI544 量子光学8 2-level system approximation的population rate equation模型 Density Matrix的稳态(假设无非弹性碰撞) ...

  6. UA OPTI544 量子光学7 2-level system approximation的Density Matrix模型

    UA OPTI544 量子光学7 2-level system approximation的Density Matrix模型 Density Matrix的Rabi Equation Non-Hami ...

  7. 创新实训个人记录:approximation factor, maximum matchingvertex cover

    创新实训个人记录:approximation factor, maximum matching&&vertex cover approximation factor(近似比) maxi ...

  8. 斯特林公式(Stirling's approximation)

    斯特林公式(Stirling's approximation)是一条用来取n的阶乘的近似值的数学公式.一般来说,当n很大的时候,n阶乘的计算量十分大,所以斯特林公式十分好用,而且,即使在n很小的时候, ...

  9. C++实现successive approximation渐进法(附完整源码)

    C++实现successive approximation渐进法 C++实现successive approximation渐进法算法完整源码(定义,实现,main函数测试) C++实现success ...

  10. Approximation and fitting、Statistical estimation

    一.Approximation and fitting 1. 拟合与回归的区别 回归分析:是一种统计学上分析数据的方法,目的在于了解两个或多个变量间是否相关.相关方向与强度,并建立数学模型以便观察特定 ...

最新文章

  1. SpringBoot接口参数校验
  2. 2020-03-21
  3. uploadify的使用错误
  4. shell_之_find(查找)
  5. Airbnb搜索:Embedding表示学习
  6. Group By和Order By的总结
  7. LINUX检查一个进程内存增长的脚本
  8. c语言井字棋二维数组,【C语言】简单实现三子棋(井字棋)小游戏
  9. word当前页面设置第一页
  10. 给公司、领导提提意见,该怎么写?
  11. 【期末复习】网络安全技术(双语)
  12. Java实现微信公众号模板消息管理群发和单发
  13. 验收测试的名词解释_验收测试工作流程及准则
  14. vs智能提示英文转为中文
  15. 【笔记】ARM指令系统
  16. ubuntu下载,直接上中国官网就好了
  17. win7 mac 时间不一致
  18. BBS社区运营,需要什么专业知识?
  19. 详解资本市场线、证券市场线、证券特征线
  20. SmartDraw 2010 破解

热门文章

  1. 大学物理----同方向同频率简谐振动的合运动公式的数学推导
  2. 我在拼多多的三年......
  3. Chloroplot叶绿体基因组圈图可视化的新工具
  4. 《高效学习7堂课》读书笔记PPT模板
  5. 海康SDK对接系列教程(一)- 总览
  6. python第三方库pygame的使用
  7. 计算机专业英语汇总(二)
  8. Illustrator如何使用图形对象的特殊效果之实例演示?
  9. 第十二周作业任务2-1
  10. psnbsp;盖印图层