This repository has been archived by the owner on May 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathflaskfiller.html
541 lines (528 loc) · 29.3 KB
/
flaskfiller.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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
<!DOCTYPE html>
<!--
Copyright 2016 Huub de Beer <Huub@heerdebeer.org>
This file is part of FlaskFiller.
FlaskFiller is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
FlaskFiller is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with FlaskFiller. If not, see <http://www.gnu.org/licenses/>.
-->
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="keywords" content="mathematic education, primary education,
calculus, instantanoues speed, speed">
<title>FlaskFiller: Explore Instantaneous Speed in the Context of Filling
Glassware</title>
<link rel="stylesheet" href="node_modules/bootstrap/dist/css/bootstrap.css">
<link rel="stylesheet" href="node_modules/font-awesome/css/font-awesome.min.css">
<link rel="stylesheet" href="flaskfiller.css">
</head>
<body>
<!-- FlaskFiller menu -->
<header>
<nav class="navbar bg-primary navbar-full">
<ul class="nav nav-tabs navbar-nav" role="tablist">
<li class="nav-item">
<a class="nav-link active" href="#filler" data-toggle="tab" role="tab">
<span class="icon fa fa-glass"></span>
<span class="hidden-sm-down">FlaskFiller</span>
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#settings" data-toggle="tab" role="tab">
<span class="icon fa fa-wrench"></span>
<span class="hidden-sm-down">Settings</span>
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#information" data-toggle="tab" role="tab">
<span class="icon fa fa-info"></span>
<span class="hidden-sm-down">Info</span>
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#help" data-toggle="tab" role="tab">
<span class="icon fa fa-question"></span>
<span class="hidden-sm-down">Help</span>
</a>
</li>
</ul>
</nav>
</header>
<main class="container-fluid">
<div class="tab-content">
<!--
The actual FlaskFiller with four components:
- simulation,
- graph,
- control + table,
- and glass designer
-->
<div class="tab-pane active" id="filler" role="tabpanel">
<div class="row">
<div class="col-md-12 col-xs-12">
<figure id="simulation"></figure>
<figure id="graph"></figure>
</div>
</div>
<div class="row">
<div class="col-md-12 col-xs-12">
<table id="table"></table>
</div>
</div>
<!--
<div class="row">
<div class="col-md-6 col-xs-12">
<figure class="col" id="designer"></figure>
</div>
</div>
-->
</div>
<!--
Settings tab to configure the FlaskFiller software
-->
<div class="tab-pane" id="settings" role="tabpanel">
<div class="alert alert-info invisible" id="reload-message" role="alert">
Reload the page for the changes to take effect.
</div>
<div id="settings-accordion" role="tablist" aria-multiselectable="true">
<form id="configuration-form" name="configuration-form">
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="settings-general">
<h4 class="panel-title">
<a data-toggle="collapse" data-parent="#settings-accordion"
href="#collapse-settings-general" aria-expanded="true"
aria-controls="collapse-settings-general">
General
</a>
</h4>
</div>
<div id="collapse-settings-general" class="panel-collapse collapse in" role="tabpanel"
aria-labelledby="settings-general">
<fieldset class="form-group row">
<legend class="col-form-legend col-sm-4">
Components
</legend>
<div class="col-sm-8">
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="components" value="simulation" checked>
Simulation
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="components" value="graph" checked>
Graph
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="components" value="table" checked>
Table
</label>
</div>
<div class="form-check disabled">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="components" value="control" checked disabled>
Control
</label>
</div>
<!--
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="components" value="designer">
Glass designer
</label>
</div>
-->
</div>
</fieldset>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="settings-simulation">
<h4 class="panel-title">
<a data-toggle="collapse" class="collapsed" data-parent="#settings-accordion"
href="#collapse-settings-simulation" aria-expanded="true"
aria-controls="collapse-settings-simulation">
Simulation
</a>
</h4>
</div>
<div id="collapse-settings-simulation" role="tabpanel"
class="panel-collapse collapse"
aria-labelledby="settings-simulation">
<div class="form-group row">
<label for="world-height" class="form-label
col-sm-4">World height</label>
<div class="col-sm-8">
<input class="form-control" type="number" value="18"
name="world-height"
id="world-height"> (cm)
</div>
</div>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="settings-graph">
<h4 class="panel-title">
<a data-toggle="collapse" class="collapsed" data-parent="#settings-accordion"
href="#collapse-settings-graph" aria-expanded="true"
aria-controls="collapse-settings-graph">
Graph
</a>
</h4>
</div>
<div id="collapse-settings-graph" role="tabpanel"
class="panel-collapse collapse"
aria-labelledby="settings-graph">
<div class="form-group row">
<label for="horizontal-axis" class="form-label
col-sm-4">Horizontal axis</label>
<div class="col-sm-8">
<select class="custom-select" name="horizontal-axis"
id="horizontal-axis">
<option value="height">Height</option>
<option value="volume">Volume</option>
<option value="time" selected>Time</option>
<option value="speed">Rising speed</option>
</select>
</div>
</div>
<div class="form-group row">
<label for="vertical-axis" class="form-label
col-sm-4">Vertical axis</label>
<div class="col-sm-8">
<select class="custom-select" name="vertical-axis"
id="vertical-axis">
<option value="height" selected>Height</option>
<option value="volume">Volume</option>
<option value="time">Time</option>
<option value="speed">Rising speed</option>
</select>
</div>
</div>
<fieldset class="form-group row">
<legend class="col-form-legend col-sm-4">
Graph types
</legend>
<div class="col-sm-8">
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-types" value="arrow">
Arrow graph
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-types" value="bar">
Bar graph
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-types" value="line" checked>
Line graph
</label>
</div>
</div>
</fieldset>
<fieldset class="form-group row">
<legend class="col-form-legend col-sm-4">
Options
</legend>
<div class="col-sm-8">
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-options" value="coordinates" checked>
Show coordinates
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-options" value="speed">
Show speed
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-options" value="tangent-line">
Show tangent line
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-options" value="step" checked>
Show step control for arrow and bar graphs
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="graph-options" value="move-highball">
Moveable graph of the extensible highball glass
</label>
</div>
</div>
</fieldset>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="settings-table">
<h4 class="panel-title">
<a data-toggle="collapse" class="collapsed" data-parent="#settings-accordion"
href="#collapse-settings-table" aria-expanded="true"
aria-controls="collapse-settings-table">
Table
</a>
</h4>
</div>
<div id="collapse-settings-table" role="tabpanel"
class="panel-collapse collapse"
aria-labelledby="settings-table">
<fieldset class="form-group row">
<legend class="col-form-legend col-sm-4">
Quantities
</legend>
<div class="col-sm-8">
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="table-quantities" value="height" checked>
Height
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="table-quantities" value="time" checked>
Time
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="table-quantities" value="volume" checked>
Volume
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="table-quantities" value="speed">
Rising speed
</label>
</div>
</div>
</fieldset>
<fieldset class="form-group row">
<legend class="col-form-legend col-sm-4">
Glasses
</legend>
<div class="col-sm-8">
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="table-glass-name" value="hide-glass-name">
Hide glass' name
</label>
</div>
</div>
</fieldset>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="settings-control">
<h4 class="panel-title">
<a data-toggle="collapse" class="collapsed" data-parent="#settings-accordion"
href="#collapse-settings-control" aria-expanded="true"
aria-controls="collapse-settings-control">
Control
</a>
</h4>
</div>
<div id="collapse-settings-control" role="tabpanel"
class="panel-collapse collapse"
aria-labelledby="settings-control">
<fieldset class="form-group row">
<legend class="col-form-legend col-sm-4">
Glasses to add
</legend>
<div class="col-sm-8">
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="cocktail" checked>
Cocktail glass
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="highball" checked>
Highball glass
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="extensible-highball" checked>
Extensible highball glass
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="wine" checked>
Wine glass
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="cognac" checked>
Cognac glass
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="beer" checked>
Beer glass
</label>
</div>
<!-- Add these later
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="erlenmeyer" checked>
Erlenmeyer
</label>
</div>
<div class="form-check">
<label class="form-check-label">
<input class="form-check-input" type="checkbox"
name="glasses" value="round-bottom" checked>
Rondbodemfles
</label>
</div>
-->
</div>
</fieldset>
</div>
</div>
</form>
</div>
</div>
<!--
Information about the FlaskFiller software and the research and
educational design projects it was developed in
-->
<div class="tab-pane" id="information" role="tabpanel">
<p>FlaskFiller is a learning tool to explore instantaneous speed in primary school. It has been made as part of a <a href="https://heerdebeer.org/DR/">research on teaching instantaneous speed in grade 5</a>. During this research, four teaching experiments have been performed and in each experiment used a new version of the software has been developed and used. After the last experiment a more polished version of FlaskFiller has been developed. You can download and use this latest and greatest version of FlaskFiller <a href="standalone_flaskfiller.html">here</a>!</p>
<h2 id="flaskfiller-is-free-software">FlaskFiller is free software</h2>
<p>FlaskFiller is <a href="https://www.gnu.org/philosophy/free-sw.en.html">free software</a>; FlaskFiller is released under the <a href="https://www.gnu.org/licenses/gpl-3.0.en.html">GPL version 3</a>. This means that you can use, adapt, and distribute FlaskFiller as long as these adaptations are published under the same free license. The FlaskFiller source code is released on <a href="https://github.com/htdebeer/flaskfiller">github</a>.</p>
<p>Furthermore, FlaskFiller is build using the following free and/or open source libraries:</p>
<ul>
<li>The simulation component is build with <a href="http://dmitrybaranovskiy.github.io/raphael/">Raphaël.js</a></li>
<li>The graphing component is build with <a href="https://d3js.org/">d3</a></li>
<li>The user interface is made with <a href="https://v4-alpha.getbootstrap.com/">Bootstrap</a> and <a href="https://blog.jquery.com/">jQuery</a></li>
<li>The icons used are from <a href="http://fontawesome.io/">Font Awesome</a></li>
</ul>
</div>
<!--
Help on using flaskfiller
-->
<div class="tab-pane" id="help" role="tabpanel">
<h1 id="using-flaskfiller">Using FlaskFiller</h1>
<p><a href="standalone_flaskfiller.html"><img src="flaskfiller.png" alt="Figure 1. Using FlaskFiller to explore filling a cocktail glass and a beer glass." /></a></p>
<h2 id="exploring-filling-glassware-with-flaskfiller">Exploring filling glassware with FlaskFiller</h2>
<p>FlaskFiller consists of four configurable components (see Figure 1) that interact with each other:</p>
<ol style="list-style-type: decimal">
<li><p>In Figure 1, you see the simulation of filling a cocktail glass with a greenish liquid and a beer glass with a purple liquid. To start the simulation of filling a glass, double-click on a glass or use the control (see the last component). Clicking on a glass that is being filled, pauses the simulation. Changes in the simulation are reflected in the other three components (and vice versa).</p>
<p>You can drag glasses around in the simulation. When you drag a glass over another glass, it snaps to that other glass' center line. This makes it easier to align different glasses.</p>
<p>Do note that the glass' position in the simulation has no effect on the other components. As you can see in Figure 1, the beer glass have been moved about 2cm, yet its graph still starts at 0cm. This is intentional.</p>
<p>When you move your mouse pointer over a ruler, a red helper line will show.</p></li>
<li><p>In the graph component you see a line graph of the cocktail glass and a bar chart of the beer glass. FlaskFiller also has a third type of graph, the arrow graph. You can enable the arrow chart via the settings tab (which is discussed in the <a href="#configuring-flaskfiller">next section: Configuring FlaskFiller</a>) to explore what it does.</p>
<p>In Figure 1 the mouse cursor hovers over the cocktail glass' line graph at the point (1.31s, 12.19cm). You can configure FlaskFiller to show different aspects of the situation described by a point on a line graph. Furthermore, you can choose which quantities to plot on the axes. FlaskFiller supports quantities time, height, volume, and the rising speed.</p></li>
<li><p>On the bottom you see the control component combined with the table (more about that later). Using the control you can start, pause, restart or finish the simulation. You can also show or hide graphs, change the step-size of a bar chart and arrow graph. To change the color of a glass' liquid, you click on its colored square. A random color will be chosen.</p>
<p>Furthermore, through the control component you can add and remove a glass. Note the option to add an extensible highball glass. The extensible highball glass is the only glass that can be added multiple times. And you can change its size by dragging its handle at the upper-right corner of the glass.</p></li>
<li><p>Finally, the situation of filling glassware is described quantitatively by a table. The table component is combined with the control component. You can configure what quantities to show in the table component, if any. Furthermore, the values in the quantities' columns can be edited. For example, if you would change the cocktail glass' volume to 100ml and press Enter, the table, simulation, and graph components will be updated to reflect that change.</p></li>
</ol>
<p>Each component but the control can be hidden. If your web browser window is too small, the graph component will be shown below the simulation instead of alongside it. If you change the browser window's size, reload the page to have it resize properly.</p>
<h2 id="configuring-flaskfiller">Configuring FlaskFiller</h2>
<p>FlaskFiller is highly configurable. Settings are stored in the web browser. When you open FlaskFiller again in the same web browser, it will use the same settings as you had when you had last time you used FlaskFiller.</p>
<p>Open the Settings tab to configure the following aspects of FlaskFiller:</p>
<ul>
<li><p><strong>General</strong>: select which components you want to show in FlaskFiller. By default the <em>simulation</em>, <em>graph</em>, <em>table</em>, and <em>control</em> components are selected. You cannot deselect the <em>control</em> component.</p></li>
<li><p><strong>Simulation</strong>: change the <em>height of the simulated world</em>. After changing the <em>height</em>, the FlaskFiller application needs to be reloaded.</p></li>
<li><p><strong>Graph</strong>:</p>
<ul>
<li>Select the <em>horizontal axis' quantity</em>, which is one of height, time, volume, or rising speed.</li>
<li>Select the <em>vertical axis' quantity</em>, which is one of height, time, volume, or rising speed. Note that you can select the same quantity for both axes, which can make for an interesting topic of discussion.</li>
<li><p>Select which <em>graph types</em> can be shown. The supported graph types are:</p>
<ul>
<li><em>line graph</em></li>
<li><em>bar graph</em></li>
<li><em>arrow graph</em></li>
</ul></li>
</ul>
<p>You can show or hide a graph of a particular glass by toggling its corresponding icon in the control component.</p>
<ul>
<li><p>Various <em>options</em>:</p>
<ul>
<li><em>Show the coordinates</em> of the point on a line graph the mouse points at.</li>
<li><em>Show the rising speed</em> in the point on a line graph the mouse points at.</li>
<li><em>Show the tangent line</em> to the point on a line graph the mouse points at.</li>
<li><em>Show a slider to change the step-size</em> between the subsequent bars in a bar graph or the arrows in an arrow graph.</li>
<li><em>Make the line graphs of the extensible highball glass moveable</em>. This allows you to move these line graphs over other graphs to explore the idea of a tangent line.</li>
</ul></li>
</ul></li>
<li><p><strong>Table</strong>: select which quantities to show. You can enable each of <em>height</em>, <em>time</em>, <em>volume</em>, and <em>rising speed</em>.</p></li>
<li><p><strong>Control</strong>: select which glasses can be added in FlaskFiller. You can select the following glasses:</p>
<ul>
<li><em>cocktail glass</em>, which will be shown by default if selected</li>
<li><em>highball glass</em></li>
<li><em>extensible highball glass</em>, which can be added multiple times</li>
<li><em>wine glass</em></li>
<li><em>cognac glass</em></li>
<li><em>beer glass</em>.</li>
</ul></li>
</ul>
<p>When FlaskFiller needs to be reloaded for the changes to take effect, you will see a message on top of the settings tab.</p>
</div>
</div>
</main>
<script src="node_modules/jquery/dist/jquery.min.js"><!--</script>
<script>
// surpress Bootstrap warning about missing Tether: is not used in FlaskFiller anyway
window.Tether = function () {};
</script>
<script src="node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="node_modules/raphael/raphael.min.js"></script>
<script src="node_modules/d3/build/d3.min.js"></script>
<script src="flaskfiller.js" charset="utf-8"></script>
</body>
</html>