首页 | 官方网站   微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 31 毫秒
1.
We provide a mathematical specification of an extension of Warren's Abstract Machine (WAM) for executing Prolog to type-constraint logic programming and prove its correctness. Our aim is to provide a full specification and correctness proof of a concrete system, the PROTOS Abstract Machine (PAM), an extension of the WAM by polymorphic order-sorted unification as required by the logic programming language PROTOS-L.In this paper, while leaving the details of the PAM's type constraint representation and solving facilities to a sequel to this work, we keep the notion of types and dynamic type constraints abstract to allow applications to different constraint formalisms like Prolog III or CLP(R). This generality permits us to introduce modular extensions of Börger's and Rosenzweig's formal derivation of the WAM. Since the type constraint handling is orthogonal to the compilation of predicates and clauses, we start from type-constraint Prolog algebras with compiled AND/OR structure that are derived from Börger's and Rosenzweig's corresponding compiled standard Prolog algebras. The specification of the type-constraint WAM extension is then given by a sequence of evolving algebras, each representing a refinement level, and for each refinement step a correctness proof is given. Thus, we obtain the theorem that for every such abstract type-constraint logic programming system L, every compiler to the WAM extension with an abstract notion of types which satisfies the specified conditions, is correct.The first author was partially funded by the German Ministry for Research and Technology (BMFT) in the framework of the WISPRO Project (Grant 01 IW 206). He would also like to thank the Scientific Center of IBM Germany where the work reported here was started.  相似文献   

2.
Constraint Retraction in CLP(FD): Formal Framework and Performance Results   总被引:1,自引:1,他引:0  
Constraint retraction can be described, in general, as the possibility of deleting a previously stated piece of information. This is obviously very convenient in many programming frameworks, especially in those that involve some level of interaction between the user and the system, or also in those concerning rescheduling or replanning. Nevertheless, constraint retraction is usually not provided in current constraint programming environments. This is mainly due to its high complexity and also to its non-monotonic nature, which would make most of such systems much more complex to reason with. In this paper we avoid these problems by considering a specific constraint programming framework, called clpFD, that is, constraint logic programming (CLP) over finite domain (FD) constraints. We propose an algorithm which deletes a constraint from a set of FD constraints, while maintaining partial arc-consistency, which is usual in this programming framework. What is crucial is that the retraction operation we propose is incremental, in that it follows the chain of dependencies among variables which are set by the nature of the FD constraints, and by doing so it updates only the part of the constraint set which is affected by the deletion. We also detail how constraint retraction can be incorporated in the FD constraint solver and we evaluate its behavior within the clpFD system. Experimental results on usual benchmarks, on classes of problems of increasing connectivity, and also on a real-life problem show that in almost all cases the use of our retraction algorithm provides great speed-up with respect to standard methods while not slowing down the clpFD system when no retraction is performed. This provides the system with an efficient way of retracting constraints while not changing its performance when the user does not want to use this new feature.  相似文献   

3.
一种并行工程约束分解方法   总被引:2,自引:0,他引:2  
在并行工程产品开发过程中,往往按照问题的结构特点将较大规模的问题分解成一些子问题,并希望通过求解子问题来获得原问题的解。实际中,分解得到的子问题之间往往不是完全独立的,一般的简单分解方法只能有限地降低求解难度和简化问题规模。如何进一步分解各个子问题间的关系,使各个子问题的设计结果不但满足原问题的总体要求而且还能由此获得优化的总体设计结果是一个重要问题。该文给出了分解的意义,提出了基于约束的优化分解方法。  相似文献   

4.
不透明谓词是一类轻量级的代码混淆方法,能以单向的执行复杂度对抗程序的逆向分析。广义不透明谓词扩展狭义不透明谓词的值恒定属性至逻辑恒定属性,已经应用于部分恶意代码中以提升抗查杀能力。为消除不透明谓词对程序恶意性判定的影响,以广义不透明谓词后趋依赖的属性为依据,结合逻辑恒定判定,提出了基于逻辑一致性的广义不透明谓词检测方法。通过静态分析提取谓词前置条件约束、后趋逻辑约束和谓词判定表达式,以相交基本块搜寻初筛谓词,并依据约束求解方法判定广义不透明谓词。构造原型系统并进行测试,结果表明该方法能精准高效地检测出恶意代码中的不透明谓词。  相似文献   

