Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

New Exercise maximizing_minimizing_functions #17947

Closed
wants to merge 1 commit into from

3 participants

@Michael-Koop

New exercise which asks to find the maximum and minimum values of a randomly generated cubic polynomial on the interval [-5,5]. This is my first khan exercise so any feedback/advice would be much appreciated

@Michael-Koop Michael-Koop reopened this
@Christi

might want to tighten up your data-ensures.

@beneater
Owner

We've gotten an overwhelming number of pull requests and unfortunately haven't had time to go through all of them. To get down to a more manageable number, we're (somewhat arbitrarily) closing a bunch of them. :(

Our focus for the next few months will be deepening the content we have for 5th grade level math through trigonometry. To reduce the number of open pull requests to a more manageable size, we're closing pull requests that don't relate directly to that focus. We're also closing all pull requests that were opened before the beginning of 2012.

As we add other subject areas in the future, we'll still be able to use the closed pull requests. If you've submitted something that fills a gap in 5th-trig coverage and we've inadvertently closed it, please feel free to re-open a new pull request.

@beneater beneater closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Mar 29, 2012
  1. @Michael-Koop
This page is out of date. Refresh to see the latest.
Showing with 71 additions and 0 deletions.
  1. +71 −0 exercises/maximizing_minimizing_functions.html
View
71 exercises/maximizing_minimizing_functions.html
@@ -0,0 +1,71 @@
+<!DOCTYPE html>
+<html data-require="math expressions">
+<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+ <title>Maximizing & Minimizing Functions</title>
+ <script src="../khan-exercise.js"></script>
+</head>
+<body>
+ <div class="exercise">
+ <div class="problems">
+ <div id="cubic">
+ <div class="vars">
+ <div data-ensure="DER_B%2 == 0 && X_1 <= X_2">
+ <var id="A">randRangeNonZero( -4, 4 )</var>
+ <var id="B">randRangeNonZero( -4, 4 )</var>
+ <var id="C">( A > 0 ? -1 : 1 ) * randRange( 3, 8 )</var>
+ <var id="H">randFromArray([ "\\Delta x", "h" ])</var>
+
+ /* Zeros of the derivative of the function*/
+ <var id="X_1">randRangeNonZero( -4, 4 )</var>
+ <var id="X_2">randRangeNonZero( -4, 4 )</var>
+
+ /* Coefficients of derivative of the function (Ax^2 + Bx + C) */
+ <var id="DER_A">randRangeNonZero( -2, 2 )*3</var>
+ <var id="DER_B">-DER_A * X_1 - DER_A * X_2</var>
+ <var id="DER_C">DER_A * X_1 * X_2</var>
+
+ /* Coefficients of the function (Ax^3 + Bx^2 + Cx + D)*/
+ <var id="FUNC_A">DER_A / 3 </var>
+ <var id="FUNC_B">DER_B / 2 </var>
+ <var id="FUNC_C">DER_C </var>
+ <var id="FUNC_D">randRangeNonZero(-9 , 9)</var>
+
+ /* Possible Extreme Values */
+ <var id="EXT_1">FUNC_A * pow(X_1,3) + FUNC_B * pow(X_1,2) + FUNC_C * X_1 + FUNC_D</var>
+ <var id="EXT_2">FUNC_A * pow(X_2,3) + FUNC_B * pow(X_2,2) + FUNC_C * X_2 + FUNC_D</var>
+ <var id="EXT_3">FUNC_A * pow(-5,3) + FUNC_B * pow(-5,2) + FUNC_C * (-5) + FUNC_D</var>
+ <var id="EXT_4">FUNC_A * pow(5,3) + FUNC_B * pow(5,2) + FUNC_C * 5 + FUNC_D</var>
+ <var id="MAX">max(EXT_1,EXT_2,EXT_3,EXT_4)</var>
+ <var id="MIN">min(EXT_1,EXT_2,EXT_3,EXT_4)</var>
+ </div>
+ <var id="X" data-ensure="abs( ( A * X + B ) * X + C ) < 7">randRange( -6, 6 )</var>
+ </div>
+ <div class="question">
+ <p>What are the maximum and minimum values of the function <code>f(x) = <var>expr(["+", ["*", FUNC_A, ["^", "x", 3]],["*", FUNC_B, ["^", "x", 2]], ["*", FUNC_C, "x"], FUNC_D])</var></code> on the interval <code>[-5,5]</code></p>
+ </div>
+ <div class="solution" data-type="multiple">
+ <p class="short">Maximum Value: <span class="sol"><var>MAX</var></span></p>
+ <p>Minimum Value: <span class="sol"><var>MIN</var></span></p>
+ </div>
+ </div>
+ </div>
+
+ <div class="hints">
+ <p>We find where the critical points (possible locations of local maxima or minima) of a function <code>f(x)</code> are by setting the derivative <code>f'(x)</code> equal to zero.</p>
+ <p>The derivative of <code>f(x)</code> is <code>f'(x) = <var>expr(["+", ["*", DER_A, ["^", "x", 2]], ["*", DER_B, "x"], DER_C])</var></code>.</p>
+ <p>We solve <code>f'(x) = <var>expr(["+", ["*", DER_A, ["^", "x", 2]], ["*", DER_B, "x"], DER_C])</var> = 0</code> to find the values of <code>x</code> where there are critical points.</p>
+ <div>
+ <p data-if="X_1 === X_2">Using the quadratic equation we find that there is only one critical point, <code>x = <var>X_1</var></code>.</p>
+ <p data-else>Using the quadratic equation we find two critical points <code>x = <var>X_1</var></code> and <code>x = <var>X_2</var></code>.</p>
+ </div>
+ <p>We evaluate <code>f(x)</code> at the critical point(s) and the end points of the interval</p>
+ <div>
+ <p data-if="X_1 === X_2">We evaluate <code>f(<var>X_1</var>) = <var>EXT_1</var></code>, <code>f(-5) = <var>EXT_3</var></code>, and <code>f(5) = <var>EXT_4</var></code>.</p>
+ <p data-else>We evaluate <code>f(<var>X_1</var>) = <var>EXT_1</var></code>, <code>f(<var>X_2</var>) = <var>EXT_2</var></code>, <code>f(-5) = <var>EXT_3</var></code>, and <code>f(5) = <var>EXT_4</var></code>.</p>
+ </div>
+ <p>On the interval <code>[-5,5]</code> the maximum of <code>f(x)</code> is <var>MAX</var> and the minimum is <var>MIN</var>.</p>
+ </div>
+ </div>
+</body>
+</html>
Something went wrong with that request. Please try again.