1 / 6

תרגול חזרה לבוחן אמצע

תרגול חזרה לבוחן אמצע. אביב - תשס"ד. שפות רגולריות - 1. הוכיחו או הפריכו את רגולריות השפות הבאות: L 1 = { w | w  { a , b }*  # a ( w ) = # b ( w ) } L 2 = { a i b j | i  j } L 3 = { a n b k c m | 0< k , k < m , m 2 < n <10 k }

gen
Download Presentation

תרגול חזרה לבוחן אמצע

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. תרגול חזרה לבוחן אמצע אביב - תשס"ד

  2. שפות רגולריות - 1 • הוכיחו או הפריכו את רגולריות השפות הבאות: • L1 = { w | w{a,b}*  #a(w) = #b(w) } • L2 = { aibj | ij } • L3 = { anbkcm | 0<k, k<m, m2<n<10k } • L4 = { w | w{a,b}* w=wR } • L5= {wxwR | w,x{a,b}* }

  3. שפות רגולריות - 2 הוכיחו או הפריכו: • (שאלה ממבחן חורף תשס"ב מועד ב') יהי A אוטומט סופי בעל n מצבים. השפה הבאה אינה רגולרית: L’ = { w | wL(A) , |w|>n } • בהינתן שפה L, נגדיר: L1={vw | vL, wL}. • אם L רגולרית, L1 רגולרית. • אם L1 רגולרית, L רגולרית.

  4. ביטויים רגולריים (שאלה מבוחן 1 חורף תשס"ד מועד א') • עבור א"ב , יהי R אוסף כל הביטויים הרגולריים מעל . הגדר אינדוקטיבית את RR, כך שיתקיים: R={ rR | L[r]= } הוכח את תשובתך. • הגדר את RR : R={ rR | L[r]={} }

  5. אוטומט אי-דטרמיניסטי • תהי L שפה רגולרית. הוכח כי השפה: Cycle(L)={yx | xyL , x,y* } רגולרית, ע"י בניית אוטומט.

  6. תכונות סגור • L1, L2 שפות רגולריות מעל א"ב , $. הוכח כי השפה: L={w1$w2 | w1,w2, w1L1 or w2L2} רגולרית.

More Related