We show for several computational problems how classical greedy algorithms for special cases can be derived in a simple way from dynamic programs for the general case: interval scheduling (restricted to unit weights), knapsack (restricted to unit values), and shortest paths (restricted to nonnegative edge lengths). Conceptually, we repeatedly expand the Bellman equations underlying the dynamic program and use straightforward monotonicity properties to figure out which terms yield the optimal value under the respective restrictions. The approach offers an alternative for developing these greedy algorithms in undergraduate algorithms courses and/or for arguing their correctness. In the setting of interval scheduling, it elucidates the change in order from earliest start time first for the memoized dynamic program to earliest finish time first for the greedy algorithm.


翻译:针对若干计算问题,我们展示了如何从一般情形的动态规划中简洁地推导出特殊情形下的经典贪心算法:区间调度(限于单位权重)、背包问题(限于单位价值)以及最短路径(限于非负边权)。从概念上,我们反复展开动态规划所基于的贝尔曼方程,并利用直观的单调性性质来确定在相应限制下哪些项能产生最优值。该方法为在本科算法课程中讲授这些贪心算法和/或论证其正确性提供了一种替代思路。在区间调度问题中,该方法阐明了从记忆化动态规划的"最早开始时间优先"到贪心算法的"最早结束时间优先"的排序转变。

0
下载
关闭预览

相关内容

【干货书】算法博弈论,Algorithmic Game Theory,775页pdf
专知会员服务
89+阅读 · 2023年6月19日
【经典书】算法博弈论,775页pdf,Algorithmic Game Theory
专知会员服务
157+阅读 · 2021年5月9日
【经典书】算法C语言实现,Algorithms in C. 672页pdf
专知会员服务
82+阅读 · 2020年8月13日
机器学习算法集锦:从贝叶斯到深度学习及各自优缺点
人工智能学家
11+阅读 · 2019年2月15日
448页伊利诺伊大学《算法》图书-附下载
专知
15+阅读 · 2018年12月31日
并行算法演进,从MapReduce到MPI
凡人机器学习
10+阅读 · 2017年11月5日
国家自然科学基金
8+阅读 · 2017年12月31日
国家自然科学基金
44+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Arxiv
0+阅读 · 3月3日
Arxiv
0+阅读 · 1月30日
VIP会员
最新内容
反制无人机:乌克兰提供的五点启示
专知会员服务
10+阅读 · 9月23日
《各指挥层级均亟需红队能力》报告
专知会员服务
9+阅读 · 9月23日
《航电任务系统框架(FAMOS)》50页报告
专知会员服务
6+阅读 · 9月22日
《对抗行动中的人工智能与自主性》智库报告
专知会员服务
12+阅读 · 9月22日
《从数据到胜利:战争中的分析优势之争》
专知会员服务
15+阅读 · 9月22日
战争不仅需要机器人:人类仍不可或缺
专知会员服务
6+阅读 · 9月21日
《描绘美国防部创新基础设施的未来蓝图》100页
专知会员服务
13+阅读 · 9月21日
相关基金
国家自然科学基金
8+阅读 · 2017年12月31日
国家自然科学基金
44+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员