# Khan/khan-exercises

igorT authored and sophiebits committed Jul 21, 2011
1 parent 1616198 commit eb168d32d07e4cef25bb503f14c8ed18033c776e
Showing with 226 additions and 0 deletions.
1. +219 −0 exercises/trigonometry_1.html
2. +7 −0 utils/math-format.js
 @@ -0,0 +1,219 @@ + + + + Trigonometry 1 + + + + +
+
+ randRange(3, 10) + randRange(3, 10) + BC + AC * AC + BC * BC + formattedSquareRootOf(AC * AC + BC * BC) +
+
• "ABC"
• +
• "BAC"
• +
+ (ANGLE.substring(0,1) + ANGLE.substring(2)) + + (function(){ + if ( OPPOSITE_NAME == "AC" ){ + return AC; + } + else if ( OPPOSITE_NAME == "BC" ){ + return CB; + } + return AB_STRING; + })() + + + "AB" + AB_STRING + + ANGLE.substring(1) + + (function(){ + if ( ADJACENT_NAME=="AC" ){ + return AC; + } + else if ( ADJACENT_NAME=="BC" ){ + return BC; + } + + return AB_STRING; + })() + + + fraction( OPPOSITE_VALUE, ADJACENT_VALUE, false, false, false, false) + + + fractionReduce( OPPOSITE_VALUE, ADJACENT_VALUE, false, false) + + + "\\frac{" + OPPOSITE_VALUE + "}{" + formattedSquareRootOf(AB) + "}" + + + fractionSQRoot( OPPOSITE_VALUE , AB ) + + + "\\frac{" + ADJACENT_VALUE + "}{" + formattedSquareRootOf(AB) + "}" + + + fractionSQRoot( ADJACENT_VALUE , AB ) + + + +
+ +
+
+
+

\overline{AC} is AC units long

+

\overline{BC} is BC units long

+

\overline{AB} is AB_STRING units long

+
+
+

What is \sin(\angle ANGLE) ?

+ +
+ betterTriangle( BC, AC, "A", "B", "C", BC, AC, AB_STRING ); +
+
+ +
+ SIN +
+
+
• COS
• +
• SIN
• +
• TAN
• +
• \dfrac{1}{AB}
• +
• \dfrac{1}{BC}
• +
• \dfrac{1}{AC}
• +
• \dfrac{2 \sqrt{2}}{AC}
• +
+ +
+

SOH CAH TOA

+

Sin = Opposite over Hypotenuse

+

opposite = \overline{OPPOSITE_NAME} = OPPOSITE_VALUE

+

hypotenuse = \overline{HYPOTENUSE_NAME} = AB_STRING

+

\sin(\angle ANGLE)=SIMPLE_SIN

+

=SIN

+
+
+ +
+
+

\overline{AC} is AC units long

+

\overline{BC} is BC units long

+

\overline{AB} is AB_STRING units long

+
+
+

What is \cos(\angle ANGLE) ?

+ +
+ betterTriangle( BC, AC, "A", "B", "C", BC, AC, AB_STRING ); +
+
+ +
+ COS +
+ +
+

SOH CAH TOA

+

+

+

hypotenuse = \overline{HYPOTENUSE_NAME} = AB_STRING

+

\cos(\angle ANGLE )=SIMPLE_COS

+

=COS

+
+
+ +
+
+

\overline{AC} is AC units long

+

\overline{BC} is BC units long

+

\overline{AB} is AB_STRING units long

+
+
+

What is \tan(\angle ANGLE) ?

+ +
+ betterTriangle( BC, AC, "A", "B", "C", BC, AC, AB_STRING ); +
+
+ +
+ TAN +
+ +
+

SOH CAH TOA

+

+

opposite = \overline{OPPOSITE_NAME} = OPPOSITE_VALUE

+

+

\tan(\angle ANGLE)=SIMPLE_TAN

+

=TAN

+
+
+ +
+ +
+ +
 @@ -11,6 +11,13 @@ jQuery.extend(KhanUtil, { return KhanUtil.fraction( f[0], f[1], defraction, reduce, small, parens ); }, + reduce: function( n, d){ + var gcd = KhanUtil.getGCD( n, d ); + n = n / gcd; + d = d / gcd; + return [ n, d ]; + }, + /* Format the latex of the fraction n/d. * - Will use latex's dfrac unless small is specified as truthy. * - Will wrap the fraction in parentheses if necessary (ie, unless the