Transforming multi-tape Turing machines to equivalent single-tape Turing machines

We know that multi-tape Turing machines have the same computational power as single-tape ones. So every $ k$ -tape Turing machine has an equivalent single-tape Turing machine.

About the computability and complexity analysis of such a transformation:

Is there a computable function that receives as input an arbitrary multi-tape Turing machine and returns an equivalent single-tape Turing machine in polynomial time and polynomial space?

What is the AC equivalent of mirror image?

It is suggested (by the DMG) to account for defensive options by assuming increased AC, e.g. +2 AC for magic resistance.

I would like to give some of my monsters the spell mirror image as part of a spellcasting / innate spellcasting trait. There is precedence for this: the Alhoon, the Faerie Dragon, and the Lamia have it, for example.

What would be a rough estimate of the AC equivalent for mirror image for the purpose of determining CR / combat performance?

Tangentially related (compares mirror image to other spells for PCs concerning the defensive capabilities): What's my most efficient use of spell slots to help my AC?

Are these two methods of handling Elven Accuracy “Double Advantage” mathematically equivalent?

For context, part of the Elven Accuracy feat (Xanathar’s Guide to Everything, p. 74) states:

Whenever you have advantage on an attack roll using Dexterity, Intelligence, Wisdom, or Charisma, you can reroll one of the dice once.

So the obvious way to handle this, mechanically, is to roll two dice, pick the lowest, and roll it again. But as an effort to save time, I’ve proposed instead simply rolling three dice simultaneously, and picking the highest rolled value.

The problem is that I’m not certain that this is mathematically correct.

I created a code simulation that was intended to model the probability curve of both methods, and it suggests that the two methods are mathematically equivalent, but the simulation only performs direct sampling of random numbers and their results; it has unavoidable error in the results, and it doesn’t attempt to solve the underlying mathematical principles involved.

//Roll 3, pick highest ResultSet: Double Advantage      Average: 15.48246                                                                                                      Variance: 14.94721234837884                                                                                            Std. Deviation: 3.8661624834425727                                                                                     95% range: [6, 20]                                                                                                     Mode: 20                                                                                                               Median: 16         //Roll 2, reroll lowest, pick highest ResultSet: Alternate Double Advantage                                                                                      Average: 15.488486                                                                                                     Variance: 14.944649427739675                                                                                           Std. Deviation: 3.8658310138623073                                                                                     95% range: [6, 20]                                                                                                     Mode: 20                                                                                                               Median: 16             

Is it correct to say that these two dice-rolling methods are equivalent, or should I stick to the RAW interpretation of how these dice should be rolled?

For full context, I’m planning out a build for a Shadow Sorcerer that fights only in melee combat, and if this character has the ability to nearly-permanently shroud themselves in Darkness (which is one of their class features), it’ll give them nearly permanent Advantage against creatures that don’t have Devil’s Sight or Truesight (or a reliable, spammable Counterspell/Dispel Magic). So simplifying this roll can matter in terms of time saved.

Is my recursive algorithm for Equivalent Words correct?

Here is my problem.

Problem Given two words and a dictionary, find out whether the words are equivalent.

Input: The dictionary, D (a set of words), and two words v and w from the dictionary.

Output: A transformation of v into w by substitutions such that all intermediate words belong to D. If no transformation is possible, output “v and w are not equivalent.”

I need to write both recursive and dynamic programming algorithm. As for recursion, I came up with this algorithm. Is it correct?

 EquivalentWordsProblem(v, w, D)  1.m <- len (v)  2.n <-  len (w)  3.substitutions = [] #array to save substitutions   4.if m != n:  5.  return "v and w are not equivalent"  6.else  7.for i <- m to 1 <-1 do  8.  for j <- n to j <- 1 do  9.    if v[i] != w[j]:  10.           substituted_word <- v[1…i-1]+v[j] #we substitute v[i] for w[j]  11.              if substituted_word in D:  12.                substitutions.append(substituted_word)  13.                   return EquivalentWordsProblem(v[1…m-i], w, D) #recur on the string of length m - i  14.   else:          return EquivalentWordsProblem(v[1…m-1], w, D) #recur on the string decreasing its length by 1  15.if len(substitutions) != 0:  16.  return substitutions   17.else  18.   return (“v and w are not equivalent”)  

Is checking if regular languages are equivalent decidable?

