Upgrade to Pro — share decks privately, control downloads, hide ads and more …

TM_multitape

Chen
October 06, 2022

 TM_multitape

Chen

October 06, 2022
Tweet

More Decks by Chen

Other Decks in Science

Transcript

  1. Multi-tape TM 0: t 0 0 0 1 + 1

    0 0 1 = 1 0 1 0 t 1: t t t t t t t t t t t t t t t t 2: t t t t t t t t t t t t t t t t We start with input on tape 0. Other tapes are blank. 10 / 27
  2. Multi-tape TM 0: t t t t t + 1

    0 0 1 = 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t t t t t t t t t t t t t t t t We can copy the first operand to tape 1, crossing it off as we go 11 / 27
  3. Multi-tape TM 0: t t t t t t t

    t t t = 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t 1 0 0 1 t t t t t t t t t t t We can copy the second operand to tape 2, crossing it off as we go 12 / 27
  4. Multi-tape TM 0: t t t t t t t

    t t t t 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t 1 0 0 1 t t t t t t t t t t t We scan to the end 13 / 27
  5. Multi-tape TM 0: t t t t t t t

    t t t t 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t 1 0 0 1 t t t t t t t t t t t Move left once on all tapes, and then just check each digit one by one, moving left. Remember carry in state. Carry in = 0 Carry out = 1 14 / 27
  6. Multi-tape TM 0: t t t t t t t

    t t t t 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t 1 0 0 1 t t t t t t t t t t t Carry in = 1 Carry out = 0 15 / 27
  7. Multi-tape TM 0: t t t t t t t

    t t t t 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t 1 0 0 1 t t t t t t t t t t t Carry in = 0 Carry out = 0 16 / 27
  8. Multi-tape TM 0: t t t t t t t

    t t t t 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t 1 0 0 1 t t t t t t t t t t t Carry in = 0 Carry out = 0 17 / 27
  9. Multi-tape TM 0: t t t t t t t

    t t t t 1 0 1 0 t 1: t 0 0 0 1 t t t t t t t t t t t 2: t 1 0 0 1 t t t t t t t t t t t Carry in = 0 All tapes on t Accept! 18 / 27