How to define delta in a PDA

168 views Asked by At

I'm a little confused about PDA's and how to define the tuple. I have the language L = { 0^n1^n | n >= 0 } and I know that PDA's are six tuple with Q, sigma, gamma, delta, q0, and F. I know how to define all of them except delta.

Q = ['q1', 'q2', 'q3', 'q4'] 
sig = ['0', '1']
gam = ['0', '$']
delta = ?
q0 = 'q1'
F = ['q1', 'q4']

Can anyone help me understand how delta is defined?

1

There are 1 answers

0
Nikolay Handzhiyski On

One transition in a PDA is made of the tuple (s, i, A, d, B), where:

  • s is the source state that the automaton must currently be at to be able to use the transition
  • i (i in Sigma or epsilon) has to be the current character in the input to be able to use the transition, and it will be read from the input if the transition is used
  • A (A in Gamma*) are the symbols that has to be on top of the stack to be able to use the transition
  • d is the destination state (where the automaton will move to by the use of the transition)
  • B (B in Gamma*) are the symbols that will replace A on the top of the stack, if the transition is used.

The transitions for this language are written in the example section in Wikipedia.