Tilted Forum Project Discussion Community  

Go Back   Tilted Forum Project Discussion Community > The Academy > Tilted Knowledge and How-To


 
 
LinkBack Thread Tools
Old 02-23-2004, 08:51 PM   #1 (permalink)
Crazy
 
Location: Raleigh, NC
Finite Automata question

If I am supposed to define a finite state machine for an expression described as:

w is in (0,1)* and |w|[0] mod 3 = 1

what languages does that machine accept?

My main question is, what does the |w|[0] mean?

The []'s mean subscript...

Thanks
__________________
"Good artists copy, great artists steal." - Pablo Picasso
Digilogic is offline  
Old 03-09-2004, 03:47 PM   #2 (permalink)
Addict
 
Location: Grey Britain
Hmm. Don't know for certain about the notation in this specific context, but the |w| would mean the absolute value of w in the only context I've come across it before. That is to say take your value of w and get rid of any minus sign if there is one.

if w=x; |w|=x
if w=-x; |w|=x

easy
__________________
"No one was behaving from very Buddhist motives. Then, thought Pigsy, he was hardly a Buddha, nor was he a monkey. Presently, he was a pig spirit changed into a little girl pretending to be a little boy to be offered to a water monster. It was all very simple to a pig spirit."
John Henry is offline  
Old 03-17-2004, 06:21 PM   #3 (permalink)
Insane
 
AngelicVampire's Avatar
 
| also means OR

W[0] is the initial case...

So you have to accept: any number in the 0-1 range, or a number divisible by 3 but only if its the initial number...

so:

Init: Nmod3 -> Acceptor
.......0<N<1 -> Acceptor
......else -> fail and no other states
Transitions: 0<N<1 -> Acceptor
N<0|N>1 -> Fail and no other state

Something like that?
AngelicVampire is offline  
 

Tags
automata, finite, question

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -8. The time now is 06:37 PM.

Tilted Forum Project

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Search Engine Optimization by vBSEO 3.6.0 PL2
© 2002-2012 Tilted Forum Project

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62