Sparse Maps

From Adam Colton
Revision as of 21:11, 28 June 2017 by Adamcolton (talk | contribs) (Created page with "Given any sparse map, it should be possible to create a function that very efficiently represents it. What I really want is a very efficient way to do DFA's. Given a State an...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Given any sparse map, it should be possible to create a function that very efficiently represents it.

What I really want is a very efficient way to do DFA's. Given a State and a Rune, return the next state in linear time, no hashing. The State also needs to indicate if it's accepting or an error. That could be done with ranges; 50-1000 is accepting, >1000 is an error. This would also mean it's ok for for some values that should be errors to not immediately be, so long as you can never get back to an accepting state with valid input.