{"id":22102,"date":"2023-02-22T03:58:20","date_gmt":"2023-02-22T03:58:20","guid":{"rendered":"https:\/\/www.booksofall.com\/vi\/?post_type=product&#038;p=22102"},"modified":"2023-02-22T03:59:49","modified_gmt":"2023-02-22T03:59:49","slug":"gnu-prolog-manual","status":"publish","type":"product","link":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/","title":{"rendered":"GNU Prolog Manual"},"content":{"rendered":"<p>GNU Prolog is a free Prolog compiler with constraint solving over finite domains. For recent information about GNU Prolog please consult the <a href=\"http:\/\/www.gprolog.org\/\">GNU Prolog page<\/a>.<\/p>\n<p>GNU Prolog is a Prolog compiler based on the <a href=\"https:\/\/en.wikipedia.org\/wiki\/Warren_Abstract_Machine\">Warren Abstract Machine (WAM)<\/a>. It first compiles a Prolog program to a WAM file which is then translated to a low-level machine-independent language called mini-assembly specifically designed for GNU Prolog. The resulting file is then translated into the assembly language of the target machine (from which an object is obtained). This allows GNU Prolog to produce a native stand alone executable from a Prolog source (similarly to what does a C compiler from a C program). The main advantage of this compilation scheme is to produce native code and to be fast. Another interesting feature is that executables are small. Indeed, the code of most unused built-in predicates is not included in the executables at link time.<\/p>\n<p>A lot of work has been devoted to ISO compatibility. Indeed, GNU Prolog is very close to the <a href=\"https:\/\/en.wikipedia.org\/wiki\/International_Organization_for_Standardization\">ISO standard<\/a> for Prolog.<\/p>\n<p>GNU Prolog also offers various extensions very useful in practice (global variables, OS interface, sockets,&#8230;). In particular, GNU Prolog contains an efficient constraint solver over Finite Domains (FD). This opens constraint logic programming to the user combining the power of constraint programming to the declarativity of logic programming. The key feature of the GNU Prolog solver is the use of a single (lowlevel) primitive to define all (high-level) FD constraints. There are many advantages of this approach: constraints can be compiled, the user can define his own constraints (in terms of the primitive), the solver is open and extensible (as opposed to black-box solvers like CHIP),. . . Moreover, the GNU Prolog solver is rather efficient, often more than commercial solvers.<\/p>\n<p>GNU Prolog is inspired from two systems: \u2022 wamcc: a Prolog to C compiler. the key point of wamcc was its ability to produce stand alone executables using an original compilation scheme: the translation of Prolog to C via the <a href=\"https:\/\/www.wamtalent.org.hk\/\">WAM<\/a>. Its drawback was the time needed by gcc to compile the produced sources. GNU Prolog can also produce stand alone executables but using a faster compilation scheme.<\/p>\n<p>\u2022 <a href=\"https:\/\/www.swi-prolog.org\/man\/clpfd.html\">clp(FD)<\/a>: a constraint programming language over FD. Its key feature was the use of a single primitive to define FD constraints. GNU Prolog is based on the same idea but offers an extended constraint definition language. In comparison to clp(FD), GNU Prolog offers new predefined constraints, new predefined heuristics, reified constraints,. . .<\/p>\n<p>Here are some features of GNU Prolog:<\/p>\n<p>\u2022 Prolog system:<\/p>\n<p>\u2013 conforms to the ISO standard for Prolog (floating point numbers, streams, dynamic code,. . . ).<\/p>\n<p>\u2013 a lot of extensions: global variables, definite clause grammars (DCG), sockets interface, operating system interface,. . .<\/p>\n<p>\u2013 more than 300 Prolog built-in predicates.<\/p>\n<p>\u2013 Prolog debugger and a low-level WAM debugger.<\/p>\n<p>\u2013 line editing facility under the interactive interpreter with completion on atoms.<\/p>\n<p>\u2013 powerful bidirectional interface between Prolog and C.<\/p>\n<p>\u2022 Compiler:<\/p>\n<p>\u2013 native-code compiler producing stand alone executables.<\/p>\n<p>\u2013 simple command-line compiler accepting a wide variety of files: Prolog files, C files, WAM files,. . .<\/p>\n<p>\u2013 direct generation of assembly code 15 times faster than wamcc + gcc.<\/p>\n<p>\u2013 most of unused built-in predicates are not linked (to reduce the size of the executables).<\/p>\n<p>\u2013 compiled predicates (native-code) as fast as wamcc on average.<\/p>\n<p>\u2013 consulted predicates (byte-code) 5 times faster than wamcc.<\/p>\n<p>\u2022 Constraint solver:<\/p>\n<p>\u2013 FD variables well integrated into the Prolog environment (full compatibility with Prolog variables and integers). No need for explicit FD declarations.<\/p>\n<p>\u2013 very efficient FD solver (comparable to commercial solvers).<\/p>\n<p>\u2013 high-level constraints can be described in terms of simple primitives.<\/p>\n<p>\u2013 a lot of predefined constraints: arithmetic constraints, boolean constraints, symbolic constraints, reified constraints,. . .<\/p>\n<p>\u2013 several predefined enumeration heuristics.<\/p>\n<p>\u2013 the user can define his own new constraints.<\/p>\n<p>\u2013 more than 50 FD built-in constraints\/predicates.<\/p>\n","protected":false},"excerpt":{"rendered":"<p><iframe style=\"width: 100%; height: 700px; border: none;\" src=\"https:\/\/online.visual-paradigm.com\/share\/book\/gprolog-19l2rokjri?enforceShowPromotionBar=true&amp;p=1\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/p>\n","protected":false},"featured_media":22106,"template":"","meta":{"_yoast_wpseo_title":"","_yoast_wpseo_metadesc":""},"product_brand":[],"product_cat":[363],"product_tag":[],"class_list":{"0":"post-22102","1":"product","2":"type-product","3":"status-publish","4":"has-post-thumbnail","6":"product_cat-prolog","8":"first","9":"instock","10":"shipping-taxable","11":"product-type-simple"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>GNU Prolog Manual - BooksOfAll Vietnamese<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/\" \/>\n<meta property=\"og:locale\" content=\"vi_VN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"GNU Prolog Manual - BooksOfAll Vietnamese\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/\" \/>\n<meta property=\"og:site_name\" content=\"BooksOfAll Vietnamese\" \/>\n<meta property=\"article:modified_time\" content=\"2023-02-22T03:59:49+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:image\" content=\"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png\" \/>\n<meta name=\"twitter:label1\" content=\"\u01af\u1edbc t\u00ednh th\u1eddi gian \u0111\u1ecdc\" \/>\n\t<meta name=\"twitter:data1\" content=\"3 ph\u00fat\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/\",\"url\":\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/\",\"name\":\"GNU Prolog Manual - BooksOfAll Vietnamese\",\"isPartOf\":{\"@id\":\"https:\/\/www.booksofall.com\/vi\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png\",\"datePublished\":\"2023-02-22T03:58:20+00:00\",\"dateModified\":\"2023-02-22T03:59:49+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#breadcrumb\"},\"inLanguage\":\"vi\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"vi\",\"@id\":\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#primaryimage\",\"url\":\"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png\",\"contentUrl\":\"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png\",\"width\":\"532\",\"height\":\"729\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.booksofall.com\/vi\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Categories\",\"item\":\"https:\/\/www.booksofall.com\/vi\/categories\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"GNU Prolog Manual\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.booksofall.com\/vi\/#website\",\"url\":\"https:\/\/www.booksofall.com\/vi\/\",\"name\":\"BooksOfAll Vietnamese\",\"description\":\"Biggest IT eBooks library and learning resources - Free eBooks for programming, computing, artificial intelligence and more.\",\"publisher\":{\"@id\":\"https:\/\/www.booksofall.com\/vi\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.booksofall.com\/vi\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"vi\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.booksofall.com\/vi\/#organization\",\"name\":\"BooksOfAll Vietnamese\",\"url\":\"https:\/\/www.booksofall.com\/vi\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"vi\",\"@id\":\"https:\/\/www.booksofall.com\/vi\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2022\/06\/booksofall-logo-2.png\",\"contentUrl\":\"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2022\/06\/booksofall-logo-2.png\",\"width\":166,\"height\":30,\"caption\":\"BooksOfAll Vietnamese\"},\"image\":{\"@id\":\"https:\/\/www.booksofall.com\/vi\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"GNU Prolog Manual - BooksOfAll Vietnamese","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/","og_locale":"vi_VN","og_type":"article","og_title":"GNU Prolog Manual - BooksOfAll Vietnamese","og_url":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/","og_site_name":"BooksOfAll Vietnamese","article_modified_time":"2023-02-22T03:59:49+00:00","og_image":[{"url":"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png","type":"","width":"","height":""}],"twitter_card":"summary_large_image","twitter_image":"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png","twitter_misc":{"\u01af\u1edbc t\u00ednh th\u1eddi gian \u0111\u1ecdc":"3 ph\u00fat"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/","url":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/","name":"GNU Prolog Manual - BooksOfAll Vietnamese","isPartOf":{"@id":"https:\/\/www.booksofall.com\/vi\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#primaryimage"},"image":{"@id":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#primaryimage"},"thumbnailUrl":"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png","datePublished":"2023-02-22T03:58:20+00:00","dateModified":"2023-02-22T03:59:49+00:00","breadcrumb":{"@id":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#breadcrumb"},"inLanguage":"vi","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/"]}]},{"@type":"ImageObject","inLanguage":"vi","@id":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#primaryimage","url":"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png","contentUrl":"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2023\/02\/img_63f590d053432.png","width":"532","height":"729"},{"@type":"BreadcrumbList","@id":"https:\/\/www.booksofall.com\/vi\/gnu-prolog-manual\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.booksofall.com\/vi\/"},{"@type":"ListItem","position":2,"name":"Categories","item":"https:\/\/www.booksofall.com\/vi\/categories\/"},{"@type":"ListItem","position":3,"name":"GNU Prolog Manual"}]},{"@type":"WebSite","@id":"https:\/\/www.booksofall.com\/vi\/#website","url":"https:\/\/www.booksofall.com\/vi\/","name":"BooksOfAll Vietnamese","description":"Biggest IT eBooks library and learning resources - Free eBooks for programming, computing, artificial intelligence and more.","publisher":{"@id":"https:\/\/www.booksofall.com\/vi\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.booksofall.com\/vi\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"vi"},{"@type":"Organization","@id":"https:\/\/www.booksofall.com\/vi\/#organization","name":"BooksOfAll Vietnamese","url":"https:\/\/www.booksofall.com\/vi\/","logo":{"@type":"ImageObject","inLanguage":"vi","@id":"https:\/\/www.booksofall.com\/vi\/#\/schema\/logo\/image\/","url":"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2022\/06\/booksofall-logo-2.png","contentUrl":"https:\/\/www.booksofall.com\/vi\/wp-content\/uploads\/sites\/10\/2022\/06\/booksofall-logo-2.png","width":166,"height":30,"caption":"BooksOfAll Vietnamese"},"image":{"@id":"https:\/\/www.booksofall.com\/vi\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/product\/22102","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/product"}],"about":[{"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/types\/product"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/media\/22106"}],"wp:attachment":[{"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/media?parent=22102"}],"wp:term":[{"taxonomy":"product_brand","embeddable":true,"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/product_brand?post=22102"},{"taxonomy":"product_cat","embeddable":true,"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/product_cat?post=22102"},{"taxonomy":"product_tag","embeddable":true,"href":"https:\/\/www.booksofall.com\/vi\/wp-json\/wp\/v2\/product_tag?post=22102"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}