-
Notifications
You must be signed in to change notification settings - Fork 0
/
suvat.html
412 lines (409 loc) · 22.6 KB
/
suvat.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>suvat</title>
<link rel="icon" href="favicon.ico" type="image/x-icon">
<link rel="stylesheet" href="assets/css/bootstrap.css">
<link rel="stylesheet" href="assets/css/style.css" type="text/css">
<link rel="stylesheet" href="assets/css/fontawesome.css">
<link rel="stylesheet" href="assets/fontawesome/css/brands.css">
<link rel="stylesheet" href="assets/fontawesome/css/solid.css">
</head>
<body class="bg-pcode">
<header>
<div class="header"></div>
</header>
<section class="container">
<div class="jumbotron jumbotron-fluid mt-1 mb-1 shadow p-3 jumbo-bg">
<div class="container">
<h1 class="display-4 text-center text-wrap">Kinematics Calculator</h1>
<p class="lead">Calculate from any of the four kinematic equations (suvat) to determine displacement, initial velocity, final velocity, acceleration or time.
</p>
<p>Start by adding three of the known variables to calculate any of the remaining unknowns.</p>
</div>
</div>
</section>
<!-- Equation Display -->
<section class="container border border-info bg_cont mb-1">
<div class="row d-flex justify-content-center">
<h3>Equations</h3>
<table class="table table-sm">
<thead>
<tr>
<th scope="col" class="w50 text-center">Equation 1</th>
<th scope="col" class="w50 text-center">Equation 2</th>
</tr>
</thead>
<tbody>
<tr>
<td>\begin{gather} v\ =\ u+at\\ \notag \end{gather}
</td>
<td>\begin{gather} s\ =\ ut\ +\ \frac{1}{2} \ at^{2}\\ \notag \end{gather}
</td>
</tr>
</tbody>
</table>
<table class="table table-sm">
<thead>
<tr>
<th scope="col" class="w50 text-center">Equation 3</th>
<th scope="col" class="w50 text-center">Equation 4</th>
</tr>
</thead>
<tbody>
<tr>
<td>\begin{gather} v^{2} =u^{2} +2as\\ \notag \end{gather}
</td>
<td>\begin{gather} s=\frac{( u\ +\ v) \ t}{2}\\ \notag \end{gather}
</td>
</tr>
</tbody>
</table>
<p class="ml-3"><em>The equation table shows the four kinematic equations presented in the IB Databook
where:
<strong>s</strong> is displacement in m, <strong>u</strong> is the initial velocity in
ms<sup>-1</sup>,
<strong>v</strong> is the final velocity in ms<sup>-1</sup>,
<strong>a</strong> is acceleration in ms<sup>-2</sup>, and <strong>t</strong> is time in s.
</em></p>
</div>
</section>
<form id="SubmissionForm" class="needs-validation" novalidate>
<!-- Equation Selection -->
<section class="container border border-primary bg_cont mb-1">
<h4>Select the things you know:
<a tabindex="0" class="btn btn-link" role="button" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Select known variables" data-bs-content="By getting you to select the known variables you can start to become more familiar with the four equations. You can select up to four variables, but a minimum of three is required.">
<small><i class="far fa-question-circle fa"></i></small>
</a>
</h4>
<p>Select the three variables that you know. You can change this selection later if you want.</p>
<p>This will help you become familiar with the processes of calculating <em>suvat</em> equations.</p>
<div class="suvat-check">
<div class="form-check">
<input class="form-check-input" type="checkbox" value="displacement" id="displacement">
<label class="form-check-label" for="displacement">
Displacement (s)
</label>
</div>
<div class="form-check">
<input class="form-check-input" type="checkbox" value="" id="initial_velocity">
<label class="form-check-label" for="initial_velocity">
Initial Velocity (u)
</label>
</div>
<div class="form-check">
<input class="form-check-input" type="checkbox" value="final_velocity" id="final_velocity">
<label class="form-check-label" for="final_velocity">
Final Velocity (v)
</label>
</div>
<div class="form-check">
<input class="form-check-input" type="checkbox" value="acceleration" id="acceleration">
<label class="form-check-label" for="acceleration">
Acceleration (a)
</label>
</div>
<div class="form-check mb-2">
<input class="form-check-input" type="checkbox" value="time" id="time">
<label class="form-check-label" for="time">
Time (t)
</label>
</div>
</div>
</section>
<section class="container border border-primary bg_cont">
<div class="row d-flex justify-content-center">
<!-- Displacement Card -->
<div class="card shadow-sm p-3 mt-1 mb-1" style="width: 18rem;">
<i class="fa-solid fa-ruler-horizontal fa-10x rounded mx-auto d-block mt-1 shadow-sm p-3"></i>
<div class="card-body">
<h4 class="text-center">Displacement (s)<br>
<a tabindex="0" class="btn btn-link" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Displacement (m, km, yd, mi, ft):" data-bs-content="Leave blank or enter the displacement the object travelled. Don't forget to check the units!">
<i class="far fa-question-circle fa"></i>
</a>
</h4>
<p class="card-text"></p>
<label for="inputDistance">Displacement (s)</label><br>
<input type="number" name="inputDistance" id="inputDistance" class="reset_form checkDisplacement formCheck maxAllow" value="" min="0" max="99999999999999" step="0.001" autocomplete="off" aria-label="input value for distance in metres, kilometers, yards or miles"
disabled>
<br>
<label for="unitsDistance">Units</label><br>
<select name="unitsDistance" id="unitsDistance" style="width:60px;" disabled>
<option value="m" selected>m</option>
<option value="km">km</option>
<option value="yd">yd</option>
<option value="mi">miles</option>
<option value="ft">feet</option>
</select>
</div>
</div>
<!-- Initial Velocity -->
<div class="card shadow-sm p-3 mt-1 mb-1 cardBodyVelocity form-check" style="width: 18rem;">
<i class="fa-solid fa-gauge fa-10x rounded mx-auto d-block mt-1 shadow-sm p-3"></i>
<div class="card-body">
<h4 class="text-center">Initial Velocity (u)<br>
<a tabindex="0" class="btn btn-link" role="button" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Initial Velocity (ms<sup>-1</sup>, kmh<sup>-1</sup>, mph or fts<sup>-1</sup>)" data-bs-content="Leave blank or enter the initial velocity the object is travelling. Don't forget to check the units!">
<i class="far fa-question-circle fa"></i>
</a>
</h4>
<p class="card-text"></p>
<label for="inputVi">Velocity (u)</label><br>
<input type="number" name="inputVi" id="inputVi" class="reset_form checkVelocity maxAllow" value="" min="0" step="0.01" autocomplete="off" aria-label="input value for the initial velocity in metres per second, kilometers per hour, miles per hour or feet per second."
disabled>
<br>
<label for="unitsVi">Units</label>
<br>
<select name="unitsVi" id="unitsVi" style="width:67px;" disabled>
<option value="kmh">kmh⁻¹</option>
<option value="ms" selected>ms⁻¹</option>
<option value="mph">mph</option>
<option value="fts">fts⁻¹</option>
</select>
</div>
</div>
<!-- Final Velocity -->
<div class="card shadow-sm p-3 mt-1 mb-1 cardBodyVelocity form-check" style="width: 18rem;">
<i class="fa-solid fa-gauge-high fa-10x rounded mx-auto d-block mt-1 shadow-sm p-3"></i>
<div class="card-body">
<h4 class="text-center">Final Velocity (v)<br>
<a tabindex="0" class="btn btn-link" role="button" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Final Velocity (ms<sup>-1</sup>, kmh<sup>-1</sup>, mph or fts<sup>-1</sup>)" data-bs-content="Leave blank or enter the final velocity the object is travelling. Don't forget to check the units!">
<i class="far fa-question-circle fa"></i>
</a>
</h4>
<p class="card-text"></p>
<label for="inputVf">Final Velocity (v)</label><br>
<input type="number" name="inputVf" id="inputVf" class="reset_form checkVelocity maxAllow" value="" min="0" step="0.01" autocomplete="off" aria-label="input value for the final velocity in metres per second, kilometers per hour, miles per hour or feet per second."
disabled>
<!-- Error Message 1-->
<!-- Bootstrap Popover Method -->
<span id="sameV" data-bs-container="body" data-bs-toggle="popover" data-bs-trigger="manual" data-bs-title="<i class='fa-solid fa-triangle-exclamation'></i> Final and Initial Velocities can
not be the same" data-bs-content="Change either your initial or your final velocities, they can
not be the same number.">
</span>
<!-- Error Message 2-->
<!-- Bootstrap Popover Method -->
<span id="lowerV" data-bs-container="body" data-bs-toggle="popover" data-bs-trigger="manual" data-bs-title="<i class='fa-solid fa-triangle-exclamation'></i> Your final velocity is less than
your initial velocity" data-bs-content="Change your acceleration so that it is negative for this
to work. For samsung users, use the 'select' option in the Acceleration input for the negative sign.">
</span>
<br>
<label for="unitsVf">Units</label>
<br>
<select name="unitsVf" id="unitsVf" style="width:67px;" disabled>
<option value="kmh">kmh⁻¹</option>
<option value="ms" selected>ms⁻¹</option>
<option value="mph">mph</option>
<option value="fts">fts⁻¹</option>
</select>
</div>
</div>
</div>
<div class="row d-flex justify-content-center">
<!-- Acceleration Card -->
<div class="card shadow-sm p-3 mt-1 mb-1 form-check" style="width: 18rem;">
<i class="fa-solid fa-forward fa-10x rounded mx-auto d-block mt-1 shadow-sm p-3"></i>
<div class="card-body">
<h4 class="text-center">Acceleration (a)<br>
<a tabindex="0" class="btn btn-link" role="button" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Acceleration (ms<sup>-2</sup>)" data-bs-content="Leave blank or enter the acceleration of the object. You can choose gravity
as the acceleration.">
<i class="far fa-question-circle fa"></i>
</a>
</h4>
<p class="card-text"></p>
<label for="inputAcceleration">Acceleration (a)</label><br>
<!-- User Input - note pattern and input type to allow for Samsung Keyboards -->
<input type="text" pattern="-?[0-9]\d*(\.\d+)?" name=" inputAcceleration" id="inputAcceleration" class="reset_form checkAcceleration maxAllow" value="" min="-9999" step="0.0001" max="99999999999999" autocomplete="off" aria-label="input value for acceleration in metres per second squared or select g."
disabled>
<!-- Bootstrap Popover Method -->
<span id="zeroAccel" data-bs-container="body" data-bs-toggle="popover" data-bs-trigger="manual" data-bs-title="<i class='fa-solid fa-triangle-exclamation'></i> Acceleration must be non-zero" data-bs-content="Change your acceleration from zero to a positive or negative number. For samsung users, use the 'select' option for the negative sign.">
</span>
<br>
<label for="unitsAcceleration">Units</label>
<br>
<select name="unitsAcceleration" id="unitsAcceleration" style="width:115px;" disabled>
<option value="mss" selected>ms⁻²</option>
<option id="gOnly" value="g">(g) 9.81 ms⁻²</option>
<option id="-gOnly" value="-g">(g) -9.81 ms⁻²</option>
</select>
</div>
</div>
<!-- Time Card -->
<div class="card shadow-sm p-3 mt-1 mb-1 form-check" style="width: 18rem;">
<i class="fa-solid fa-stopwatch fa-10x rounded mx-auto d-block mt-1 shadow-sm p-3"></i>
<div class="card-body">
<h4 class="text-center">Time (t)<br>
<a tabindex="0" class="btn btn-link" role="button" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Time (s, min, hr, days)" data-bs-content="Leave blank or enter the time the object has travelled for. Don't forget to check the units!">
<i class="far fa-question-circle fa mb-1"></i>
</a>
</h4>
<p class="card-text"></p>
<label for="inputTime">Time (t)</label><br>
<input type="number" name="inputTime" id="inputTime" class="reset_form checkTime maxAllow" value="" min="0" max="99999999999999" step="0.0001" autocomplete="off" aria-label="input value for time in seconds, minutes, hours or days" disabled>
<br>
<label for="unitsTime">Units</label><br>
<select name="unitsTime" id="unitsTime" style="width:60px;" disabled>
<option value="s" selected>s</option>
<option value="min">min</option>
<option value="hr">hr</option>
<option value="days">days</option>
</select>
</div>
</div>
</div>
<div class="col text-center">
<button type="button" class="btn-sm btn btn-outline-success mb-2" id="submitButton" disabled>Calculate</button>
<a tabindex="0" class="btn btn-link" role="button" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Calculate" data-bs-content="Once you have added three or four variables, submit the calculation for evaluation.">
<i class="far fa-question-circle fa mb-2"></i>
</a>
</div>
<br>
</section>
<!-- Table 1 Select Output SI-Units -->
<section class="container border border-success mt-1 mb-1 bg_cont">
<h5>Table 1: Results in SI units</h5>
<table class="table table-sm">
<thead>
<tr>
<th scope="col" class="w50">Variable</th>
<th scope="col" class="w50">Amount</th>
</tr>
</thead>
<tbody>
<tr>
<td>Displacement (s)</td>
<td id="s">m</td>
</tr>
<tr>
<td>Initial Velocity (u)</td>
<td id="u">ms<sup>-1</sup></td>
</tr>
<tr>
<td>Final Velocity (v)</td>
<td id="v">ms<sup>-1</sup></td>
</tr>
<tr>
<td>Acceleration (a)</td>
<td id="a">ms<sup>-2</sup></td>
</tr>
<tr>
<td>Time (t)</td>
<td id="t">s</td>
</tr>
</tbody>
</table>
<h6 class="equation_color">Equation(s) Used:</h6>
<p id="si_suvat_equation"></p>
<p id="si_suvat_equation2"></p>
<button type="reset" class="btn-sm btn-outline-danger btn mb-2" id="resetButton">Reset</button>
<a tabindex="0" class="btn btn-link" role="button" data-bs-toggle="popover" data-bs-trigger="focus" data-bs-title="Reset Form" data-bs-content="Reset the form to add new variables to calculate. The answer will remain here until you calculate a new set of variables.">
<i class="far fa-question-circle fa mb-2"></i>
</a>
<br>
<p><em>Table 1 provides the SI unit for either ms<sup>-1</sup>, m, or s. You can change the output
accordingly
and see the common unit conversions in Table 2.</em></p>
</section>
</form>
<!-- Table 2 Results Table -->
<section class="container border border-success mt-1 mb-2 bg_cont">
<h5>Table 2: Results with common units displayed</h5>
<table class="table table-sm">
<thead>
<tr class="t_line">
<th scope="col" class="w50">Variable</th>
<th scope="col" class="w50">Amount</th>
</tr>
</thead>
<tbody>
<tr>
<td>Displacement (s)</td>
<td id="sx">m</td>
</tr>
<tr>
<td></td>
<td id="s1x">km</td>
</tr>
<tr>
<td></td>
<td id="s2x">mi</td>
</tr>
<tr>
<td></td>
<td id="s3x">yd</td>
</tr>
<tr class="t_line">
<td></td>
<td id="s4x">ft</td>
</tr>
<tr>
<td>Initial Velocity (u)</td>
<td id="ux">ms<sup>-1</sup></td>
</tr>
<tr>
<td></td>
<td id="u1x">kmh<sup>-1</sup></td>
</tr>
<tr>
<td></td>
<td id="u2x">mph</td>
</tr>
<tr class="t_line">
<td></td>
<td id="u3x">fts<sup>-1</sup></td>
</tr>
<tr>
<td>Final Velocity (v)</td>
<td id="vx">ms<sup>-1</sup></td>
</tr>
<tr>
<td></td>
<td id="v1x">kmh<sup>-1</sup></td>
</tr>
<tr>
<td></td>
<td id="v2x">mph</td>
</tr>
<tr class="t_line">
<td></td>
<td id="v3x">fts<sup>-1</sup></td>
</tr>
<tr class="t_line">
<td>Acceleration (a)</td>
<td id="ax">ms<sup>-2</sup></td>
</tr>
<tr>
<td>Time (t)</td>
<td id="tx">s</td>
</tr>
<tr>
<td></td>
<td id="t1x">min</td>
</tr>
<tr>
<td></td>
<td id="t2x">hr</td>
</tr>
<tr class="t_line">
<td></td>
<td id="t3x">days</td>
</tr>
</tbody>
</table>
<p><em>Table 2 shows the results of all the calculations and various units available with all conversions
completed.</em>
</p>
</section>
<footer>
<div class="footer"></div>
</footer>
<script src="assets/scripts/jquery-3.6.1.min.js"></script>
<script src="assets/scripts/bootstrap.bundle.js"></script>
<script src="assets/scripts/include_content.js"></script>
<script src="assets/scripts/calculators/suvat.js"></script>
<script src="assets/scripts/calculators/suvat_validity.js"></script>
<script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
<script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
</body>
</html>