Permalink
Browse files

massive merge

  • Loading branch information...
2 parents 39709fe + ef02c95 commit 432ecb9fea799659d5e984c14dec75309a315dad @nsfmc nsfmc committed Sep 1, 2011
Showing with 8,397 additions and 655 deletions.
  1. +4 −0 README.md
  2. +36 −1 css/khan-exercise.css
  3. +23 −29 exercises/absolute_value.html
  4. +1 −1 exercises/adding_and_subtracting_fractions.html
  5. +2 −2 exercises/adding_decimals.html
  6. +54 −0 exercises/adding_fractions.html
  7. +1 −1 exercises/adding_fractions_with_common_denominators.html
  8. +1 −1 exercises/addition_1.html
  9. +1 −1 exercises/addition_2.html
  10. +1 −1 exercises/addition_3.html
  11. +1 −1 exercises/addition_4.html
  12. +26 −3 exercises/angle_types.html
  13. +304 −0 exercises/arithmetic_word_problems_1.html
  14. +18 −2 exercises/chain_rule_1.html
  15. +0 −46 exercises/changing_decimals_to_fractions_1.html
  16. +31 −0 exercises/changing_decimals_to_percents.html
  17. +45 −0 exercises/changing_fractions_to_decimals_1.html
  18. +13 −6 exercises/changing_fractions_to_percents.html
  19. +30 −0 exercises/changing_percents_to_decimals.html
  20. +44 −0 exercises/changing_percents_to_fractions.html
  21. +87 −0 exercises/comparing_absolute_values.html
  22. +8 −8 exercises/comparing_fractions_1.html
  23. +8 −6 exercises/comparing_fractions_2.html
  24. +1 −1 exercises/complementary_angles.html
  25. +15 −0 exercises/conic_sections.html
  26. +54 −0 exercises/converting_decimals_to_fractions_1.html
  27. +62 −0 exercises/converting_decimals_to_fractions_2.html
  28. +106 −0 exercises/converting_mixed_numbers_and_improper_fractions.html
  29. +78 −0 exercises/decimals_on_the_number_line.html
  30. +1 −1 exercises/dividing_decimals.html
  31. +2 −1 exercises/dividing_fractions.html
  32. +2 −2 exercises/divisibility.html
  33. +1 −1 exercises/division_0.5.html
  34. +1 −1 exercises/division_1.5.html
  35. +1 −1 exercises/division_1.html
  36. +1 −1 exercises/division_2.html
  37. +1 −1 exercises/division_3.html
  38. +1 −1 exercises/division_4.html
  39. +70 −0 exercises/equation_of_a_hyperbola.html
  40. +51 −0 exercises/equation_of_a_parabola.html
  41. +54 −0 exercises/equation_of_an_ellipse.html
  42. +94 −0 exercises/estimation_with_decimals.html
  43. +65 −0 exercises/evaluating_expressions_2.html
  44. +206 −0 exercises/even_and_odd_integers.html
  45. +4 −5 exercises/exponent_rules.html
  46. +1 −1 exercises/exponents_4.html
  47. +42 −0 exercises/expressing_ratios_as_fractions.html
  48. +86 −19 exercises/fraction_word_problems_1.html
  49. +111 −0 exercises/fractions_on_the_number_line.html
  50. +1 −1 exercises/graphing_points.html
  51. +2 −1 exercises/graphs_of_sine_and_cosine.html
  52. +216 −0 exercises/inequalities_on_a_number_line.html
  53. +7 −7 exercises/inverse_trig_functions.html
  54. +7 −2 exercises/khan-exercise.html
  55. +2 −2 exercises/khan-site.html
  56. +1 −1 exercises/line_relationships.html
  57. +6 −4 exercises/linear_equations_4.html
  58. +61 −0 exercises/lines_of_symmetry.html
  59. +10 −21 exercises/measuring_angles.html
  60. +7 −5 exercises/multiplication_0.5.html
  61. +1 −1 exercises/multiplication_1.5.html
  62. +5 −5 exercises/multiplication_1.html
  63. +1 −1 exercises/multiplication_2.html
  64. +1 −1 exercises/multiplication_3.html
  65. +1 −1 exercises/multiplication_4.html
  66. +1 −1 exercises/multiplying_decimals.html
  67. +1 −1 exercises/multiplying_fractions.html
  68. +526 −0 exercises/multiplying_fractions_1.html
  69. +58 −0 exercises/number_line.html
  70. +115 −0 exercises/one_step_inequalities.html
  71. +0 −3 exercises/order_of_operations.html
  72. +37 −29 exercises/ordering_fractions.html
  73. +108 −0 exercises/ordering_negative_numbers.html
  74. +7 −7 exercises/pythagorean_theorem_2.html
  75. +1 −1 exercises/quadratic_inequalities_1.html
  76. +99 −0 exercises/ratio_word_problems.html
  77. +45 −34 exercises/recognizing_conic_sections.html
  78. +12 −11 exercises/recognizing_fractions.html
  79. +101 −0 exercises/recognizing_percents.html
  80. +12 −5 exercises/recognizing_rays_lines_and_line_segments.html
  81. +12 −12 exercises/rounding_numbers.html
  82. +1 −8 exercises/scientific_notation.html
  83. +72 −0 exercises/signs_of_a_parabola.html
  84. +1 −1 exercises/simplifying_fractions.html
  85. +3 −3 exercises/solving_for_a_variable.html
  86. +143 −0 exercises/square_roots_cube_roots.html
  87. +2 −2 exercises/subtracting_decimals.html
  88. +40 −100 exercises/subtracting_fractions.html
  89. +1 −1 exercises/subtracting_fractions_with_common_denominators.html
  90. +1 −1 exercises/subtraction_1.html
  91. +1 −1 exercises/subtraction_2.html
  92. +1 −1 exercises/subtraction_3.html
  93. +1 −1 exercises/subtraction_4.html
  94. +2 −2 exercises/systems_of_equations.html
  95. +85 −0 exercises/telling_time.html
  96. +6 −12 exercises/trigonometry_1.html
  97. +15 −28 exercises/trigonometry_2.html
  98. +1 −1 exercises/writing_expressions_2.html
  99. +81 −0 exercises/writing_proportions.html
  100. BIN images/protractor.png
  101. +3,616 −0 jquery.js
  102. +171 −63 khan-exercise.js
  103. +0 −1 test/qunit
  104. +49 −32 utils/answer-types.js
  105. +260 −0 utils/exercise_maker.html
  106. +13 −6 utils/expressions.js
  107. +32 −0 utils/graphie-helpers-arithmetic.js
  108. +272 −83 utils/graphie-helpers.js
  109. +15 −0 utils/graphie.js
  110. +81 −2 utils/math-format.js
  111. +33 −0 utils/math.js
  112. +1 −1 utils/tmpl.js
  113. +83 −3 utils/word-problems.js
