Longest Zigzag Method
Can you provide a detailed explanation of how to get the answers from the given transition function and how the transition function works in this case?
Problem 4 [28 points]
Consider the Turing machine M = (Q, Σ, Γ, δ, q0, F) such that:
Q = {q, p, r, t, y}
Σ = {a, b, c}
Γ = {B, a, b, c, g, A, D}
F = {v}
The transition function δ is defined by the following transition set:
δ(q, a) = (p, a, R)
δ(p, a) = (r, a, R)
δ(r, a) = (a, R)
δ(a, R) = (q, B, R)
δ(q, b) = (p, b, R)
δ(p, b) = (p, b, R)
δ(r, b) = (b, R)
δ(a, B) = (q, B, R)
δ(q, c) = (c, R)
δ(p, c) = (p, c, R)
δ(r, c) = (g, R)
δ(a, A) = (q, A, R)
δ(q, D) = (p, D, R)
δ(p, D) = (c, R)
δ(r, D) = (r, R)
δ(q, g) = (q, g, R)
δ(p, g) = (r, g, R)
δ(r, g) = (r, R)
Write a regular expression that defines L. If such a regular expression does not exist, prove it.
Answer: (a+c)*b(a+c)*g
δ(q, a) = (c, R)
δ(p, a) = (c, R)
δ(r, a) = (c, R)
δ(a, R) = (q, B, R)
δ(q, b) = (q, b, R)
δ(p, b) = (p, b, R)
δ(r, b) = (b, R)
Write a regular expression that defines L. If such a regular expression does not exist, prove it.
Answer: b(a+c)*b
List four distinct strings that belong to L. If this is impossible, state it and explain why it is so.
Answer: bqa, aa, ab, ah
List four distinct strings that belong to L. If this is impossible, state it and explain why it is so.
Answer: bb, bc
Note: This problem continues on the following page.