5.
Abstract

This paper presents an enhancement of the CARESS system—A Constraint Approximative Reasoning System Support—introduced in (Popescu and Roventa, 1994). CARESS is an experimental system with primarily two objectives:

(1)knowledge representation and manipulation techniques and to implement them in PROLOG III, and

(2) to develop a knowledge programming environment for building expert systems. We discuss here the use of meta-programming, constraint logic programming and approximate reasoning for the design of expert systems

It has already been proven that meta-programming and logic programming are powerful techniques for expert system design. Fuzzy logic can be used to model one kind of uncertainty. Constraint logic programming is useful for dealing with the constraints given by operations using fuzzy sets.  相似文献   

6.
Although constraint programming has attracted much attention in logic programming, nowadays the importance to integrate constraints with imperative programming is widely acknowledged. In particular, in artificial intelligence domains, the benefits deriving from merging constraint‐based programming with object‐oriented paradigms seem to be still more attractive because of the lack of ‘pure’ AI languages in supporting structured representations. This work presents the extension of the Java language towards finite domain constraint programming. This extension has been possible thanks to a high‐level approach to low‐level resource management: the sleeper mechanism. As practical results, this paper shows how Java programmers can develop meaningful applications in which finite domain constraints have been extensively used, as in the design of visual, interactive, user‐interface environments in a client–server architecture. Copyright © 1999 John Wiley & Sons, Ltd.  相似文献   

7.
Constraint hierarchies provide a framework for soft constraints, and have been applied to areas such as artificial intelligence, logic programming, and user interfaces. In this framework, constraints are associated with hierarchical preferences or priorities called strengths, and may be relaxed if they conflict with stronger constraints. To utilize constraint hierarchies, researchers have designed and implemented various practical constraint satisfaction algorithms. Although existing algorithms can be categorized into several approaches, what kinds of algorithms are possible has been unclear from a more general viewpoint. In this paper, we propose a novel theory called generalized local propagation as a foundation of algorithms for solving constraint hierarchies. This theory formalizes a way to express algorithms as constraint scheduling, and presents theorems that support possible approaches. A benefit of this theory is that it covers algorithms using constraint hierarchy solution criteria known as global comparators, for which only a small number of algorithms have been implemented. With this theory, we provide a new classification of solution criteria based on their difficulties in constraint satisfaction. We also discuss how existing algorithms are related to our theory, which will be helpful in designing new algorithms.  相似文献   

8.
The incorporation of global program analysis into recent compilers for Constraint Logic Programming (CLP) languages has greatly improved the efficiency of compiled programs. We present a global analyser based on abstract interpretation. Unlike traditional optimizers, whose designs tend to be ad hoc, the analyser has been designed with flexibility in mind. The analyser is incremental, allowing substantial program transformations by a compiler without requiring redundant re-computation of analysis data. The analyser is also generic in that it can perform a large number of different program analyses. Furthermore, the analyser has an object-oriented design, enabling it to be adapted to different applications easily and allowing it to be used with various CLP languages with simple modifications. As an example of this generality, we sketch the use of the analyser in two different applications involving two distinct CLP languages: an optimizing compiler for CLP(R) programs and an application for detecting occur-check problems in Prolog programs. © 1998 John Wiley & Sons Ltd.  相似文献   

9.
10.
We study the complexity of two-person constraint satisfaction games. An instance of such a game is given by a collection of constraints on overlapping sets of variables, and the two players alternately make moves assigning values from a finite domain to the variables, in a specified order. The first player tries to satisfy all constraints, while the other tries to break at least one constraint; the goal is to decide whether the first player has a winning strategy. We show that such games can be conveniently represented by a logical form of quantified constraint satisfaction, where an instance is given by a first-order sentence in which quantifiers alternate and the quantifier-free part is a conjunction of (positive) atomic formulas; the goal is to decide whether the sentence is true.While the problem of deciding such a game is PSPACE-complete in general, by restricting the set of allowed constraint predicates, one can obtain infinite classes of constraint satisfaction games of lower complexity. We use the quantified constraint satisfaction framework to study how the complexity of deciding such a game depends on the parameter set of allowed predicates. With every predicate, one can associate certain predicate-preserving operations, called polymorphisms. We show that the complexity of our games is determined by the surjective polymorphisms of the constraint predicates. We illustrate how this result can be used by identifying the complexity of a wide variety of constraint satisfaction games.  相似文献   

