top | item 31644620

(no title)

chrismaeda | 3 years ago

Prolog is cool but has exponential complexity which makes it impractical for real world use.

The rete algorithm was supposed to be a solution but has anyone applied rete to a prolog implementation yet?

discuss

order

aarroyoc|3 years ago

Isn't RETE a forward-chaining algorithm while Prolog is a backward-chaining language? I'm not sure you could use RETE for the actual Prolog semantics. Currently, fast implementations of Prolog use a virtual machine, the most popular is WAM, that can be compiled then to machine code (GNU Prolog does it). Also some implementations have JIT indexing, which improves performance too.

simplify|3 years ago

Prolog itself does not have exponential complexity. It depends on the problem you're solving.