-
Notifications
You must be signed in to change notification settings - Fork 86
/
maxwell.html
70 lines (62 loc) · 1.77 KB
/
maxwell.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
66
67
68
69
70
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Maxwell's Demon</title>
<link rel="shortcut icon" href="favicon.ico"/>
<style>
body {
background-color: whiteg;
text-align: center;
font-family: Ubuntu Mono;
}
#title {
color: black;
font-size: 200%;
font-style: normal;
margin: 1px;
border: 1px;
}
#balls {
margin-top: 5px;
}
#myCanvas {
margin-top: -20px;
}
section.footer {
color: black;
font-family: Ubuntu Mono;
font-style: normal;
font-size: small;
}
#disclaimer {
font-size: 74%;
color: gray;
}
</style>
</head>
<body style="text-align: center">
<section>
<div id="title"><p id="balls" style="font-size: 15pt">Maxwell's Demon</p><br/></div>
</section>
<div>
<div style="width:68%;float:left">
<canvas id="maxwell-canvas" width="700" height="500" style="border:1px solid black;display:inline;text-align:left"></canvas>
</div>
<div style="width:28%;float:right;margin:auto">
<div style="float:right;width:100%;margin:auto">Entropy: <output id="maxwell-entropy"></output></div>
<div id="maxwell-histogram-canvas" style="width:300px;height:250px;display:inline-block;text-align:right;margin:auto">
</div>
</div>
</div>
<div>
<button id="maxwell-newball" style="text-align:right">New Ball</button>
<button id="maxwell-pause" style="text-align:right">Pause</button>
<button id="maxwell-skip" style="text-align:right">Skip 1000s</button>
<button id="maxwell-histogram" style="text-align:right">Histogram</button>
</div>
<script src="https://cdn.plot.ly/plotly-latest.min.js"></script>
<script src="./scripts/ballworld/ballworld.js"></script>
<script src="./scripts/ballworld/maxwell.js"></script>
</body>
</html>