Finite-state transducers and regular relations
A finite-state transducer (FST) is a finite automaton with the
labels on its transitions doubled and allowed to be , for a
transition table δ ⊆ Q × (Σ ∪ {}) × (Σ ∪ {}) × Q with
x:x 0
δ(q, x, x 0 , q 0 ) written q → q 0 .
The fst h→, F i computes the relation
x1 :x 0
x2 :x 0
{(x1 . . . xn , x10 . . . xn0 ) ∈ Σ∗ × Σ∗ | (∃q1 . . . qn ) q0 →1 q1 →2
xn :x 0
q2 · · · →n qn ∈ F }.
Finite-state transducers and regular relations
A finite-state transducer (FST) is a finite automaton with the
labels on its transitions doubled and allowed to be , for a
transition table δ ⊆ Q × (Σ ∪ {}) × (Σ ∪ {}) × Q with
x:x 0
δ(q, x, x 0 , q 0 ) written q → q 0 .
The fst h→, F i computes the relation
x1 :x 0
x2 :x 0
{(x1 . . . xn , x10 . . . xn0 ) ∈ Σ∗ × Σ∗ | (∃q1 . . . qn ) q0 →1 q1 →2
xn :x 0
q2 · · · →n qn ∈ F }.
N.B. x1 . . . xn and x10 . . . xn0 may have different lengths, as an xi
and/or xi0 can be (of length 0).
Finite-state transducers and regular relations
A finite-state transducer (FST) is a finite automaton with the
labels on its transitions doubled and allowed to be , for a
transition table δ ⊆ Q × (Σ ∪ {}) × (Σ ∪ {}) × Q with
x:x 0
δ(q, x, x 0 , q 0 ) written q → q 0 .
The fst h→, F i computes the relation
x1 :x 0
x2 :x 0
{(x1 . . . xn , x10 . . . xn0 ) ∈ Σ∗ × Σ∗ | (∃q1 . . . qn ) q0 →1 q1 →2
xn :x 0
q2 · · · →n qn ∈ F }.
N.B. x1 . . . xn and x10 . . . xn0 may have different lengths, as an xi
and/or xi0 can be (of length 0).
A relation between strings is regular if it is computed by some fst.
Prolog exercise
Define
fst(+Input, +Trans, +Final, ?Output)
Caution: consider fst computing 1 × 1+ given by
Trans = [[q0,[],1,q0], [q0,1,1,q1]]
Final = [q1]
That is, the length n of a pair (x1 . . . xn , x10 . . . xn0 ) no longer
bounds a run computing it.
Some regular relations
1. The factor relation
s hasFactor s 0 :⇔ (∃u, v ) s = us 0 v
Some regular relations
1. The factor relation
s hasFactor s 0 :⇔ (∃u, v ) s = us 0 v
2. The accepting runs of a finite automaton →, F
a
a
a
{ha1 a2 · · · an , q1 q2 · · · qn i | q0 →1 q1 →2 q2 · · · →n qn ∈ F }
mixing symbols/actions ai with states/situations qi
Some regular relations
1. The factor relation
s hasFactor s 0 :⇔ (∃u, v ) s = us 0 v
2. The accepting runs of a finite automaton →, F
a
a
a
{ha1 a2 · · · an , q1 q2 · · · qn i | q0 →1 q1 →2 q2 · · · →n qn ∈ F }
mixing symbols/actions ai with states/situations qi
3. The diagonal ∆L of a regular language L
∆L := {(s, s) | s ∈ L}
Some regular relations
1. The factor relation
s hasFactor s 0 :⇔ (∃u, v ) s = us 0 v
2. The accepting runs of a finite automaton →, F
a
a
a
{ha1 a2 · · · an , q1 q2 · · · qn i | q0 →1 q1 →2 q2 · · · →n qn ∈ F }
mixing symbols/actions ai with states/situations qi
3. The diagonal ∆L of a regular language L
∆L := {(s, s) | s ∈ L}
4. A-string-meronym ≥A on (2A )∗
α1 · · · αn ≥A x1 · · · xn
for α1 · · · αn ∈ (2A )∗ .
:⇔ xi = or xi ⊆ αi for 1 ≤ i ≤ n
Some closure properties
1. If R is regular, so is its inverse R −1 .
Some closure properties
1. If R is regular, so is its inverse R −1 .
2. If R and R 0 are regular, so are its union R ∪ R 0 and relational
composition
R; R 0 := {(s, s 0 ) | (∃s0 ) sRs0 and s0 R 0 s 0 } .
Some closure properties
1. If R is regular, so is its inverse R −1 .
2. If R and R 0 are regular, so are its union R ∪ R 0 and relational
composition
R; R 0 := {(s, s 0 ) | (∃s0 ) sRs0 and s0 R 0 s 0 } .
3. The restriction RL of a regular relation R to a regular
language L
RL := {(s, s 0 ) ∈ R | s ∈ L}
Some closure properties
1. If R is regular, so is its inverse R −1 .
2. If R and R 0 are regular, so are its union R ∪ R 0 and relational
composition
R; R 0 := {(s, s 0 ) | (∃s0 ) sRs0 and s0 R 0 s 0 } .
3. The restriction RL of a regular relation R to a regular
language L
RL := {(s, s 0 ) ∈ R | s ∈ L}
If R is a regular relation, then its image {s 0 | (∃s) sRs 0 } is regular
including
L ∩ L0 = image(∆L ; ∆L0 )
and the Peirce product
R −1 L := {s | (∃s 0 ∈ L) sRs 0 } = image(R −1 L )
Regular relations are not Boolean-closed
Regular relations are not closed under intersection —
{h0n , 1n 2m i | n ≥ 0, m ≥ 0} and {h0n , 1m 2n i | n ≥ 0, m ≥ 0}
P
are regular, but their intersection has image n≥0 1n 2n .
Regular relations are not Boolean-closed
Regular relations are not closed under intersection —
{h0n , 1n 2m i | n ≥ 0, m ≥ 0} and {h0n , 1m 2n i | n ≥ 0, m ≥ 0}
P
are regular, but their intersection has image n≥0 1n 2n .
Hence, the complement R of a regular relation R need not be
regular, as
R ∩ R0 = R ∪ R0
TM-actions via finite-state transducers
moveRight(q, a, q 0 )
moveLeft(q, a, q 0 )
write(q, a, a0 , q 0 )
~lqa~r
~la0 qa~r
~lqa~r
~laq 0~r
~lq 0 a0 a~r
~lq 0 a0~r
TM-actions via finite-state transducers
moveRight(q, a, q 0 )
moveLeft(q, a, q 0 )
write(q, a, a0 , q 0 )
~lqa~r
~la0 qa~r
~lqa~r
~laq 0~r
~lq 0 a0 a~r
~lq 0 a0~r
tape infinite to the right ~lq ≈ ~lq#
tape infinite to the left
q~r ≈ #q~r
TM-actions via finite-state transducers
moveRight(q, a, q 0 )
moveRight(q, #, q 0 )
moveLeft(q, a, q 0 )
moveLeft(q, a, q 0 )
moveLeft(q, #, q 0 )
moveLeft(q, #, q 0 )
write(q, a, a0 , q 0 )
write(q, #, a, q 0 )
~lqa~r
~lq
~laq 0~r
qa~r
~laq
q 0 #a~r
~lq 0 a
~l#q 0
~la0 qa~r
~lq 0 a0 a~r
q
q0
~lqa~r
~lq 0 a0~r
~lq
~lq 0 a
tape infinite to the right ~lq ≈ ~lq#
tape infinite to the left
q~r ≈ #q~r
TM-actions via finite-state transducers
moveRight(q, a, q 0 )
moveRight(q, #, q 0 )
moveLeft(q, a, q 0 )
moveLeft(q, a, q 0 )
moveLeft(q, #, q 0 )
moveLeft(q, #, q 0 )
write(q, a, a0 , q 0 )
write(q, #, a, q 0 )
~lqa~r
~lq
~laq 0~r
qa~r
~laq
q 0 #a~r
~lq 0 a
~l#q 0
~la0 qa~r
~lq 0 a0 a~r
q
q0
~lqa~r
~lq 0 a0~r
~lq
~lq 0 a
tape infinite to the right ~lq ≈ ~lq#
tape infinite to the left
q~r ≈ #q~r
For any Turing machine M, stepM is regular (finite tuples)
Finite-state approximations
Output extraction
via finite-state transducer
halt(q, a)
halt(q, #)
~lqa~r
~lq
unpad(~la~r )
unpad(~l)
n-step approximation of a TM M
n
Mn := {(s, s 0 ) | q0 s stepM
;
|
{z
s 0}
}
n
(∃x) q0 s stepM
x and x
Bounded iterations (time-out clock) are regular
[
input/output(M) =
Mn
n≥0
s0
© Copyright 2026 Paperzz