11.
We consider the Weighted Constraint Satisfaction Problem which is an important problem in Artificial Intelligence. Given a set of variables, their domains and a set of constraints between variables, our goal is to obtain an assignment of the variables to domain values such that the weighted sum of satisfied constraints is maximized. In this paper, we present a new approach based on randomized rounding of semidefinite programming relaxation. Besides having provable worst-case bounds for domain sizes 2 and 3, our algorithm is simple and efficient in practice, and produces better solutions than some other polynomial-time algorithms such as greedy and randomized local search.  相似文献   

12.
To ease the programming burden and to make parallel programs more maintainable, computational scientists and engineers currently have the options to use software libraries, templates, and general purpose language extensions to compose their application programs. These existing options, unfortunately, have considerable limitations with compatibility, expressive power and delivered performance. To address these issues, we design a domain specific language, GridFOR, for computational problems defined over regular geometric grids. This language allows the programmer to first implement an algorithm on simple data structures, as commonly illustrated in textbooks or papers. The programmer then specifies transformations to extend the algorithm for complex data structures required by the target applications. We build a compiler to automatically translate a GridFOR program to a parallel Fortran version with Message Passing Interface calls. Several optimization techniques are implemented in our compiler to enhance the program speed.  相似文献   

13.
智能规划的逻辑编码方式研究   总被引:1,自引:0,他引:1  
逻辑编码方式的设计和实现是基于转换的规划方法有效处理的关键.对几种智能规划方法中的逻辑编码方式予以分析,分别介绍线性编码、基于Graphplan的编码、基于状态的编码、基于动作的编码、基于命题的编码、基于转移的编码、提升的因果编码、基于多值变元的编码、基于有向二元决策图的编码以及基于约束可满足的编码等,并结合国际规划竞赛和相关论文等的实验结论,说明上述编码方式的有效性和可行性,分析该类编码方式在其他领域的应用前景.最后,提出目前智能规划方法中逻辑编码方式研究所面临的挑战、可能的处理方法,以及与之相关的研究热点与趋势.  相似文献   

14.
In this paper an application of constraint logic programming (CLP) to the resolution of nesting problems is presented. Nesting problems are a special case of the cutting and packing problems, in which the pieces generally have non‐convex shapes. Because of their combinatorial optimization nature, nesting problems have traditionally been tackled by heuristics and in the recent past by meta‐heuristics. When trying to formulate nesting problems as linear programming models, to achieve global optimal solutions, the difficulty of dealing with the disjunction of constraints arises. On the contrary, CLP deals easily with this type of relationships among constraints. A CLP implementation for the nesting problem is described for convex and non‐convex shapes. The concept of nofit polygon is used to deal with the geometric constraints inherent to all cutting and packing problems. Computational results are presented.  相似文献   

15.
课程安排问题是典型的组合优化和不确定调度问题。采用约束逻辑程序设计的研究方法,结合课程安排自身的特点,通过约束推理找到最优的课程安排结果。约束逻辑程序设计综合了人工智能中一致性算法和启发式搜索算法,采用约束推理方法,能非常好地处理各种冲突,并且能快速地排出合理的课程。  相似文献   

