This repository has been archived by the owner on May 11, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 863
/
multiplying_mixed_numbers_1.html
60 lines (52 loc) · 2.7 KB
/
multiplying_mixed_numbers_1.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
<!DOCTYPE html>
<html data-require="math math-format graphie graphie-helpers word-problems">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Multiplying mixed numbers 1</title>
<script data-main="../local-only/main.js" src="../local-only/require.js"></script>
</head>
<body>
<div class="exercise">
<div class="vars">
<var id="WHOLE_1">randRange(1, 5)</var>
<var id="WHOLE_2">randRange(1, 5)</var>
<div data-ensure="getGCD(NUM_1, DENOM_1) === 1">
<var id="NUM_1">randRange(1, 4)</var>
<var id="DENOM_1">randRange(NUM_1 + 1, 5)</var>
</div>
<div data-ensure="getGCD(NUM_2, DENOM_2) === 1">
<var id="NUM_2">randRange(1, 4)</var>
<var id="DENOM_2">randRange(NUM_2 + 1, 5)</var>
</div>
<var id="I_NUM_1">WHOLE_1 * DENOM_1 + NUM_1</var>
<var id="I_NUM_2">WHOLE_2 * DENOM_2 + NUM_2</var>
<var id="I_NUM">I_NUM_1 * I_NUM_2</var>
<var id="I_DENOM">DENOM_1 * DENOM_2</var>
<var id="GCD">getGCD(I_NUM, I_DENOM)</var>
<var id="WHOLE_3">roundTowardsZero(I_NUM / I_DENOM)</var>
<var id="NUM_3">I_NUM % I_DENOM</var>
<var id="NUM_3_SIMP">NUM_3 / getGCD(NUM_3, I_DENOM)</var>
<var id="DENOM_3_SIMP">I_DENOM / getGCD(NUM_3, I_DENOM)</var>
</div>
<div class="problems">
<div class="problem">
<p>Multiply, simplify to lowest terms, and write as a mixed number:</p>
<p class="question"><code>
<var>WHOLE_1</var><var>fraction(NUM_1, DENOM_1, false, true)</var> \times
<var>WHOLE_2</var><var>fraction(NUM_2, DENOM_2, false, true)</var>
</code></p>
<div class="solution" data-type="multiple">
<p><span class="sol" data-type="mixed"><var>WHOLE_3 + NUM_3_SIMP / DENOM_3_SIMP</var></span></p>
</div>
</div>
</div>
<div class="hints">
<p><code>\qquad = <var>fraction(I_NUM_1, DENOM_1, false, true)</var> \times <var>fraction(I_NUM_2, DENOM_2, false, true)</var></code></p>
<p><code>\qquad = \dfrac{<var>I_NUM_1</var> \times <var>I_NUM_2</var>}{<var>DENOM_1</var> \times <var>DENOM_2</var>}</code></p>
<p><code>\qquad = <var>fraction(I_NUM, I_DENOM)</var></code></p>
<p data-if="GCD !== 1"><code>\qquad = <var>fractionReduce(I_NUM, I_DENOM)</var></code></p>
<p data-if="WHOLE_3 !== 0 && NUM_3 !== 0"><code>\qquad = <var>WHOLE_3</var> <var>fractionReduce(NUM_3, I_DENOM)</var></code></p>
</div>
</div>
</body>
</html>