View
@@ -22,3 +22,7 @@ The process for writing exercises is rather well documented. More information ab
* [How to Get Involved](https://github.com/Khan/khan-exercises/wiki/Getting-Involved)
* [How to Write Exercises](https://github.com/Khan/khan-exercises/wiki/Writing-Exercises:-Home)
* [How to Test Exercises](https://github.com/Khan/khan-exercises/wiki/Testing-Exercises)
+
+## More
+
+If you're passionate about creating these exercises and want to apply to be a full-time exercise developer at the Khan Academy, [please do so](http://hire.jobvite.com/CompanyJobs/Careers.aspx?c=qd69Vfw7&page=Job%20Description&j=ohjSVfw7).
View
@@ -55,6 +55,8 @@ body.debug .graphie { outline: 1px dashed red; }
#answer_area input.button:disabled { opacity: 0.7; cursor: default; color: #333; }
+#hint-remainder { color: #777; }
+
#footer .simple-button { padding: 3px 10px; top: -1px }
#issue .error { font-style: italic; font-weight: bold; }
@@ -66,4 +68,37 @@ body.debug .graphie { outline: 1px dashed red; }
var, div.graphie { white-space: pre; }
-#issue-throbber { position: relative; top: 3px; }
+#issue-throbber { position: relative; top: 3px; }
+
+.exp input { vertical-align: super; font-size: 9px; height: 11px; }
+
+#warning-bar {
+ background: red;
+ width: 100%;
+ height: 35px;
+ text-align: center;
+ color: #eee;
+ font-size: 15px;
+ display: none;
+}
+
+#warning-bar span {
+ position: relative;
+ top: 5px;
+}
+
+#warning-bar-close {
+ top: 5px;
+ float: right;
+ right: 20px;
+ position: relative;
+}
+
+#warning-bar a {
+ color: #eee;
+}
+
+#warning-bar-content a {
+ color: #eee;
+ text-decoration: underline;
+}
@@ -23,36 +23,30 @@
</div>
<div class="hints">
- <p data-if="SIGN == &quot;&quot;">The number <code><var>INT + FRAC</var></code> is already non-negative, so it is its own absolute value.</p>
- <div data-else>
- <p>The number <code>-<var>INT + FRAC</var></code> is negative, so its absolute value is positive: <code><var>INT + FRAC</var></code>.</p>
- </div>
- <div>
- <div class="graphie">
- init({
- range: [ [-1, 11], [-1, 1] ]
- });
- var start = 0;
- var end = 10;
- var originX = 0;
- var x = abs( INT ) + FRAC;
- if ( SIGN === "-" ) {
- start = -10;
- end = 0;
- originX = 10;
- x = 10 - x;
- }
- numberLine( start, end );
- style({ stroke: "#6495ED", fill: "#6495ED" });
- graph.pt = circle( [ x, 0 ], 0.15 );
- style({ stroke: "#FFA500", fill: "#FFA500", strokeWidth: 3.5, arrows: "->" });
- path( [ [ originX, 0 ], [ x, 0 ] ] );
- circle( [ originX, 0 ], 0.10 );
- graph.pt.toFront();
- </div>
- <p>The distance from <code>0</code> to <code><var>SIGN + INT + FRAC</var></code> is <code><var>INT + FRAC</var></code>, which equals the absolute value.</p>
- <p data-if="SIGN !== &quot;&quot;">In other words, <code><var>INT + FRAC</var></code> is the non-negative version of <code><var>SIGN + INT + FRAC</var></code>.</p>
+ <div class="graphie">
+ init({
+ range: [ [-1, 11], [-1, 1] ]
+ });
+ var start = 0;
+ var end = 10;
+ var originX = 0;
+ var x = abs( INT ) + FRAC;
+ if ( SIGN === "-" ) {
+ start = -10;
+ end = 0;
+ originX = 10;
+ x = 10 - x;
+ }
+ numberLine( start, end );
+ style({ stroke: "#6495ED", fill: "#6495ED" });
+ graph.pt = circle( [ x, 0 ], 0.15 );
+ style({ stroke: "#FFA500", fill: "#FFA500", strokeWidth: 3.5, arrows: "->" });
+ path( [ [ originX, 0 ], [ x, 0 ] ] );
+ circle( [ originX, 0 ], 0.10 );
+ graph.pt.toFront();
</div>
+ <p>The distance from <code>0</code> to <code><var>SIGN + INT + FRAC</var></code> is <code><var>INT + FRAC</var></code>, which equals the absolute value.</p>
+ <p data-if="SIGN !== &quot;&quot;">In other words, <code><var>INT + FRAC</var></code> is the non-negative version of <code><var>SIGN + INT + FRAC</var></code>.</p>
</div>
</div>
</body>
@@ -22,7 +22,7 @@
<div class="question">
<p><code><var>fraction( N1, D1 )</var> + <var>fraction( N2, D2 )</var> = {?}</code></p>
</div>
- <div class="solution" data-type="improper"><var>N1 / D1 + N2 / D2</var></div>
+ <div class="solution" data-type="rational"><var>N1 / D1 + N2 / D2</var></div>
</div>
</div>
@@ -51,7 +51,7 @@
<div class="hints">
<div class="graphie" id="numbers">
init({
- range: [ [ -1, X_SIDE ], [ -0.5, 3 ] ],
+ range: [ [ -2, 17 ], [ -0.5, 3 ] ],
scale: [30, 45]
});
style({
@@ -60,7 +60,7 @@
X_MAX = X_MAX + ( B_DECIMAL - A_DECIMAL ) * (A_DECIMAL &lt; B_DECIMAL ? 1 : -1);
path( [ [ -0.5, Y_SECOND - 0.5 ], [ X_MAX + 0.5, Y_SECOND - 0.5 ] ]);
- HIGHLIGHTS.push( label( [ X_SIDE, Y_SIDE ], "\\large{\\text{Make sure the decimals are lined up.}}", "right" ) );
+ HIGHLIGHTS.push( label( [ X_SIDE, Y_SIDE ], "\\text{Make sure the decimals are lined up.}", "right" ) );
drawDigits( A_DIGITS.slice( 0 ).reverse(), X_MAX - A_DIGITS.length + 1, Y_FIRST );
drawDigits( B_DIGITS.slice( 0 ).reverse(), X_MAX - B_DIGITS.length + 1, Y_SECOND );
for ( var i = 0; i &lt; 3; i++ ){
@@ -0,0 +1,54 @@
+<!DOCTYPE html>
+<html data-require="math math-format">
+<head>
+ <meta charset="UTF-8" />
+ <title>Adding fractions</title>
+ <script src="../khan-exercise.js"></script>
+</head>
+<body>
+ <div class="exercise">
+ <div class="vars" data-ensure="SIMP_D1 !== SIMP_D2">
+ <var id="N1">randRange( 1, 9 )</var>
+ <var id="D1">randRange( N1 + 1, 13 )</var>
+ <var id="GCD1">getGCD( N1, D1 )</var>
+ <var id="SIMP_N1">N1 / GCD1</var>
+ <var id="SIMP_D1">D1 / GCD1</var>
+
+ <var id="N2">randRange( 1, 9 )</var>
+ <var id="D2">randRange( N2 + 1, 13 )</var>
+ <var id="GCD2">getGCD( N2, D2 )</var>
+ <var id="SIMP_N2">N2 / GCD2</var>
+ <var id="SIMP_D2">D2 / GCD2</var>
+
+ <var id="LCM">getLCM( SIMP_D1, SIMP_D2 )</var>
+ </div>
+
+ <div class="problems">
+ <div>
+ <p class="question"><code><var>fraction( N1, D1 )</var> + <var>fraction( N2, D2 )</var> = {?}</code></p>
+ <p class="solution" data-type="rational"><var>N1 / D1 + N2 / D2</var></p>
+ </div>
+ </div>
+
+ <div class="hints">
+ <div data-if="GCD1 !== 1 || GCD2 !== 1">
+ <p>Simplify each fraction.</p>
+ <p><code><var>fraction( SIMP_N1, SIMP_D1 )</var> + <var>fraction( SIMP_N2, SIMP_D2 )</var></code></p>
+ </div>
+ <p>Find a common denominator by finding the least common multiple of <code><var>SIMP_D1</var></code> and <code><var>SIMP_D2</var></code>.</p>
+ <p><code>\text{LCM(}<var>SIMP_D1</var>\text{, }<var>SIMP_D2</var>\text{)} = <var>LCM</var></code></p>
+ <div>
+ <p>Change each fraction to an equivalent fraction with a denominator of <code><var>LCM</var></code>.</p>
+ <p><code><var>fraction( SIMP_N1, SIMP_D1 )</var> + <var>fraction( SIMP_N2, SIMP_D2 )</var></code></p>
+ <p><code>=<var>fraction( SIMP_N1, SIMP_D1 )</var> <span data-if="LCM !== SIMP_D1">\cdot <var>fraction( LCM / SIMP_D1, LCM / SIMP_D1 )</var></span> + <var>fraction( SIMP_N2, SIMP_D2 )</var> <span data-if="LCM !== SIMP_D2">\cdot <var>fraction( LCM / SIMP_D2, LCM / SIMP_D2 )</var></span></code></p>
+ </div>
+ <p><code>=<var>fraction( SIMP_N1 * LCM / SIMP_D1, LCM )</var> + <var>fraction( SIMP_N2 * LCM / SIMP_D2, LCM )</var></code></p>
+ <p><code>=<var>fraction( SIMP_N1 * LCM / SIMP_D1 + SIMP_N2 * LCM / SIMP_D2, LCM )</var></code></p>
+ <div data-if="getGCD( SIMP_N1 * LCM / SIMP_D1 + SIMP_N2 * LCM / SIMP_D2, LCM ) !== 1">
+ <p>Simplify.</p>
+ <p><code>=<var>fractionReduce( SIMP_N1 * LCM / SIMP_D1 + SIMP_N2 * LCM / SIMP_D2, LCM )</var></code></p>
+ </div>
+ </div>
+ </div>
+</body>
+</html>
@@ -18,7 +18,7 @@
<div class="question">
<p><code><var>fraction( N1, D )</var> + <var>fraction( N2, D )</var> = {?}</code></p>
</div>
- <div class="solution" data-type="improper"><var>( N1 + N2 ) / D</var></div>
+ <div class="solution" data-type="rational"><var>( N1 + N2 ) / D</var></div>
</div>
</div>
@@ -17,7 +17,7 @@
<div class="question">
<div class="graphie">
init({
- range: [ [0, 0], [0, 1] ]
+ range: [ [0, 12], [-1, 1] ]
});
label( [0, 0],
@@ -28,7 +28,7 @@
<div>
<div class="graphie" id="numbers">
init({
- range: [ [ -1, 5 ], [ -0.5, 3 ] ],
+ range: [ [ -1, 11 ], [ -0.5, 3.5 ] ],
scale: [30, 45]
});
drawDigits( A_DIGITS.slice( 0 ).reverse(), X_MAX - A_DIGITS.length + 1, Y_FIRST );
@@ -28,7 +28,7 @@
<div>
<div class="graphie" id="numbers">
init({
- range: [ [ -1, 5 ], [ -0.5, 3 ] ],
+ range: [ [ -1, 11 ], [ -0.5, 3.5 ] ],
scale: [30, 45]
});
drawDigits( A_DIGITS.slice( 0 ).reverse(), X_MAX - A_DIGITS.length + 1, Y_FIRST );
@@ -28,7 +28,7 @@
<div>
<div class="graphie" id="numbers">
init({
- range: [ [ -1, 5 ], [ -0.5, 3 ] ],
+ range: [ [ -1, 11 ], [ -0.5, 3.5 ] ],
scale: [30, 45]
});
drawDigits( A_DIGITS.slice( 0 ).reverse(), X_MAX - A_DIGITS.length + 1, Y_FIRST );
@@ -1,9 +1,19 @@
<!DOCTYPE html>
-<html data-require="math graphie">
+<html data-require="math graphie graphie-helpers">
<head>
<meta charset="UTF-8" />
<title>Angle types</title>
<script src="../khan-exercise.js"></script>
+ <script>
+ function protractorHint( pro, rot, angle ) {
+ pro.translate( 0, 0, true );
+ pro.rotate( rot, true );
+ pro.translatable( false );
+ pro.rotatable( false );
+
+ pro.drawAngle( angle, 2, "green", "green" );
+ }
+ </script>
</head>
<body>
<div class="exercise">
@@ -17,20 +27,24 @@
<div class="question">
<p>Is the shown angle acute, right, or obtuse?</p>
- <div class="graphie">
+ <div class="graphie" id="angle">
var ANGLE_TWO = ANGLE_ONE + DIFF;
var ANGLE_ONE_R = ANGLE_ONE * PI / 180;
var ANGLE_TWO_R = ANGLE_TWO * PI / 180;
init({
- range: [ [-6, 6], [-6, 6] ],
+ range: [ [-11, 31], [-10, 10] ],
scale: 20
});
path([ [5 * cos( ANGLE_ONE_R ), 5 * sin( ANGLE_ONE_R )], [0, 0], [5 * cos( ANGLE_TWO_R ), 5 * sin( ANGLE_TWO_R )] ]);
arc( [0,0], 1, ANGLE_ONE, ANGLE_TWO );
+ graph.protractor = new Protractor( [22, 0], 8 );
+ jQuery( "#scratchpad-show" ).replaceWith( "Scratchpad not available" ).hide();
+ jQuery( "#scratchpad" ).hide();
+
</div>
</div>
@@ -42,6 +56,9 @@
</ul>
<div class="hints">
+ <div class="graphie" data-update="angle">
+ protractorHint( graph.protractor, 360 - ANGLE_ONE, DIFF );
+ </div>
<p>The shown angle measures less than <code>90^\circ</code>.</p>
<p>Therefore, it is an acute angle.</p>
</div>
@@ -55,6 +72,9 @@
<div class="solution">Right</div>
<div class="hints">
+ <div class="graphie" data-update="angle">
+ protractorHint( graph.protractor, 360 - ANGLE_ONE, DIFF );
+ </div>
<p>The shown angle measures <code>90^\circ</code>.</p>
<p>Therefore, it is a right angle.</p>
</div>
@@ -68,6 +88,9 @@
<div class="solution">Obtuse</div>
<div class="hints">
+ <div class="graphie" data-update="angle">
+ protractorHint( graph.protractor, 360 - ANGLE_ONE, DIFF );
+ </div>
<p>The shown angle measures more than <code>90^\circ</code>.</p>
<p>Therefore, it is an obtuse angle.</p>
</div>
Oops, something went wrong. Retry.

0 comments on commit 432ecb9

Please sign in to comment.