Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 91 lines (80 sloc) 3.978 kb
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
1 <!DOCTYPE html>
2 <html data-require="math graphie graphie-helpers">
3 <head>
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <title>Parabola intuition 2</title>
6 <script src="../khan-exercise.js"></script>
7 <style>
8 .parabola-answer {
9 padding: 0;
10 margin: 10px 0px;
11 }
12 .parabola-answer p {
13 margin: 8px 0px 2px 0px
14 }
15 .parabola-answer .mini-buttons {
16 width: 20px;
17 display: inline-block;
18 }
19 .parabola-answer .mini-buttons input {
20 margin-left: 5px;
21 padding: 0px 5px;
22 width: 20px;
23 }
24 </style>
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
25 </head>
26 <body>
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
27 <div class="exercise">
28 <div class="vars">
29 <var id="A">randRangeNonZero( -2, 2 )</var>
30 <var id="X1">randRangeNonZero( -5, 5 )</var>
31 <var id="Y1">randRangeNonZero( -5, 5 )</var>
32 </div>
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
33
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
34 <div class="problems">
35 <div>
36 <p class="question">Adjust the focus coordinates and the equation of the directrix to make the blue parabola match the orange parabola.</p>
37 <p>All points on the blue parabola are equidistant from the focus and the directrix. How does changing the numbers affect the shape of the parabola?</p>
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
38
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
39 <div class="graphie" id="grid">
40 graphInit({
41 range: 10,
42 scale: 20,
43 tickStep: 1,
44 axisArrows: "<->"
45 });
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
46
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
47 // Plot the orange parabola
48 style({
49 stroke: "#FFA500",
50 fill: "none",
51 clipRect:[ [-10, -10], [20, 20] ],
52 arrows: null
53 });
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
54
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
55 plot( new Parabola( A, X1, Y1 ).graphieFunction, [-10, 10]);
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
56
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
57 style({
58 stroke: "#6495ED",
59 strokeWidth: 3,
60 fill: "none",
61 clipRect:[ [-10, -10], [20, 20] ],
62 arrows: null
63 });
4da7347 Marcia Lee Rework parabola
marcia authored
64
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
65 graph.currParabola = new Parabola( 1, 0, 0 );
66 graph.currParabola.plot( true );
67 </div>
c2cb4db Ben Alpert Whitespace :)
spicyj authored
68
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
69 <div class="solution" data-type="multiple">
70 <p class="parabola-answer">focus x coordinate: <span id="focus-x-label"><code>0</code></span><span class="mini-buttons">
263a5e4 Jason Rosoff Semi-major refactor of button styles. You no longer need to add action-g...
jasonrr authored
71 <input type="button" class="simple-button" value="+" onclick="updateFocusDirectrix( 1, 0, 0 )" />
72 <input type="button" class="simple-button" value="-" onclick="updateFocusDirectrix( -1, 0, 0 )" /></span></p>
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
73
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
74 <p class="parabola-answer">focus y coordinate: <span id="focus-y-label"><code>0.25</code></span><span class="mini-buttons">
263a5e4 Jason Rosoff Semi-major refactor of button styles. You no longer need to add action-g...
jasonrr authored
75 <input type="button" class="simple-button" value="+" onclick="updateFocusDirectrix( 0, 1/8, 0 )" />
76 <input type="button" class="simple-button" value="-" onclick="updateFocusDirectrix( 0, -1/8, 0 )" /></span></p>
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
77
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
78 <p class="parabola-answer">directrix: <span id="directrix-label"><code>y=-0.25</code></span><span class="mini-buttons">
263a5e4 Jason Rosoff Semi-major refactor of button styles. You no longer need to add action-g...
jasonrr authored
79 <input type="button" class="simple-button" value="+" onclick="updateFocusDirectrix( 0, 0, 1/8 )" />
80 <input type="button" class="simple-button" value="-" onclick="updateFocusDirectrix( 0, 0, -1/8 )" /></span></p>
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
81
4e4cb9b Ben Eater lint: tabs->spaces and jQuery->$ for exercises
beneater authored
82 <span class="sol" id="leading-coefficient" style="display: none"><var>A</var></span>
83 <span class="sol" id="vertex-x" style="display: none"><var>X1</var></span>
84 <span class="sol" id="vertex-y" style="display: none"><var>Y1</var></span>
85 </div>
86 </div>
87 </div>
88 </div>
aa217d3 Marcia Lee Add exercises -- parabola intuition 1, 2
marcia authored
89 </body>
90 </html>
Something went wrong with that request. Please try again.