Is this problem algorithmically decidable?

L1 and L2 are both regular languages with alphabet $ \Sigma$ . Does L1 = L2?

I think that it is decidable because you can write regular expressions for each language and see if they are the same. But I’m not sure how to prove it since I see that you prove something is decidable by showing a Turing Machine

Are Online Problems always harder than the Offline equivalent?

I am currently studying Online-Algorithms, and I just asked myself if online Problems are always harder than the offline equivalent.

The most probable answer ist yes, but I can’t figure the reason out why.

Actually I have a second more specific question. When an offline Problem has some integrality gap ($ IG\in[1,\infty) $ ) we know in an offline setting, that there is generally no randomized rounding algorithm which achieves a ratio $ C\geq IG$ .

Can this just be adapted to the online problem? If some fractional algorithm has competitive ratio $ c_{frac}$ can some randomized rounding scheme only reach competitive ratio as good as $ \frac{c_{frac}}{IG}$ ?

Thanks in advance.

Analysis of kd-tree, how is the vertical line L’s intersect areas equivalent to sqrt(N)?

I’m trying to understand how the number of intersected areas by a vertical line in a KD-tree is equivalent to sqrt(n)

If you draw a balanced KD-tree with 7 nodes.
enter image description here

And then draw a vertical line l.

enter image description here

The number of areas this line intersects should be equivalent to sqrt(N) where N is amount of nodes. (7)

When I count the areas the vertical line L intersects I get 5. But sqrt(7) = 2,6 not even close.

Both sources get to the recurrence:

enter image description here

Which solves to O(sqrt(N)).

What am I doing wrong?


Source 1

Source 2

What is the equivalent of Skull Trap or Glyph of Warding in Savage Worlds?

I am converting Return to the Keep on the Borderlands into a Savage Worlds test. Mainly because that adventure is very localized and has all the basic role-playing elements (Hack and Slash, Intrigue, Mystery, Diplomacy etc.) which makes is a good testing ground for my players and I to feel out the system as a possibility of a full move from 5E.

As I was converting some of the encounters and monsters I stumbled across a place where there were what amounted to what would be considered in 5E as a Glyph or in an old Dragon article a Skull Trap.

Basically, Skull Trap was a 2nd or 3rd level Necromantic spell that allowed the caster to imbue an intact skull to be more or less like a landmine. If disturbed it would explode and all in the radius would take damage.

Since Savage Worlds leans mostly on Power Points and they regenerate insanely fast I have seen that they tend to essentially invest the Power Points and they don’t regain them until the trap is triggered.

Are there other ways to adjudicate this? I realize there are a number of settings out there with varying magic systems and I have seen the Savage Vancian versions but they don’t seem to really work for me.

Essentially, is there a way for a power to be used to create a trap that lasts indefinitely without investment of Power Points and if so what are the balance issues of allowing this? I had thought to allow it but increase the casting time significantly for long standing effects.

Are DPDAs accepting on final state equivalent to DPDAs accepting on empty stack equivalent?

Say I have a string x that is accepted by some DPDA P that accepts empty stack. Intuitively it’s seems impossible for P to accept any string x.y for any y != epsilon. The below DPDA accepts on final states all strings the language {a,b}* having an equal number of a’s and b’s.


Is it possible to transform this to a DPDA accepting on empty stack, i.e. are DPDAs accepting on final states and DPDAs accepting on empty stack equivalent?

Under what kind of oralces are $P$ and $NP$ equivalent?

How strong have the oracles needed to be for these two classes to be proven equivalent with respect to them?

For instance: is $ P^H$ = $ NP^H$ (ie. is $ P$ equipped with an oracle to solve the halting problem equivalent to $ NP$ equipped with an oracle to solve the halting problem)?

From Theodore Baker, John Gill, and Robert Solovay. Relativization of the P=?NP problem. Siam Journal of Computing, 4:432-442, 1975 [219] we know $ NP^A =P^A$ for their oracle A (which is a decision algorithm for a PSPACE complete problem).

If the oracle can perform an infinite amount of computation and return back the result in one step are these classes equal with respect to an oracle of this type? How about weaker ones? What is the weakest oracle we know of where $ P$ and $ NP$ are equal with respect to it?

An answer I’m looking for is something like: $ P^O$ =$ NP^O$ with respect to an oracle O and any oracle more powerful than it.