turing-complete

Why is mov turing complete?

回眸只為那壹抹淺笑 提交于 2021-02-13 11:41:48
问题 I found this recently: https://github.com/xoreaxeaxeax/movfuscator It seems to be contingent on the fact that mov is turing-complete. Is that true, and why? 回答1: Yes, x86's mov is Turing complete. I added that tag to your question because it may not be true for other ISAs with an instruction called mov , and the movfuscator compiler only targets x86. It's not "mov" itself doing computation , it's x86 addressing modes which can do addition (and bit-shift). I haven't looked in detail at how it

Why is mov turing complete?

北城余情 提交于 2021-02-13 11:41:27
问题 I found this recently: https://github.com/xoreaxeaxeax/movfuscator It seems to be contingent on the fact that mov is turing-complete. Is that true, and why? 回答1: Yes, x86's mov is Turing complete. I added that tag to your question because it may not be true for other ISAs with an instruction called mov , and the movfuscator compiler only targets x86. It's not "mov" itself doing computation , it's x86 addressing modes which can do addition (and bit-shift). I haven't looked in detail at how it

Is pure Prolog Turing-complete, and if so, why can't it implement list intersection?

∥☆過路亽.° 提交于 2021-02-04 04:58:19
问题 The Wikipedia section on this topic is a mess. It states: Pure Prolog is based on a subset of first-order predicate logic, Horn clauses, which is Turing-complete. Turing completeness of Prolog can be shown by using it to simulate a Turing machine: (emphasis added) And then it goes on to show code that uses things that are not Horn clauses ( ! and once ): turing(Tape0, Tape) :- perform(q0, [], Ls, Tape0, Rs), reverse(Ls, Ls1), append(Ls1, Rs, Tape). perform(qf, Ls, Ls, Rs, Rs) :- !. perform(Q0

Is pure Prolog Turing-complete, and if so, why can't it implement list intersection?

喜夏-厌秋 提交于 2021-02-04 04:56:57
问题 The Wikipedia section on this topic is a mess. It states: Pure Prolog is based on a subset of first-order predicate logic, Horn clauses, which is Turing-complete. Turing completeness of Prolog can be shown by using it to simulate a Turing machine: (emphasis added) And then it goes on to show code that uses things that are not Horn clauses ( ! and once ): turing(Tape0, Tape) :- perform(q0, [], Ls, Tape0, Rs), reverse(Ls, Ls1), append(Ls1, Rs, Tape). perform(qf, Ls, Ls, Rs, Rs) :- !. perform(Q0

Is pure Prolog Turing-complete, and if so, why can't it implement list intersection?

与世无争的帅哥 提交于 2021-02-04 04:56:29
问题 The Wikipedia section on this topic is a mess. It states: Pure Prolog is based on a subset of first-order predicate logic, Horn clauses, which is Turing-complete. Turing completeness of Prolog can be shown by using it to simulate a Turing machine: (emphasis added) And then it goes on to show code that uses things that are not Horn clauses ( ! and once ): turing(Tape0, Tape) :- perform(q0, [], Ls, Tape0, Rs), reverse(Ls, Ls1), append(Ls1, Rs, Tape). perform(qf, Ls, Ls, Rs, Rs) :- !. perform(Q0

Halting in non-Turing-complete languages

耗尽温柔 提交于 2020-01-12 13:54:54
问题 The halting problem cannot be solved for Turing complete languages and it can be solved trivially for some non-TC languages like regexes where it always halts. I was wondering if there are any languages that has both the ability to halt and not halt but admits an algorithm that can determine whether it halts. 回答1: Yes. One important class of this kind are primitive recursive functions. This class includes all of the basic things you expect to be able to do with numbers (addition,

Halting in non-Turing-complete languages

自作多情 提交于 2020-01-12 13:53:52
问题 The halting problem cannot be solved for Turing complete languages and it can be solved trivially for some non-TC languages like regexes where it always halts. I was wondering if there are any languages that has both the ability to halt and not halt but admits an algorithm that can determine whether it halts. 回答1: Yes. One important class of this kind are primitive recursive functions. This class includes all of the basic things you expect to be able to do with numbers (addition,

The type system in Scala is Turing complete. Proof? Example? Benefits?

梦想的初衷 提交于 2019-12-28 02:38:29
问题 There are claims that Scala's type system is Turing complete. My questions are: Is there a formal proof for this? How would a simple computation look like in the Scala type system? Is this of any benefit to Scala - the language? Is this making Scala more "powerful" in some way compared languages without a Turing complete type system? I guess this applies to languages and type systems in general. 回答1: There is a blog post somewhere with a type-level implementation of the SKI combinator

Can a language be Turing-complete without any support for arrays?

给你一囗甜甜゛ 提交于 2019-12-23 10:06:17
问题 If a language has control structures and variables, but no support for arrays, lists, memory access and allocation, etc, can it be Turing-complete? Maybe if there was no limit to the amount of variables you can create, you can simulate arrays by creating variables like array_1 , array_2 , ... array_6000 and manually loop through them, and somehow create complex data structures and recursion? Edit : Even if you cannot access variables by name manipulation ( array_10+i is not allowed)? 回答1:

Why can Conway’s Game of Life be classified as a universal machine?

痴心易碎 提交于 2019-12-18 09:59:30
问题 I was recently reading about artificial life and came across the statement, "Conway’s Game of Life demonstrates enough complexity to be classified as a universal machine." I only had a rough understanding of what a universal machine is, and Wikipedia only brought me as close to understanding as Wikipedia ever does. I wonder if anyone could shed some light on this very sexy statement? Conway's Game of Life seems, to me, to be a lovely distraction with some tremendous implications: I can't make