-
Notifications
You must be signed in to change notification settings - Fork 0
/
recognizingfinitelanguages.html
51 lines (51 loc) · 1.95 KB
/
recognizingfinitelanguages.html
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
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<title>RIPAL: Responsive and Intuitive Parsing for the Analysis of Language</title>
<link href="styles/styles.css" rel="stylesheet" type="text/css" media="all"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
</head>
<body>
<h1>RIPAL: Responsive and Intuitive Parsing for the Analysis of Language</h1>
<h2>Pages</h2>
<nav aria-label="Pages">
<ul>
<li><a href="index.html">Home</a></li>
<li><a href="theory.html">Theory</a></li>
<li><a href="contact.html">Contact</a></li>
</ul>
</nav>
<h2>Recognizing finite languages</h2>
<div class="section">
<h3>Problem statement</h3>
<p>Given a finite language L and an input string s, how do we determine whether s ∈ L?</p>
</div>
<div class="section">
<h3>Algorithm</h3>
<div class="code">For each string l ∈ L
If s = l
Return true
Return false</div>
</div>
<div class="section">
<h3>Examples</h3>
<div class="subsection example">
<p><em>Example</em></p>
<p>Σ = {red, yellow, blue, orange, purple, green}</p>
<p>L = {red, yellow, blue}</p>
<p>red ∈ L, since the matching element red appears in its definition.</p>
<p>green ∉ L, since the matching element does not appear in its definition.</p>
</div>
<div class="subsection example">
<p><em>Example</em></p>
<p>Σ = {0, 1}</p>
<p>L = {00, 01, 10, 11}</p>
<p>11 ∈ L, since the matching element 11 appears in its definition.</p>
<p>111 ∉ L, since the matching element does not appear in its definition.</p>
</div>
</div>
<hr/>
<p>GitHub Repository: <a href="https://github.com/bprollinson/ripal">https://github.com/bprollinson/ripal</a></p>
<p>Copyright © 2017 Brendan Rollinson-Lorimer</p>
</body>
</html>