共查询到20条相似文献,搜索用时 93 毫秒
1.
李盘荣 《电脑编程技巧与维护》2011,(18):25-27
递归算法的设计与实现是非常重要的内容,全排列是组合数学中最常见的问题。提出了基于递归算法并通过c语言编程实现了计算机解题,实例数据表明程序非常高效。 相似文献
2.
3.
4.
全排列递归算法在算法教学中的重要性 总被引:1,自引:0,他引:1
全排列递归算法简洁,清晰,可读性强。针对该算法在递归算法的设计以及回溯法中的应用.讨论了全排列递归算法在算法教学中的重要作用。 相似文献
5.
递归在计算机科学和数学中都是一个重要的问题求解工具,许多复杂问题的求解都可以用递归算法去解决,适当的使用递归算法可以简化复杂问题。该文通过具体的实例,讨论了递归算法的实现,并对递归算法进行了进一步的探讨。 相似文献
6.
关于Hanoi塔问题的非递归算法,已有了大量的研究[1 ̄4]。实验表明,当圆盘数目较少时,现有的非递归算法的执行速度比递归算法要快一些,但是随着圆盘数目的增加,现有的非递归算法的执行速度会逐渐变得比递归算法慢。论文提出了一种基于压缩编码的非递归新算法,在压缩了存储空间的同时,提高了算法的执行速度。实验结果表明,对于任意圆盘数目n,论文所实现的非递归算法的执行速度比现有的递归算法和非递归算法都有成倍的提高。 相似文献
7.
递归算法是程序设计中的一种有力的工具,许多问题采用递归方法来编写求解程序.使程序非常简洁而清晰。本文针对学生在学习程序设计课程时对递归算法难以理解及掌握等情况,阐述了递归算法的本质及解决问题的思路。 相似文献
8.
虽然递归算法具有结构简练、清晰、可读性强等优点,但有时受执行效率和程序设计语言的限制,必须实现递归向非递归的转换.提出一个通用的算法框架实现一般递归算法向非递归算法的转换.该框架产生的非递归算法没有标号,适用于大多数程序设计语言.结合几个典型的实例说明该框架的应用方法和有效性. 相似文献
9.
递归在计算机科学和数学中都是一个重要的问题求解工具,许多复杂问题的求解都可以用递归算法去解决,适当的使用递归算法可以简化复杂问题。该文通过具体的实例,讨论了递归算法的实现,并对递归算法进行了进一步的探讨。 相似文献
10.
二叉树遍历递归算法非递归化的讨论 总被引:3,自引:0,他引:3
尽管递归算法具有结构简炼、清晰、可读性强等优点,但递归算法在执行过程会耗费太多的时间和空间,为了追求算法的时空效率,必须将递归算法转化为非递化算法,问题才能得到有效解决,本文讨论了在递归算法执行过程中栈的变化和给出了改进的非递归化算法。 相似文献
11.
文章给出了一种快速判断三相变压器联接组的方法———相位递推法,这种方法和相量图法比较具有简单、快速、准确的特点。 相似文献
12.
主要研究了著名的几何曲线——蔓叶线的一种并行生成算法,以Bresenham算法为基础,对蔓叶线的并行生成算法进行了分析和讨论。首先,从蔓叶线图像的一个已知点开始,根据递推公式逐点选择最靠近蔓叶线的像素点;然后引入并行机制生成蔓叶线的图像;最后,利用C#多线程模拟实现了该算法。模拟结果表明,这是关于蔓叶线图像的一种快速、高效的并行算法。 相似文献
13.
14.
15.
MA Biao-biao 《数字社区&智能家居》2008,(22)
ACM/ICPC(ACM International Collegiate Programming Contest)是ACM国际大学生程序设计竞赛的简称,这是世界计算机领域的一项权威赛事。该文就是针对ACM国际大学生程序设计中的一道题目的解法进行算法分析,道题目的名字叫做"Instructions"。通过对原问题进行理解,通过暴力方法,动态递推法,对原问题进行算法分析和实现,然后对算法进行测试和总结,从而满足题目的要求。 相似文献
16.
K-Dimensional Optimal Parallel Algorithm for the Solution of a General Class of Recurrence Equations 总被引:1,自引:0,他引:1 下载免费PDF全文
1IntroductionAlgorithmshavebeenproposedtosolvelinearrecurrencesinparallell1-13].Someofthemsupposeunlimitednumberofprocessorsbeingusedwhileothersuselimitednumberofprocessors.P-M.KoggeandH.S.Stoneproposedarecursivedou-blingalgorithmforthesolutionofageneraJclassofrecuxrenceequationsl1].Itisthefastestalgorithm(thetimeisO(log,N))whenthenumberofprocessingelemelltspiseqllaltoN.Howeveritisnotoptimalintermsofefficiency:itsspeedupisO(de),whileitsefficiencyisO(wt).TherecursivedoublingapproachcanPro… 相似文献
17.
一种求解函数优化问题的单亲遗传算法 总被引:2,自引:0,他引:2
1 引言求解函数优化问题,特别是多峰函数的优化问题,由于传统的遗传算法将杂交算子作为主要算子,在选择压力的作用下,群体的多样性在进化过程中存在逐步降低的现象,最后以致趋同,进而过早收敛。文[1]也指出“杂交算子在搜索过程中存在着严重的成熟化效应,它在起搜索作用的同时,不可避免地使群体的多样性趋于0,从而逐渐减小自己的搜索范围,引起过早收敛”。 相似文献
18.
一种求解TSP问题的单亲遗传算法 总被引:15,自引:0,他引:15
1 前言 TSP问题可描述为:给定一个城市的集合,寻找一条从集合中的某个城市出发,访问每个城市一次且仅一次,最后回到出发点的最短路径。这已被证明是一个NP难解问题。求解TSP问题,遗传算法通常采用序号编码和非序号编码两种解表达方式。其中序号编码相对简单直接,其代表性的有“邻接表达”、“普通表达”和“路径表达”等几种编码方式,后者是最自然的表达方式。序号编码方式的杂交算子难于设计,杂交后解的合法性是需着重考虑的问题。虽然目前已提出了一些基于路径表达的杂交算子,如PMX、OX和CX,但普遍计算额外开销很大,而且杂交算子的使用对群体的多样性存在很大影响,容易使算法过早收敛。 相似文献
19.
20.
《国际计算机数学杂志》2012,89(4):433-461
VLSI technology has had tremendous success in revolutionizing computer design with processor arrays. Local communication and interconnection is a constraint that dictates the design of processor arrays. The shared bus and global access to memory are now no longer used, since they lower the speed. Consequently, parallel algorithms must be designed according to these constraints. One of the problems that must be resolved for the above mentioned constraints is data broadcast elimination. Algorithms must be transformed into a form that uses data propagation instead of data broadcast. Here systems of affine recurrence equations are analyzed and data broadcast is denned in context of the definition of data dependence and affine recurrence equations. A method for data broadcast elimination is introduced in [1] and expands the system of affine recurrence equations into new recurrence equations, that define data propagation and eliminates the data dependences where data broadcast occurs. Parallel algorithms are usually given as a set of similar tasks repetitively performed on different data. The iteration form of presenting the algorithms is most common. Several techniques are introduced to transform the algorithm to a single assignment form of recurrence equations. Some improvements of these techniques are presented to make the application of the data broadcast elimination method easier and more straight forward. The presented techniques are classified as the transformation of iterative algorithms to a recurrence form, the transformation of recurrence form to a single assignment form, and fulfilling the index forms of the algorithms. A system of affine recurrence equations with the data broadcast property is always obtained by applying these procedures. The method of data broadcast elimination successfully transforms this system of affine recurrence equations into a system of uniform recurrence equations which can be used for parallel implementation on VLSI processor arrays. 相似文献