# Khan/khan-exercises

Fetching contributors…
Cannot retrieve contributors at this time
269 lines (256 sloc) 16.4 KB
 Line relationships
randRangeNonZero( -3, 3 ) / randRange( 1, 3 ) M > 0 ? "" : "-" M > 0 ? "-" : "" decimalFraction( M, "true", "true" ) decimalFraction( -1 / M, "true", "true" ) randRange( -5, 5 ) randRange( 2, 8 ) * randRangeNonZero( -1, 1 ) randRange( 2, 8 ) * randRangeNonZero( -1, 1 ) "perpendicular"

Find the slope and y-intercept of the line that is \color{GREEN}{\text{LINE_TYPE}} to \enspace \color{BLUE}{y = M_FRACM_SIGNx + B}\enspace and passes through the point \color{red}{(X, Y)}.

graphInit({ range: [[-10, 10], [-10, 10]], scale: [18, 18], tickStep: 1, labelStep: 1, unityLabels: false, labelFormat: function( s ) { return "\\small{" + s + "}"; }, axisArrows: "<->" }); plot(function( x ) { return ( M * x + B ); }, [-10, 10], { stroke: BLUE }); circle( [X, Y], 1/4, { stroke: "none", fill: "#ff0000" } );

m = -1 / M

b = Y - ( -1 / M * X )

Lines are considered perpendicular if their slopes are negative reciprocals of each other.

The slope of the blue line is \color{BLUE}{M_FRAC}, and its negative reciprocal is \color{GREEN}{M_PERP_FRAC}.

Thus, the equation of our perpendicular line will be of the form \enspace \color{GREEN}{y = M_PERP_FRACM_PERP_SIGNx + b}\enspace.

We can plug our point, (X, Y), into this equation to solve for \color{GREEN}{b}, the y-intercept.

Y = \color{GREEN}{M_PERP_FRACM_PERP_SIGN}(X) + \color{GREEN}{b}

Y = decimalFraction( -1 / M * X, "true", "true" ) + \color{GREEN}{b}

Y - decimalFraction( -1 / M * X, "true", "true" ) = \color{GREEN}{b} = decimalFraction( Y - ( -1 / M * X ), "true", "true" )

The equation of the perpendicular line is \enspace \color{GREEN}{y = M_PERP_FRACM_PERP_SIGNx + decimalFraction( Y - ( -1 / M * X ), "true", "true" )}\enspace.

\color{GREEN}{m = decimalFraction( -1 / M, "true", "true" ), \enspace b = decimalFraction( Y - ( -1 / M * X ), "true", "true" )}

plot(function( x ) { return ( -1 / M * x + ( Y - ( -1 / M * X ) ) ); }, [-10, 10], { stroke: GREEN });
"parallel" randRange( 2, 8 ) * randRangeNonZero( -1, 1 ) randRange( 2, 8 ) * randRangeNonZero( -1, 1 )

m = M

b = Y - M * X

Parallel lines have the same slope.

The slope of the blue line is \color{BLUE}{M_FRAC}, so the equation of our parallel line will be of the form \enspace \color{GREEN}{y = M_FRACM_SIGNx + b}\enspace.

We can plug our point, (X, Y), into this equation to solve for \color{GREEN}{b}, the y-intercept.

Y = \color{GREEN}{M_FRACM_SIGN}(X) + \color{GREEN}{b}

Y = decimalFraction( M * X, "true", "true" ) + \color{GREEN}{b}

Y - decimalFraction( M * X, "true", "true" ) = \color{GREEN}{b} = decimalFraction( Y - M * X, "true", "true" )

The equation of the parallel line is \enspace \color{GREEN}{y = M_FRACM_SIGNx + decimalFraction( Y - M * X, "true", "true" )}\enspace.

\color{GREEN}{m = decimalFraction( M, "true", "true" ), \enspace b = decimalFraction( Y - M * X, "true", "true" )}

plot(function( x ) { return ( M * x + ( Y - M * X ) ); }, [-10, 10], { stroke: GREEN });
randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) A1 * F B1 * F C1 * F expr(["+", ["*", A1, "x"], ["*", B1, "y"]]) + " = " + C1 expr(["+", ["*", A2, "x"], ["*", B2, "y"]]) + " = " + C2

What do the following two equations represent?

EQ1

EQ2

Equivalent lines
• Equivalent lines
• Parallel lines
• Perpendicular lines
• None of the above
init({ range: [[-10, 10], [-10, 10]], scale: [20, 20] }); grid( [-10, 10], [-10, 10], { stroke: "#ccc" }); style({ stroke: "#888", strokeWidth: 2, arrows: "->" }); path( [ [-10, 0], [10, 0] ] ); path( [ [0, -10], [0, 10] ] ); style({ stroke: "#6495ED", arrows: null }); plot( function( x ) { return ( C1 / B1 ) - ( A1 / B1 ) * x; }, [-10, 10]);

Putting the first equation in y = mx + b form gives:

expr(["+", ["*", A1, "x"], ["*", B1, "y"]]) + " = " + C1

expr(["*", B1, "y"]) + " = " + expr(["+", ["*", (-1 * A1), "x"], C1])

"y = " + fractionReduce( -A1, B1 ) + "x + " + fractionReduce( C1, B1 )

plot( function( x ) { return ( C2 / B2 ) - ( A2 / B2 ) * x; }, [-10, 10]);

Putting the second equation in y = mx + b form gives:

expr(["+", ["*", A2, "x"], ["*", B2, "y"]]) + " = " + C2

expr(["*", B2, "y"]) + " = " + expr(["+", ["*", (-1 * A2), "x"], C2])

"y = " + fractionReduce( -A2, B2 ) + "x + " + fractionReduce( C2, B2 )

randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) expr(["+", ["*", A1, "x"], ["*", B1, "y"]]) + " = " + C1 expr(["+", ["*", A2, "x"], ["*", B2, "y"]]) + " = " + C2
None of the above

The slopes are not the same, so the lines are not equivalent or parallel. The slopes are not negative inverses of each other, so the lines are not perpendicular. The correct answer is none of the above.

randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) A1 * F B1 * F C1 * F expr(["+", ["*", A1, "x"], ["*", B1, "y"]]) + " = " + C1 expr(["+", ["*", A2, "x"], ["*", B2, "y"]]) + " = " + C2
Equivalent lines

The above equations turn into the same equation, so they represent equivalent lines.

randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) A1 * F B1 * F randRange( -5, 5 ) expr(["+", ["*", A1, "x"], ["*", B1, "y"]]) + " = " + C1 expr(["+", ["*", A2, "x"], ["*", B2, "y"]]) + " = " + C2
Parallel lines

The slopes are equal, and the y-intercepts are different, so the lines are parallel.

randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRangeNonZero( -5, 5 ) randRange( 1, 5 ) -1 * B1 * F A1 * F randRangeNonZero( -5, 5 ) expr(["+", ["*", A1, "x"], ["*", B1, "y"]]) + " = " + C1 expr(["+", ["*", A2, "x"], ["*", B2, "y"]]) + " = " + C2
Perpendicular lines

The slopes are negative inverses of each other, so the lines are perpendicular.

Something went wrong with that request. Please try again.