-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
65 lines (64 loc) · 3.25 KB
/
index.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Directed Graph Editor</title>
<link rel="icon" type="image/png" href="favicon.ico">
<link rel="stylesheet" href="app.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css" integrity="sha384-PsH8R72JQ3SOdhVi3uxftmaW6Vc51MKb0q5P2rRUpPvrszuE4W1povHYgTpBfshb" crossorigin="anonymous">
<script src="d3.v3.min.js"></script>
</head>
<body>
<h1>Binary Relations: An Interactive Diagram</h1>
<iframe sandbox="allow-popups allow-scripts allow-forms allow-same-origin" src="d3display.html" marginwidth="0" marginheight="0" style="height:500px;" scrolling="no"></iframe>
<div class="container">
<div class="row buffer">
<div class="col-md-6">
<h2>Instructions</h2>
<ul>
<li>Click and drag to create new edges</li>
<li>Selected edges are marked by dotted lines</li>
<li>To delete edges, select and edge and press Delete</li>
<li>Edges can only be drawn from the Domain to the Co-Domain</li>
</ul>
This is a simple interactive diagram created to help students in discrete math recognize and test different types of binary relations.
</div>
<div class="col-md-6">
<h2>Relations</h2>
<ul>
<li>Function: less than or equal to 1 arrow out</li>
<li>Surjective: greater than or eqaul to 1 arrow in</li>
<li>Total: greater than or equal to 1 arrow out</li>
<li>Injective: less than or equal to 1 arrow in</li>
<li>Bijective: 1 arrow out and 1 arrow in</li>
</ul>
These conditional statements verify if there is at most or at least one arrow going in or out of a node. Edges can only come out of the Domain and end in the Co-Domain.
</div>
</div>
<h2 class="h2center">Reference</h2>
<div class="row bigbuffer">
<div class="col-md-2" style="margin-left:45px; padding-right:20px; border-right: 1px solid #ccc; border-left: 1px solid #ccc;">
<img src="Injective.PNG" alt="Injective Relation" class="img-fluid">
</div>
<div class="col-md-2" style="padding-right:20px; border-right: 1px solid #ccc;">
<img src="Surjective.PNG" alt="Surjective Relation" class="img-fluid">
</div>
<div class="col-md-2" style="padding-right:20px; border-right: 1px solid #ccc;">
<img src="Function.PNG" alt="Function Relation" class="img-fluid">
</div>
<div class="col-md-2" style="padding-right:20px; border-right: 1px solid #ccc;">
<img src="Total.PNG" alt="Total Relation" class="img-fluid" >
</div>
<div class="col-md-3" style="padding-right:20px; border-right: 1px solid #ccc;">
<img src="Bijective.PNG" alt="Bijective Relation" class="img-fluid">
</div>
</div>
<h3 class="h2center" style="border-top: 1px solid #ccc; margin-top: 35px;">A "Related" Comic</h3>
<div class="bigbuffer">
<img src="Comic.PNG" alt="Comic" class="img-fluid"></div>
</div>
<div class="col"></div>
<p class="text-center" style="padding-top: 40px">Created by <a href="https://github.com/cpgeier" target="_blank">Christopher Geier</a> and <a href="https://github.com/hamzailyas97" target="_blank">Hamza Ilyas</a> using <a href="https://d3js.org/" target="_blank">D3</a></p>
<p></a></p>
</body>
</html>