16.
In this paper, we propose a way of exploiting Operations Research techniques within global constraints for cost-based domain filtering. In Constraint Programming, constraint propagation is aimed at removing from variable domains combinations of values which are proven infeasible. Pruning derives from feasibility reasoning. When coping with optimization problems, pruning can be performed also on the basis of costs, i.e., optimality reasoning. Cost-based filtering removes combination of values which are proven sub-optimal. For this purpose, we encapsulate in global constraints optimization components representing suitable relaxations of the constraint itself. These components embed efficient Operations Research algorithms computing the optimal solution of the relaxed problem and a gradient function representing the estimated cost of each variable-value assignment. We exploit these pieces of information for pruning and for guiding the search. We have applied these techniques to a couple of ILOG Solver global constraints (a constraint of difference and a path constraint) and tested the approach on a variety of combinatorial optimization problems such as Timetabling, Travelling Salesman Problems and Scheduling Problems with sequence dependent setup times. Comparisons with pure Constraint Programming approaches and related literature clearly show the benefits of the proposed approach.  相似文献   

17.
约束推理是人工智能中主要组成部分之一,可以解决实际优化调度和规划过程中的约束求解问题。这里在解释了约束逻辑程序设计的原理和过程基础上,打破封闭式约束逻辑程序设计系统,从软件工程上采用统一建模语言,提出一种新的开放的可扩展型约束逻辑程序设计结构系统。为实现可扩展的约束推理搜索系统,引进UML建模语言中用例图、类图和协作图。在建模基础上详细说明了可扩展约束逻辑程序设计中数学模型,搜索引擎和搜索驱动三者间的关系以及它们内部的工作内容。最后在描述系统结构后,提出了可扩展的内容。根据扩展因素,外界为满足更多的需要可扩展本系统的约束过滤器。  相似文献   

18.
In classical Constraint Satisfaction Problems (CSPs) knowledge is embedded in a set of hard constraints, each one restricting the possible values of a set of variables. However constraints in real world problems are seldom hard, and CSP's are often idealizations that do not account for the preference among feasible solutions. Moreover some constraints may have priority over others. Lastly, constraints may involve uncertain parameters. This paper advocates the use of fuzzy sets and possibility theory as a realistic approach for the representation of these three aspects. Fuzzy constraints encompass both preference relations among possible instantiations and priorities among constraints. In a Fuzzy Constraint Satisfaction Problem (FCSP), a constraint is satisfied to a degree (rather than satisfied or not satisfied) and the acceptability of a potential solution becomes a gradual notion. Even if the FCSP is partially inconsistent, best instantiations are provided owing to the relaxation of some constraints. Fuzzy constraints are thus flexible. CSP notions of consistency and k-consistency can be extended to this framework and the classical algorithms used in CSP resolution (e.g., tree search and filtering) can be adapted without losing much of their efficiency. Most classical theoretical results remain applicable to FCSPs. In the paper, various types of constraints are modelled in the same framework. The handling of uncertain parameters is carried out in the same setting because possibility theory can account for both preference and uncertainty. The presence of uncertain parameters leads to ill-defined CSPs, where the set of constraints which defines the problem is not precisely known.  相似文献   

19.
In this paper we establish the relationship between the syntax and semantics of a fuzzy temporal constraint logic (FTCL) proposed by Cárdenas et al. FTCL enables us to express interrelated events by means of fuzzy temporal constraints. Moreover, it provides a resolution principle for performing inferences which take these constraints into account. FTCL is compatible with the theoretical temporal reasoning model proposed by Marín et al. – the Fuzzy Temporal Constraint Networks (FTCN). The main contributions of this paper are, on the one hand, the proofs of the FTCL-deduction and the FTCL-refutation theorems, and, on the other, the proof of the soundness of the refutation by resolution in this formal system, together with an exhaustive study of its completeness.  相似文献   

20.
该文涉及的约束逻辑程序设计(CLP)是一在二叉树上进行搜索的过程,提高搜索效率是CLP的主要研究方向之一。在CLP中约束推理机是核心,由变量组、约束过滤器、临时容器、推理引擎组成。在介绍了约束推理机激活过滤器,对变量进行区间压缩后,提出引入变量事件,总结为三种类型:SINGLE、BOUND和DOMCHG,用于减少过滤器的激发次数。实验结果表明,变量事件能够促进约束推理机的搜索效率,缩短二叉树搜索的时间,可以更快寻找到答案。  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司    京ICP备09084417号-23

京公网安备 11010802026262号